This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
I have my custom board who's design is based on TM4C1294NCPDT. I want to upgrade the firmware of my custom board using UART and bootloader. I don't know the how to do that.
Any inputs/ insight /step by step guide that will help are appreciated.
Hi,
Why not try a few things and see if it connects, recall LM with JTAG is useless.
Hi BP101,
Thanks for your reply and doc.
BP101 said:recall LM with JTAG is useless.
I din't understand why you said that but I've programmed an arbitrary MAC on my fresh custom board with the help of JTAG of TM4C123 board. So I was thinking to use" Serial UART" Connections.
Thanks Ralph for your reply!
Ralph Jacobi said:you need to have your PC connected to the board UART port, make sure the UART is recognized by the PC (has a COM port), and then connect to that COM Port using LM Flash to load your .bin file.
I'll connect UART0 pins that are PA0 and PA1 to USB to TTL board and connect that to my PC, and choose the "manual"connections and "Serial Port" in LM Flash Programmer to dump the .bin file.
And second thing I wanted to ask the boot_demo1 example is also flash based bootloader(As I remember I've read it in comments)..I want a serial /uart ROM based bootloder. As I have gone through another serial bootloader guide which demonstrates to use TM4C123 as a programmer device and the TM4C1294NCPDT as a target device. Now I don't have knowledge about: Should I include my firmware code with this examples of boot_demo1? or should I run them first then my firmware code?
And in "boot_serial" example, there is only bl_config.h where UART port is selected for communicating with bootloader. So how to run this boot_serial example with firmware...please explain.
Also in the bootloader guide there are certain command for custom protocol for uart also...this and packet formation are needed in case of serial ROM based bootloader also?
Thanks
Techinspired said:I din't understand why you said that
Past tried to use XDS100 (JTAG header) with LM3S to write MAC user registers is not supported. The TMC123 board has an on board ICDI simulates (JTAG) control pins into the target and transports firmware or writes flash via USB CDM device drivers in Windows. That is not the same as using LM flash attempting to connect via JTAG header of custom PCB with an XDS100/200 JTAG simulator as any normal person would attempt to do after spending many $ on XDS simulator.
I don't subscribe to the use of overly complicated TMC123 method to program a remote target TM4C129x. For that reason you are seemingly unaware CCS can direct connect to custom PCB via JTAG simulator and header to load firmware, debug it via SWO and use the register debug features built into CCS. One ideal high speed JTAG simulator (on a budget) is the XDS200 sold in the TI store and may become useful for knowledge gains down the road.
The serial boot loader APP is a pain, adds complexity over that of invoking the embedded ROM version TM4C129x.
Hello Techinspired,
The example in TivaWare does run in Flash because it is an example to help users learn. If you feel you have a good grasp on the bootloader using the flash version you can work on utilizing the ROM bootloader.
Once you know what to do in terms of getting boot_demo1 into the board, I would say try to load the .bin for your own code as well so you have the location of the program setup the way you want. You wouldn't include the firmware in boot_demo1, but rather instead of loading boot_demo1, you'd load your firmware instead. The boot_demo1 just has functionality to jump to the flash bootloader repeatedly so you can see how you can trigger a bootloader via GPIO.
Techinspired said:And in "boot_serial" example, there is only bl_config.h where UART port is selected for communicating with bootloader. So how to run this boot_serial example with firmware...please explain.
The boot_loader folder has the rest of the application. The bl_config.h file is the only one which should be edited, so that is why it is in the primary directory for the example.
Techinspired said:Also in the bootloader guide there are certain command for custom protocol for uart also...this and packet formation are needed in case of serial ROM based bootloader also?
Yes, you would need to use those for the ROM boot loader.
As per my understanding of ROM uart boot loader is that it get involved only either BOOTCFG register's EN bit is clear or address at 0x4 is all F's, reference: RTOS/TM4C129ENCPDT: Regarding bootloader - Arm-based microcontrollers forum - Arm-based microcontrollers...
Now my custom board was earlier programmed using TM4C123's ICDI so it's flash had to be erased( to invoke ROM based bootloader in LMFlash Pragrammer) so I used the TM4C123's ICDI to erase flash.
and checked that flash is blank by blank check test which in my board case, was passed.
Then I removed the JTAG connections and connected my custom board's PA0(RX) and PA1(TX) pin to USB to TTL board whice has COM port-9(who's baud rate I set to 115200 in device manager and kept the same baud rate in LM flash programmer too)
and tried to program a blinky.bin to my custom board but it gave some error like this..
Is there any important step of invoking uart ROM boot loader in LM Flash programmer, am I missing here?
Thanks.
Hello Ralph,
Thanks for your reply!
Few things I want to ask:
1) Can I test this whole bootloader process on launchpad who's UART0 pin's are not out on the header. So the debug cable would work for UART0? so the COM port in LM flash programmer would be the debug com port of launchpad...right? and what other jumpers should I remove/ mount?
2) Do I need to program the boot_serial.bin in between, after the flash has been erased and the application bin is going to be programmed?
3) What does the "boot_serial" example do?
4) If I set the #define APP_BASE 0x2000 in the linker cmd file, so I would be entering the same offset address in the program offset address
field in LM Flash programmer too? But in the bl_config.h the APP_START_ADDRESS is defined as 0x4000 not as 0x2000...so this thing is
confusing.
5) If I need to set the program offset in linker cmd file then this is doable in case of a project built in ccs but my application has been built in
in Energia so where do I set/find linker cmd file,BTW I have imported energia code in ccs and dumped the application using JTAG.
Regards.
Hello Ralph,
Thanks a lot for your elaborate explanation and help!
Though, I have not tested this whole boot loader process on Launchpad or on my custom board, as I'm caught up in another issue of not getting IP address for my custom board so this task has taken precedence over the "uart bootloader" task....but as soon as I sort out the IP address issue(which I've posted on this forum also...hoping to get a solution/help here, as I've been struggling with this issue for a while. Could anyone from hardware design team from TI help me in this regard?) I will test the serial bootloader later and will keep you posted about the update.
Best Regards,
Techinspired
Perhaps this might be of service: i.imgur.com/LFHuP3J.png
Shows a TM4C1294NCPDT dev board connected to another as debugger/programmer. It's actually what I use to program my prototypes ^_^
It's not too much hassle to whip up a little ribbon cable connector to 10 pin plug for on-the-go use.
HI
you have to load "boot_serial" example using JTAG. Once it is running it will download boot_demo1.bin via LM flash programmer. Please refer to the TivaWare boot_serial (the boot loader) and the boot_demo1.bin (the application) examples.
Prachi Patil said:....but as soon as I sort out the IP address issue(which I've posted on this forum also...hoping to get a solution/help here
Hi Prachi,
Thanks for the verified!
Curious did your custom PCB get IP address yet. Many seem to end up in forum posting EMAC0 can't pull IP address. Perhaps send link to post via PM if still having issues, best of luck this New Year to get it working.