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.

FEE of TMS570LS3137 Microcontroller

Other Parts Discussed in Thread: TMS570LS3137, HALCOGEN

 

I am trying FEE Driver using the TMS570LS3137. The eeprom size of TSM570LS3137 is 64KByte.I am trying use as much as all eeprom size. My source is not using RTOS. is Firmware architecture.

1. use the parameter offset and length of TI_Fee_ReadSync(). but TI_Fee_WriteSync() isn't use the offset and length. I want to use the offset and length to TI_Fee_WriteSync(). if possible, please help me.

2. I can not be set the HALCoGen for using as much as all eeprom size.

 2.1. I am trying the 1024byte size the Block Index 1 in FEE Block Configuration tap of  HALCoGEN. but does not operated.  Is it the limit of Block size?

 2.2. Can not be set the one FEE Block index1 to 64Kbyte?

To use the 64Kbyte size, how do i need to set the HALCoGen?

8713.TMS570_FEE.zip

  • Hi, did you try out the example that ships with HalCoGen? The example file example_TI_Fee_Write_Read.c can also be found in the examples folder: ../HALCoGen/examples
  • Yes, I did try the example using TI_Fee_Write_Read.c.
    can to write/read the 64kByte using the Ti_Fee_Write_Read.c?
    can set the offset and length of write function using the Ti_Fee_Write_Read.c example?
    For reply, I don't understand.

  • Hi,

    There might be a disconnect on the question of 64K bytes. That is the physical size of the *flash* memory that is being used to emulate EEPROM in the FEE driver.

    Because it is flash, you can't erase and reprogram bytes at a time like you can do with true EEPROM. And normally an external EEPROM has more W/E cycles than the flash memory we have on chip.

    So what the FEE module does is:

    1) allow you to store 'blocks' of data in this area of flash.

    2) when you update a block it doesn't necessarily erase the flash. it may make a 2nd copy of the block and then invalidate the old copy. It'll do this until it uses all the flash up within a virtual sector.

    3) when you fill a virtual sector, the FEE will copy only the latest (valid) blocks over to the new virtual sector, then it can
    erase the other one so it can be used again.

    Some comments/conclusions you can draw from this:
    a) you need at least 2 virtual sectors...
    b) you really want all your blocks to be << in size than the virtual sector. You don't want one big block with FEE.
    otherwise you'd be erasing the flash every time you update the block, and you may as well then skip the FEE all-together and just use the area as flash.

    I notice on your HalCoGen screen that you are using 2 virtual sectors and 2 physical sectors.
    So you're only using half of the flash bank. If you want to use it all, you an either configure the virtual sectors to be 4 total, or alternatively you can keep 2 virtual sectors but make each one twice as big (change the start and end sectors to be 0,1 and 2,3).
  • Thank you. your reply.

    The selected 4 virtual sector in order to use full size(64KByte).

    the number of FEE Block selected to 16, and the one block size is 512Byte.

    this case, I succeed to read and write data. because one block size is 512 Byte, the total size is 8KByte(512Byte * 16).

    I tried the block size to 4096 byte. but, I did not succeed a 512byte larger size of block size.

    to use the 64Kbyte size, how do i need to set?

  • Hi Roy,

    That make sense. "Note: The size of all the Data Blocks cannot exceed the Virtual Sector length" - section 2.1.2 of the FEE user's guide.

    So, if you selected 4 virtual sectors of 16k bytes each, you can't configure 64K bytes worth of blocks. In fact i don't think you can configure 16K bytes worth of block because there is some overheaded needed in the sector for record keeping.

    And you probably do not *want* to configure close to 16K worth of blocks, because unless there's room in the virtual sector for multiple copies of the blocks, you'll wind up doing a lot of erasing.

    Maybe I should be really clear, the FEE is more for emulating somthing like a 512-1KByte EEPROM using 64K bytes of flash.
    Ok you can go a little higher.

    But if you have actually got 32K or 64K of data that you want' to store in this bank, the FEE model isn't the right way. You'll need to just treat the block as flash and that means it's more painful to make frequent updates. (as it should be because in reality there is only 64K bytes of *physical* flash... the FEE algo can't 'get around' the reality of the situation - it can only give a different use model which is emulating a *much smaller* EEPROM).