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.

RTOS: Problems running Sys/Bios on OMAP-L138

Other Parts Discussed in Thread: OMAP-L138

Tool/software: TI-RTOS

Hello Community,

i have a Mity-DSP with OMAP-L138 here and see some difficulties when running my application from SPI-Flash.

It is the NDK Clientexample wit server.

If i run the applicatioon with the mity-DSP gel file after resetted Device all works fine.

I then successfull flashed the application to the SPI via u-boot and started from there.

My Programm looks like:

Main

{

blink some LED

UARTOUT some Debug Info

BIOSStart()

}

alivetask

{

Blink LED

}

After some investigations i found out that SYS/Bios is not started .

To verify that i excluded the NDK Functionality so that only the alive task is left.

I see Blinking LED and UART-communication before SYS/BIOS Start.

But even with only one task SYS/Bios will not start.

Can someone tell me what i am missing?

Many thanks in advance for any help.

Regards Martin

  • Hi Martin,

    How is the UART getting set up? Are you using interrupts with the outputting in main()? If so, that's a problem. Also, you are calling BIOS_start...not BIOSStart...correct?

    Can you look at Tools->ROV to see the state of the system? You might have blown a stack or had an exception.

    Todd
  • Hi Todd,
    yes i am calling BIOS_start(), BIOSStart() leads to unresolved Symbol.
    UART is not using interrupt for Sending.

    Configuration as below:
    /* Enabling the PSC for UART1.*/
    PSCModuleControl(SOC_PSC_1_REGS, HW_PSC_UART1, PSC_POWERDOMAIN_ALWAYS_ON,
    PSC_MDCTL_NEXT_ENABLE);
    UARTPinMuxSetup(1, FALSE);
    /* Enabling the transmitter and receiver*/
    UARTEnable(SOC_UART_1_REGS);
    /* 1 stopbit, 8-bit character, no parity */
    config = UART_WORDL_8BITS;

    /* Configuring the UART parameters*/
    UARTConfigSetExpClk(SOC_UART_1_REGS, SOC_UART_1_MODULE_FREQ,
    BAUD_115200, config,
    UART_OVER_SAMP_RATE_16);
    /* Enabling the FIFO and flushing the Tx and Rx FIFOs.*/
    UARTFIFOEnable(SOC_UART_1_REGS);

    /* Setting the UART Receiver Trigger Level*/
    UARTFIFOLevelSet(SOC_UART_1_REGS, UART_RX_TRIG_LEVEL_1);


    ROV Exception shows "No Data to display"
    TASK module sees IdleTask Running no breakpoint reached in my Alive_Task.
  • What is the state of the Alive_Task? You can select the CallStack tab to see what it was doing.
  • Hi Todd,

    sry but The CallStack Tab is completly empty. even if i loadmy app.out....

    Regards martin

  • I Have some additional Info:
    In Register CPSR i see "i" is 1 means IRQ disabled. Als "F".
    If i tried to call "CPUSwitchToPrivilegedMode();" i got a jump to Adress 0x00 ?

    This only happens if i load and run my app after u-boot.

    If i load and run my app directly after Reset Programm worked.

    Hope this helps ?
    Regards Martin
  • Additional Question:
    When does BIOS_Start() switches from SystemMode to Abort please?
    Regards Martin
  • Ok further results:
    i added startup.c to my application and i see that start_boot() was passed and then main() called.
    The alive Task is executed once and after that PC stops on loop0 (_CPUAbortHandler).
    Mode Bits in CPSR-Register shows that with 0b10111 (which is Mode ABORT).
    Todd do you have any other Hints what to do ?
    Many thanks in advance
    Martin
  • Can you please set a breakpoint at BIOS_start and then open ROV->Task->Detailed and ROV->Task->CallStack and paste the results to the thread?

    Then continue the application and halt the target and do it again.

    For example:

    Also, please don't play with the CPSR registers. Let's minimize the number of things you are playing with.

    Todd

  • Hi Todd,

    thanks for your answer. attached you can see detailed view of ROV-Tasks.

    The tab CallStack is not available. How to enable that?

    FYI i use CCS V6.2

    Furthermore after u-boot has passed i halt -u-boot and start debugSession.

    As you can see in following Picture Uart-Output works.

    Many Thanks for your help Todd.

    Regards Martin

  • You have an older version of SYS/BIOS which does not have CallStack in ROV.

    Can you attach the code to AliveTask? If you set a breakpoint in it and run, does the breakpoint get hit?

    Todd
  • Yes if i put a BP in the alive Task it get hit but only the first time when the task is spawned.
    After that Programm hangs.
    Regards Martin
  • Hi Todd,

    Problem solved.

    I had to put following just befor Bios_start() function:

    		asm(" mrc p15, #0, r0, c1, c0, #0\n\t"
    		" orr r0, r0, #0x00002000\n\t"
    		" mcr p15, #0, r0, c1, c0, #0\n\t");

    Regards

    Martin