I am using mcf52259 controller and MQX4.1 RTOS.
I have MRAM on my Board and as said in main.h i uncommented the below line
**************************************************************************************************************************************
/* Uncomment following code to use whole external MRAM for ramdisk, if available.
Not applicable when using MRAM target! */
#define RAM_DISK_BASE BSP_EXTERNAL_MRAM_BASE
#define RAM_DISK_SIZE BSP_EXTERNAL_MRAM_SIZE
********************************************************************************************************************************************
********************************************************************************************************************************************
Tried to use whole MRAM for ramdisk....
Then i flashed my code...
But in the console it is showing
Initialized RAMdisk to a:/
and getting stuck in the code ...
And Not moving further....
Can anyone suggest me a solution on this......
Original Attachment has been moved to: Testing_4.1.rar
Hello Praveen,
1) If you want a task to be created in external RAM you need _mem_extend command. This command tells the kernel where the new stack pointer is going to point.
2) FlexBus is configured to communicate with MRAM. This is done by default in the initialization.
3) If the default FlexBus initialization does not match your requirements you must reconfigure FlexBus registers at the beginning of your application. Please make sure that the previous configuration does not affect the settings you need in your application.
4) You can access to external memories without the need of _mem_exted. In this case you will need to read or write directly to the memory address. But the kernel is not going to be aware of this memory and it won’t be possible to use this memory to create tasks.
5) In order to be able to use _mem_extend command you must disable Light Weight Memory Support (MQX_USE_LWMEM) and enable Memory Support (MQX_USE_MEM). The reason is that the light wight mem support does not incude _mem_extend command. To do this you must add the next lines in user_config.h
#define MQX_USE_MEM 1
#define MQX_USE_LWMEM 0
#define MQX_USE_LWMEM_ALLOCATOR 0
After editing this file you must recompile kernel BSP and PSP libraries
After this you must be able to use the _mem_extend command.
Another option is mentioned in the thread:
Best way to move RAM usage to external SRAM?
Hope this information helps.
Have a great day,
Sol
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------