I am modifying the bootloader example for the TMS570LS31 to work on the TMS570LC4357 using ethernet communication. At the beginning Fapi functions are copied from Flash to RAM (LR register value is 0x8015637) but it get stuck to
while( FAPI_GET_FSM_STATUS != Fapi_Status_Success );
in Fapi_BlockErase. The FMSTAT register reads 0x0990.
I changed some constants values in Constants.h as below:
/* Specifies the bit mask for determining all address bits exclusive of the offest
imposed by the memory map register */
#define F021_PROGRAM_ADDRESS_MASK 0x07FFFFFFU
/* Specifies the Offset to the TI OTP */
#define F021_PROGRAM_TIOTP_OFFSET 0xF0080000U
/* FMC memory map defines */
#define F021_FLASH_MAP_BEGIN 0x00000000U
#define F021_FLASH_MAP_END 0x003FFFFFU /
#define F021_OTP_MAP_BEGIN 0xF0000000U
#define F021_OTP_MAP_END 0xF000FFFFU
#define F021_OTPECC_MAP_BEGIN 0xF0040000U
#define F021_OTPECC_MAP_END 0xF0041FFFU
#define F021_EEPROMECC_MAP_BEGIN 0xF0100000U
#define F021_EEPROMECC_MAP_END 0xF01FFFFFU
#define F021_EEPROM_MAP_BEGIN 0xF0200000U
#define F021_EEPROM_MAP_END 0xF03FFFFFU
#define F021_FLASHECC_MAP_BEGIN 0xF0400000U
#define F021_FLASHECC_MAP_END 0xF05FFFFFU
#define F021_CPU0_REGISTER_ADDRESS 0xFFF87000U
/* Specific TI OTP Offsets */
#define F021_TIOTP_PER_BANK_SIZE 0x2000U
#define F021_TIOTP_SETTINGS_BASE 0x150U
#define F021_TIOTP_BANK_SECTOR_OFFSET 0x158U
I'm not sure about F021_CPU0_REGISTER_ADDRESS define since I couldn't find this information on the datasheet.
Any help/suggestion is appreciated.
Regards
Valentina