How To Program the Application in the Flash/RAM

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How To Program the Application in the Flash/RAM

5,677 Views
dumitru-daniel_
NXP Employee
NXP Employee

In case you want to program an existing application generated with Model Based Design Toolbox or any other IDE (e.g. the examples from the Motor Control Course) there is an easy way called RAppID Bootloader Tool.

Let us consider the following example shown in Lecture #12 - Motor Control System. This lecture contains a zip file Lecture #12.zip that comes with a pre-compiled FLASH application that you can find inside the ClosedLoop_Control_mbd_rtw folder: ClosedLoop_Control_mbd_rtw\ClosedLoop_Control.mot

Question: How to flash the *.mot file into the MPC5744P DevKit?

Answer: Use RAppID_BL.exe application via Serial Port.

Prerequisites: This tutorial assumes you have already programmed the RBF file into the flash memory of the MCP5744P microprocessor. The RBF is the target microcontroller specific algorithm, which the GUI interfaces to for
boot loader operation. Check Video Link : 7766 starting at 2.04 to see how you can program the RBF. 

Note!!!: There are different RBF files for DevKits vs. Development Board. Choose the appropriate one based on your setup. Special thanks to hjhjhj‌ for highlighting this aspect.

Step 1: Configure the MPC5744P DevKit board to use power from USB through the OpenSDA interface by setting the J13 jumper in the 2-3 position

pastedImage_14.png

Step 2: Connect the Board with the Host PC via the Micro-USB connector

pastedImage_15.png

Step 3: Check your computer Device Manager to see if the Serial Driver was installed and configured correctly and note down the UART port assigned (e.g. COM5)

pastedImage_17.png

Step 4: Navigate to the C:\MBDToolbox\mbdtbx_MPC574xP\tools\BootLoader folder and run the RAppID_BL.exe application

pastedImage_18.png

Step 5: Configure: Communication Protocol, Communication Port and select the MCU part you want to program.

pastedImage_27.png

Step 6: Load the *.mot file you need to program by clicking on the Browse button

pastedImage_33.png

pastedImage_35.png

Step 7: Select Auto Read File option

pastedImage_37.png

Step 8: Reset the board by pressing the SW3

pastedImage_38.png

Step 9: Very quickly (within 5 seconds from pressing SW3) press the Start Boot Loader button

pastedImage_40.png

Step 10: Wait patiently until the Erase&Program operation is finalized. The RAppID_BL.exe should show: Complete

pastedImage_43.png

Now your application is programmed into the MCU flash/ram memory. At this point you may change back the J13 to position 1-2 for external power supply.

5 Replies

2,678 Views
Jakubowski
Contributor I

Is it possible to somehow use a usb flash drive or some memory card (e.g. SD cards) in place of the EEPROMS in Ben's 8 bit computer? What would be the minimum components/circuitry in order to execute this? This would be preferable considering sd cards and usb flash drives are scattered all over my house and easy to buy.

Also, how would addressing data work on these devices compared to the EEPROM? For example, on an EEPROM, I can find that address 1 has the data 01010101 and these addresses are pretty easy to access via the pins on the chip.

0 Kudos

2,785 Views
maharajshreekum
Contributor III

I am using MPC5748G Devkit Rev D and I am able to load successfully rbf file and communicated with the Rappid BL utility.

Now if I want to run my test app on top of the BL code, are there any changes to be done in the linker scripts of the test app like linker_flash or linker_ram.ld.

I have tried flashing the test app on top of it, but unable to run my application.

 

Any Leads!!!!

0 Kudos

3,327 Views
hjhjhj
Contributor IV

Hi Daniel,

    After programming the rbf file to MCU and doing from step1 to step10 as mentioned above,MPC5744P DevKit still fails to  communicate with Rappid bootloader GUI.Can you help me solve it?

33.PNG

Thanks!

 HJ

0 Kudos

3,327 Views
dumitru-daniel_
NXP Employee
NXP Employee

Hi HJ, 

The RAppID_bootloader requires the RBF (boot loader flash algorithm application) to be flash into the MCU memory. This is done only once per each board.

The procedure of flashing the boot loader algorithm is described in the Motor Control Class: Lecture 3 - Input Commands  first video starting with 2.04 minute.

Please let me know if this works for you! If this is the root cause for your failure then i'll update the topic to be more clear about the overall procedure.

Best regards,
Daniel

0 Kudos

3,327 Views
hjhjhj
Contributor IV

Hi Daniel,

    Thanks for your reply!The reason why my MPC5744P DevKit  fails to  communicate with Rappid bootloader GUI is that I programmed the MPC5744P.rbf to MCU,while the correct method is programming the MPC5744P_DEVKIT.rbf to MCU.