Malloc function

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Malloc function

1,050件の閲覧回数
lucatollot
Contributor I

Hi, I'm using IAR tool wih imxRT1020. I want use malloc function and pass a variable in the argument for dynamic allocation but the function return me a null pointer. I would like to know if is possible to pass a variable in the argument or not.

ラベル(4)
タグ(3)
0 件の賞賛
2 返答(返信)

935件の閲覧回数
crist_xu
NXP Employee
NXP Employee

I think the size of the heap area in your project is a bit smaller, please re-configure this area, and try again

0 件の賞賛

981件の閲覧回数
jeremyzhou
NXP Employee
NXP Employee

Hi Luca Tollot,

Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
1) I would like to know if it's possible to pass a variable in the argument or not.
-- In the IAR demo of SDK library, it's available to calling the malloc function to request an area from the heap, please give a try.

Have a great day,
TIC

 

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 件の賞賛