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.

OMAP-L138 LCDK: Difficulty downloading prebuilt images

Other Parts Discussed in Thread: OMAP-L138, OMAPL138

I need help understanding what I am doing wrong. I have been trying to read the documentation and the Wikis but I am just getting more lost. Sorry for the length of the post but I wanted to show I have been trying before reaching out to the experts here.

I am new to this family of controllers, but I am not new to embedded systems and small microcontrollers.

As the subject line indicates, I am working with OMAP-L138 LCDK.

I am working in a Linux command line environment. I am not using Code Composer Studio.

I am using Minicom as my serial terminal app on my Linux host machine. I believe I have it configured correctly for using the LCDK since I can boot to the Arago Linux shell from the SD card that came with the LCDK. I also see BOOTME when SW1 has been set to have switches 2 and 4 set to ON (UART2 selected).

I want to work on a simple, no-OS project to get started. It seemed like a good first step would be to download a pre-built file. I chose the fingerprint detection example. I tried to follow the instruction at http://processors.wiki.ti.com/index.php/BIOS_C6SDK_2.0_User_Guide#How_to_Flash_Finger_Print_demo_on_LCDK under the heading 'How to Flash Finger Print demo on LCDK', but I was unsuccessful. Here are the commands I tried to use from the command line.

     mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType C6748_LCDK -erase

     mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType C6748_LCDK -flash_noubl c6sdk_02_00_00_00/demos/flash/lcdk/fingerprint_lcdk.bin

The erase operation seems to complete successfully. But when I try to flash fingerprint_lcdk.bin, it seems to initially operate correctly, but then it hangs with a message "Waiting for SFT on the OMAP-L138..."

After more searching the documentation and wikis, I also tried the following:

     mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType OMAPL138_LCDK -flash_noubl c6sdk_02_00_00_00/demos/flash/lcdk/fingerprint_lcdk.bin

This does not hang at "Waiting for SFT on the OMAP-L138..." It actually seems to load correctly as the results look similar to when I download the uboot image ti-sdk-omapl138-lcdk-01.00.00/board-support/prebuilt-images/u-boot-lcdk.bin. But after I execute the line, when I change the SW1 swttings to switch 1 OFF and switches 2, 3, and 4 ON and press the reset button, nothing seems to happen. There are no messages displayed to the terminal. It almost seems as if there is no bootloader present to launch the application. Based on the command line found on the wiki (shown above as the 2nd command line), since -flash_noubl is used I thought the bootloader was included in the fingerprint_lcdk.bin.

I also tried the following command line to use a pre-built boot loader.

    mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType OMAPL138 -flash ubl_OMAPL138_LCDK_NAND.bin fingerprint_lcdk.bin

This also seemed to download completely without producing any errors, but when I set the SW1 switches back to 1 OFF and 2, 3, and 4 ON and then reboot nothing seems to happen.

I know this should be simple, but I don't know what I am doing wrong. If I do need to add a bootloader during the download process for fingerprint_lcdk.bin, a pointer to where to find the pre-build bootloader for the LCDK and the proper command line to use would be quite helpful. Any guidance is greatly appreciated.

