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.

Cannot program IBL onto I2C EEPROM

I am trying to program the IBL into the I2C EEPROM of the TMS320C6678-EVM demo eval board.

Before doing anything, I powered up the board in "IBL NOR boot on image 0" mode, and got the following messages out of the USB serial port:

Service Status: DHCPC    : Enabled  : Fault    : 002
Service Status: DHCPC    : Disabled :          : 000
Service Status: DHCPC    : Enabled  :          : 000
Service Status: DHCPC    : Enabled  : Running  : 000

These messages repeated every couple of seconds. So, I know that the original I2C EEPROM contains a valid IBL that boots from NOR.

I tried to load the IBL built from source code in C:\ti\mcsdk_2_01_02_06\tools\boot_loader\ibl\src onto the EVM board using the EEPROM writer instructions from C:\ti\mcsdk_2_01_02_06\tools\writer\eeprom\docs\README.txt. To build the IBL, I followed the instructions in C:\ti\mcsdk_2_01_02_06\tools\boot_loader\ibl\doc\build_instructions.txt. When I power cycle the EVM, and wait 10 minutes, nothing comes out of the serial port.

I then tried to write the IBL from http://www.advantech.com/Support/TI-EVM/6678le_download3.aspx (EEPROM51.BIN and EEPROMW3.TXT) onto the I2C EEPROM, using the same instructions. Again, when I power cycle the EVM, nothing comes out the serial port.

It should be noted that the EEPROM writer did not show any error messages. From the serial port output, I can see that the IBL was written and verified by the EEPROM writer.

Did I use the correct IBL?

Are the instructions for using the EEPROM writer to load the IBL out of date? If so, where can I find the correct instructions?

