USB LDD K40 link error

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

USB LDD K40 link error

跳至解决方案
2,008 次查看
FredF
Contributor III

I have posted a similar message to the MQX forum, but I was not sure if this forum would be more appropriate. If the USB LDD is added to the bsp_twrk40x256_pe BSP project in CW 10.1 using MQX 3.7, a link error occurs indicating that "_mem_alloc_system_align" is not defined when the pe_demo_twrk40x256 MQX sample project is built. I have not found any reference to this function in the MQX documentation.  This code is generated by Processor expert, and I do not know how to resolve the erorr.

标签 (1)
标记 (1)
0 项奖励
回复
1 解答
1,669 次查看
ProcessorExpert
Senior Contributor III

Hello,

 

the solution of the issue is here:

https://community.freescale.com/thread/100242

 

best regards
Vojtech Filip
Processor Expert Support Team

在原帖中查看解决方案

0 项奖励
回复
5 回复数
1,669 次查看
hard_ware
Contributor III

Hello,

 

I got exactly the same error, I think its is related to the not included USB lib, but could not resolve it till now.

0 项奖励
回复
1,669 次查看
FredF
Contributor III

I was able to resolve the error by linking the USB libraries.  Thanks for the suggestion.

1,669 次查看
hard_ware
Contributor III

Glad to could help you, could you please tell the steps how you get it compiled, I tried to add the USB lib to project and included the USB.h but still get the

Undefined : "_mem_alloc_system_align"

error.

0 项奖励
回复
1,669 次查看
FredF
Contributor III

My previous post was not correct since there was a mismatch in the LDD names, so the code was not actually being linked. This is the repsonse I received from a sevice request that resolved the issue.

 

We made a quick analysis and there seem to be two problems:

- The funtion _mem_alloc_system_align seems not to be present in latest MQX.
So as the customer correctly observed, it's necessary to use _mem_alloc_align instead.

- The _mem_alloc_align is available only if the BSP and PSP is recompiled with the option MQX_USE_LWMEM_ALLOCATOR set to 0.
It should help adding #define MQX_USE_LWMEM_ALLOCATOR 0 to for example small_ram_config.h file, before this symbol is used."

For a current workaround you can use "_mem_alloc_align", enable the allocator macro and recompile the BSP/PSP.

Processor Expert team is getting more details on the best solution for these problems so that they get fixed for further releases of PExpert.
0 项奖励
回复
1,670 次查看
ProcessorExpert
Senior Contributor III

Hello,

 

the solution of the issue is here:

https://community.freescale.com/thread/100242

 

best regards
Vojtech Filip
Processor Expert Support Team

0 项奖励
回复