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.
Hi all,
I am using a custom board with a TM4C1294KCPDT and try to implement the Ethernet bootloader.
I've done that on a LM3S6965 and LM3S9B92 already, so I have some experience with it.
Now, after searching a while in documentation, code and forum posts, I finally got rid of the confusion caused by the documentation.
Just to let off some steam, my comments on some issues.
1. in the Bootloader guide, it is said about FLASH_PAGE_SIZE
// The size of a single, erasable page in the flash. This must be a power // of 2. The default value of 1KB represents the page size for the internal // flash on all Tiva MCUs and this value should only be overridden if // configuring a boot loader to access external flash devices with a page size // different from this.
#include "driverlib/rom.h" // // Define ROM_SysCtlClockFreqSet() for snowflake RA0. Even though this function // is deprecated in RA0 ROM, the function operates correctly when // SYSCTL_MOSCCTL register is configured correctly prior to calling this // function. // #if defined(TARGET_IS_TM4C129_RA0) #define ROM_SysCtlClockFreqSet \ ((uint32_t (*)(uint32_t ui32Config, \ uint32_t ui32SysClock))ROM_SYSCTLTABLE[48]) #endif // // Define MAP_GPIOPadConfigSet() for the Boot Loader for Snowflake. // This function fails in Snowflake for higher drive strengths, it will work // properly for the instances where it is used here in the boot loader. // #if defined(TARGET_IS_TM4C129_RA0) || \ defined(TARGET_IS_TM4C129_RA1) #define ROM_GPIOPadConfigSet \ ((void (*)(uint32_t ui32Port, \ uint8_t ui8Pins, \ uint32_t ui32Strength, \ uint32_t ui32PadType))ROM_GPIOTABLE[5]) #endif // // Define ROM_EMACInit for the bootloader of Snowflake RA0. This function is // deprecated in RA0 ROM, as it does not disable some interrupts that are not // cleared by ***_EMACIntClear(). But that is not a problem for the bootloader // as we are not enabling any interrupts. // #if defined(TARGET_IS_TM4C129_RA0) #define ROM_EMACInit \ ((void (*)(uint32_t ui32Base, \ uint32_t ui32SysClk, \ uint32_t ui32BusConfig, \ uint32_t ui32RxBurst, \ uint32_t ui32TxBurst, \ uint32_t ui32DescSkipSize))ROM_EMACTABLE[8]) #endif
But what about TM4C129_RA2? Did somebody forget to add the define for it or was this issue fixed in ROM of revision A2?
Thanks Amit.
But there are still questions open, so let me ask very specific to get specific answers:
These questions are referring to the bootloader code in the TivaWare 2.1.3.156 (the general version for no specific hardware)
Regards,
Rainer
Update:
I made an objdump of the bootloader provided by TI.
1. SysCtlClockFreqSet is not contained in the axf, so it is being used from ROM
2. EMACInit is not contained, so it is being used from ROM. I noted meanwhile that ROM_EMACInit is "allowed" for RA1 and RA2 in rom.h
3. GPIOPadConfigSet is not contained, so it's being used from ROM.
From the makefile in boot_emac_flash (and all others in TivaWare), I can see that TARGET_IS_TM4C129_RA0.
So, all examples are compiled for RA0. I guess that's on purpose to provide all customers with a working example, right?
Regards,
Rainer
Hi Amit,
I know. But have a look at your own code:
// // Define ROM_SysCtlClockFreqSet() for snowflake RA0. Even though this function // is deprecated in RA0 ROM, the function operates correctly when // SYSCTL_MOSCCTL register is configured correctly prior to calling this // function. //
This stems from TI! You explicitely use SysCtlClockFreqSet() from ROM despite being deprecated!
And this works for RA2 as well.
Best regards,
Rainer