When I use a hex editor to look at the .bin files for the IBL I built, and the IBL from Advantech, it does not look like the data at the start of the file corresponds to the boot parameter table description from table 3-19 and table 2-6 (for the first 4 bytes) in http://www.ti.com/lit/ug/sprugy5b/sprugy5b.pdf. First of all, assuming little Endian, the table length is 0x4000 (bytes are 00 40). Also, the pattern in the first 96 bytes is repeated for the first 1K of the file.

  • Tam,

    Let's first program the pre-build IBL into 6678 EVM without building your own. The pre-build is under: mcsdk_2_01_02_06\tools\writer\eeprom\evmc6678l\bin\ i2crom_0x51_c6678_le.bin.

    Can you try the same procedure and verify this is working or not in your setup? Also please provide your CCS console output to us.

    Regards, Eric

  • I could not find i2crom_0x51_c6678_le.bin in C:\ti\mcsdk_2_01_02_06\tools\writer\eeprom\evmc6678l\bin. It is actually in C:\ti\mcsdk_2_01_02_06\tools\boot_loader\ibl\src\make\bin. I compared this file with the file I originally used using DOS "fc /b", and they are identical.

    GEL file is C:\ti\mcsdk_2_01_02_06\tools\program_evm\gel\evmc6678l.gel

    EEPROM writer is C:\ti\mcsdk_2_01_02_06\tools\writer\eeprom\evmc6678l\bin\eepromwriter_evm6678l.out. I am using the version that was included in the install.

    Contents of eepromwriter_input.txt - only the file_name line has been modified by me:

    ---------------------------------------------------------------------

    file_name  = i2crom_0x51_c6678_le.bin
    bus_addr   = 81
    start_addr = 0
    swap_data  = 0

    ---------------------------------------------------------------------

    Here is a copy of the instructions I used:

    ---------------------------------------------------------------------

    1. Be sure to set the boot mode dip switch to no boot/EMIF16 boot mode on the EVM.

    2. Copy the binary file to writer\eeprom\evmc66xxl\bin directory.

    3. Change the file_name, bus_addr, start_addr and swap_data in writer\eeprom\evmc66xxl\bin\eepromwriter_input.txt if necessary.
       Make sure that file_name is set to the name of your binary file.
       
      *By default the EEPROM writer will load app.dat to DSP memory and write the data to I2C slave
       bus address 81 (0x51) at EEPROM device start byte address 0 with data swap disabled (0).
       
    4. Open CCSv5 and launch the evmc66xx emulator target configuration and connect to core 0.

    5. Load the program writer\eeprom\evmc66xxl\bin\eepromwriter_evm66xxl.out to CCS, be sure evmc66xxl.gel is used in CCS
       and DDR is intialized.

    6. Open the Memory view (in CCSv5, view->Memory Browser), and view the memory address 0x0C000000.

    7. Load your .bin file from step 3 to 0x0C000000:
         * In CCSv5, right click mouse in memory window, select "load memory".
         * Browse and select your binary file.
             - By default, the browse menu only displays .dat files. You will have to change the option
               TI Data Format (*.dat) to Raw Data Format (*.bin) to find your binary file.
         * Click "Next".
         * Change the Start Address to "0x0C000000" if it is not 0x0C000000.
         * Change the Type-size to 32 bits if it is not 32 bits.
         * Make sure the swap checkbox is unchecked.
         * click "Finish".

    8.After the data file is loaded into the memory, run the program (in CCSv5, press F8), it will start to program the
       EEPROM.

    9.When programming is completed, the console will print "EEPROM programming completed successfully", if there
       is any error, the console will show the error message.

    ---------------------------------------------------------------------

    Console output (Run GEL file, load EEPROM writer, run EEPROM writer):

    ---------------------------------------------------------------------

    C66xx_0: GEL Output: Setup_Memory_Map...
    C66xx_0: GEL Output: Setup_Memory_Map... Done.
    C66xx_0: GEL Output: Invalidate All Cache...
    C66xx_0: GEL Output: Invalidate All Cache... Done.
    C66xx_0: GEL Output: GEL Reset...
    C66xx_0: GEL Output: GEL Reset... Done.
    C66xx_0: GEL Output: Disable all EDMA3 interrupts and events.


    [C66xx_0] EEPROM Writer Utility Version 01.00.00.05

    Writing 52072 bytes from DSP memory address 0x0c000000 to EEPROM bus address 0x0051 starting from device address 0x0000 ...
    Reading 52072 bytes from EEPROM bus address 0x0051 to DSP memory address 0x0c010000 starting from device address 0x0000 ...
    Verifying data read ...
    EEPROM programming completed successfully

    ---------------------------------------------------------------------

    Set EVM6678 eval board to "IBL NOR boot on image 0" boot mode:
    - DIP SW3 = (off, off, on, off)
    - DIP SW4 = (on, on, on, on)
    - DIP SW5 = (on, on, on, off)
    - DIP SW6 = (on, on, on, on)

    Monitor USB serial port using Teraterm. I wait 10 minutes, and Teraterm shows nothing.

  • It turns out that the problem is with the serial port. When the USB serial port is used, there is no debug output. When the 3-pin RS232 serial port is used (by switching the shunt positions), there is debug output. I was able to see the "IBL version: 1.0.0.16" startup banner when using RS232, but could not see it when using the USB serial port.

    When using CCS to run the example applications from the user guide, the USB serial port output the same thing that the CCS console displayed. So, I don't understand why the USB serial port does not work when running the IBL.

  • Tam,

    Your seqence of writing IBL to EEPROM looks OK. If you have a JTAG emulator, can you check in NOR boot mode where is the Program Counter (PC)? Then power off the card, change to PCIE boot mode, and power on, where is PC again?

    PCIE boot mode:

    - DIP SW3 = (off, on, on, off)
    - DIP SW4 = (on, on, on, on)
    - DIP SW5 = (on, on, on, off)
    - DIP SW6 = (off, on, on, on)

    Regards, Eric

  • Tam,

    Glad to know you found out it is USB serial port doesn't work.

    I tried following:

    1) Run the POST by loading from CCS, I confirmed that both 3-pin RS-232 and USB serial port worked.

    2) Set the boot mode to NOR boot, I also confirmed that both 3-pin RS-232 and USB serial port worked.

    3) I updated the IBL, and confirmed the test 2) results are the same.

    Only thing tricky is that, when you power up the card in NOR mode, the information is printed out very quickly. However, without power supply you can't open the serial port (e.g, using putty) or the port is inactive. What I did is to configure the serial port first, then power up the EVM card and immediately open the USB serial port. I always have the bootup message showing up. If I am late to open the serial port, I got nothing.

    There is no problem for the USB serial port under IBL case.

    Regards, Eric