--dave

  • Hi Dave,

    Thanks for providing us all the details regarding what you have tried before posting your question here. The instruction on the BIOS C6SDK wiki for flashing and booting the fingerprint demo apply only to the C6748 LCDK(which is DSP only device). To do the same on OMAPL138 LCDK(which is ARM+DSP device) you need to understand how the OMAPL138 boot loader works. OMAPL138 is a ARM boot device so the ARM comes up first  and needs to wake up the DSP for it to start running the DSP code. The boot sequence for OMAPL138 has been described in detail here:

    http://processors.wiki.ti.com/index.php/OMAP-L138_Bootloader#After_Reset

    The process of waking up the DSP and providing the entry point in memory at which DSP should start executing code is done using a secondary ARM UBL. You can see an example implementation of this UBL in the sample code that is provided on this wiki:

    http://processors.wiki.ti.com/index.php/Boot_Images_for_OMAP-L138

    Note: The LED blink example is designed for the OMAPL138 EVM but the ARM UBL in those examples can be used on any OMAPL138 development platform. You will have to find the entry point (location of _cint00 symbol)of the fingerprint demo code and change the value programmed in HOSTCFG in the ARM UBL. This might be difficult to do since the demo is provided in binary and not in source but you could load the code on the DSP using the emulator and search for this symbol in the disassembly (in CCS go to View->Disassembly after loading code on the DSP)

    Now coming to the question of why the ubl provide in the Linux development kit didn`t work with this demo. The purpose of the UBL provided in linux SDK of the OMAPL138 LCDK  is used only to initialize DDR, PSC, and copy the Uboot to memory and then passes control to the uboot to load linux and the file system so it serves a different purpose than waking up the DSP and providing the correct entry point.

    Hope this helps.

    Regards,

    Rahul

  • Hi Rahul,

    Thank you for your response. I have been having trouble distinguishing what is on the LCDK in terms of OMAP-L138 and the C6748LCDK. I was not aware of the C6748LCDK, so this should help me work out which examples to try to use.

    Since using the fingerprint demo is complicated by needing to find the entry point, I wonder if it would be better for me to try to use a different example. Would using the ARM UBL that you mention from the OMAPL138 EVM with one of the StarterWare examples? Maybe the   OMAPL138_StarterWare_1_10_03_03/binary/armv5/cgt/omapl138/lcdkOMAPL138/gpio/Debug/gpioLed.out   pre-built image.  Or possibly the uart example in the same set of examples.

    If I want to use one of these examples, I think I will need to convert it to a bin file using HexAIS_OMAP-L138.exe.

    Is that correct?

    Thank you very much for your help.

    --dave

  • Dave,

    Are you specifically looking for examples that can boot from flash ? or are trying to find sample applications that you can run on the OMAPL138 LCDK over an emulator. The ARM UBL is required only when you want the device to boot the application. If you have an emulator and code composer v5 setup then you can load ang run code. If you have an emulator and code composer studio setup you can run not only the ARM examples in starterware but also DSP examples from Starterware and BIOS C6SDK. In case of emulation you can run the GEL file scripts provided here to wake up the DSP and load the app .out files over the emulator on the DSP.

    http://processors.wiki.ti.com/index.php/LCDK_User_Guide#CCS_Configuration_and_GEL_Files

    procedure to connect to DSP is similar to one described here:

    http://processors.wiki.ti.com/index.php/How_to_connect_to_the_OMAP-L138/C6748/AM1808_EVM_board_using_CCS%3F

    To flash these binaries you are correct you will have to use the HexAIS tools to create the binary file that can boot from the flash.

     Regards,

    Rahul

  • Hi Rahul,

    Yes, I am really wanting to work with examples that will boot from flash right now. My objective is to learn how the compile, convert to AIS, then flash to LCDK process works.

    If I am following correctly, I should be able to use HexAIS and an appropriate *.ini file to process one of the pre-built *.out examples from StarterWare that are for the OMAPL138 LCDK, then use sfh_OMAP-L138.exe to flash  the UBL you mentioned to me previously and the *.bin file I generate with HexAIS to my LCDK system.

    Is this an accurate description of the process?

    Thanks,

    --dave

  • Hi Rahul,

    I think I have managed to get what I wanted. Based on your response I tried the following.

        mono HexAIS_OMAP-L138.exe -ini OMAP-L138.ini ./OMAPL138_StarterWare_1_10_03_03/binary/armv5/gcc/omapl138/lcdkOMAPL138/bootloader/Debug/boot.out

        mono HexAIS_OMAP-L138.exe -ini OMAP-L138.ini ./OMAPL138_StarterWare_1_10_03_03/binary/armv5/gcc/omapl138/lcdkOMAPL138/uart/Debug/uartEcho.out

        mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType OMAPL138 -flash ./boot.bin ./${FILENAME}.bin

    This did not work for me, I wound up with the "Waiting for SFT on the OMAP-L138" message.

    I went back and reviewed some other forum posts I had read preiviously. But I was looking at them with the knowledge you had given me in your posts to me. I tried the following.

        mono HexAIS_OMAP-L138.exe -ini ./OMAPL138_StarterWare_1_10_03_03/binary/armv5/gcc/omapl138/lcdkOMAPL138/uart/Debug/uartEcho.out

        mono sfh_OMAP-L138.exe -p /dev/ttyUSB0 -v -flashType NAND -targetType OMAPL138_LCDK -flash_noubl ./uartEcho.bin

    This worked. The download completed successfully. When I changed the SW1 values for NAND and reboot, I see the "StarterWare UART echo application" on my terminal.  I think this will get me started on my project.

    Thank you for your help.

    --dave