Quantcast
Channel: Processors forum - Recent Threads
Viewing all articles
Browse latest Browse all 17527

RTOS/PROCESSOR-SDK-OMAPL138: IPC MessageQ Example DSP Core hangup

$
0
0

Part Number:PROCESSOR-SDK-OMAPL138

Tool/software: TI-RTOS

Hello everyone,


I am currently using an OMAPl138 LCDK and want to use the IPC examples that came with the RTOS SDK to base some applications that can communicate between the ARM running Linux and the DSP running RTOS. I am using the Linux and RTOS SDKs 5.00.00.15 and booting from SD Card (2 Partitions). Following the IPC Quick Start Guide (processors.wiki.ti.com/.../Processor_SDK_IPC_Quick_Start_Guide) as well as trying the IPC Install Guide (processors.wiki.ti.com/.../IPC_Install_Guide_Linux. Using make ti-ipc-linux-examples to rebuild the examples works, while make -f ipc-bios.mak all fails with the terminal output:

julian@julian-ThinkPad-X230:~/ti/ipc_3_47_02_00$ make -f ipc-bios.mak all
building ipc packages ...
making all: Di 11. Sep 16:48:02 CEST 2018 ...
======== .interfaces [./packages/ti/grcm/] ========
======== .interfaces [./packages/ti/ipc/] ========
======== .interfaces [./packages/ti/ipc/family/omap54xx/] ========
======== .interfaces [./packages/ti/ipc/family/omapl138/] ========
======== .interfaces [./packages/ti/ipc/family/tci6614/] ========
======== .interfaces [./packages/ti/ipc/family/tci6638/] ========
======== .interfaces [./packages/ti/ipc/family/vayu/] ========
======== .interfaces [./packages/ti/ipc/ipcmgr/] ========
======== .interfaces [./packages/ti/ipc/mm/] ========
======== .interfaces [./packages/ti/ipc/namesrv/] ========
======== .interfaces [./packages/ti/ipc/remoteproc/] ========
======== .interfaces [./packages/ti/ipc/rpmsg/] ========
======== .interfaces [./packages/ti/ipc/tests/] ========
======== .interfaces [./packages/ti/ipc/transports/] ========
======== .interfaces [./packages/ti/pm/] ========
======== .interfaces [./packages/ti/sdo/ipc/] ========
making package.mak (because of package.bld) ...
js: "/home/julian/ti/xdctools_3_50_05_12_core/packages/xdc/bld/BuildEnvironment.xs", line 243: xdc.services.global.XDCException: xdc.bld.ROOTDIR_NOT_SET: 'rootDir' has not been set for the target gnu.targets.Linux86_64; define 'rootDir' in /home/julian/ti/ipc_3_47_02_00/ipc-bios.bld
gmake[1]: *** No rule to make target `package.mak', needed by `.interfaces'.  Stop.
gmake: *** [packages/ti/sdo/ipc/,.interfaces] Error 2
ipc-bios.mak:140: recipe for target 'all' failed
make: *** [all] Error 2

I do not know where exactly to set the root directory (and where to set it to), or if this even causes all the problems, since running the make examples run from the linux sdk directory works normally but I cannot get the MessageQ (or Ping) Examples to run on the DSP Core. Building the IPC examples I moved them to the boards file system using scp and tried running the application with ./app_host DSP after I modified the rproc-dsp-fw symbolic link to the server_dsp.xe674 binary for the example application. This results in the application starting but hanging with the console output at:

root@omapl138-lcdk:~# ./app_host DSP
--> main:
--> Main_main:
--> App_create:
^CIpc: Caught SIGINT, calling Ipc_stop...

I slightly modified the Dsp main c-file to print a line before and after each function call, to pin point where the hangup occured, since I assumed the DSP might not be creating the MessageQueue. The trace in /debug/remoteproc/remoteproc0/trace0 reads as follows after this:

root@omapl138-lcdk:/# cat /debug/remoteproc/remoteproc0/trace0
3 Resource entries at 0xc3100000
[t=0x00232330] xdc.runtime.Main: --> main:
[t=0x0023771b] xdc.runtime.Main: Pre Error Init
[t=0x0023b19f] xdc.runtime.Main: Post Error Init
[t=0x0023f18b] xdc.runtime.Main: Task Params Init
[t=0x00242cc1] xdc.runtime.Main: Params Set -> Create Task
[t=0x0025f054] xdc.runtime.Main: Task Created
[t=0x002633ef] xdc.runtime.Main: Starting BIOS
registering rpmsg-proto:rpmsg-proto service on 61 with HOST
[t=0x00000001:e028a669] xdc.runtime.Main: NameMap_sendMessage: HOST 53, port=61
[t=0x00000001:e029d3d7] xdc.runtime.Main: --> smain:

The modified part of MainDsp.c is as follows:

Int main(Int argc, Char* argv[])
{
    Error_Block     eb;
    Task_Params     taskParams;

    Log_print0(Diags_ENTRY, "--> main:");

    /* must initialize the error block before using it */
    Log_print0(Diags_ENTRY, "Pre Error Init");
    Error_init(&eb);
    Log_print0(Diags_ENTRY, "Post Error Init");
    /* create main thread (interrupts not enabled in main on BIOS) */
    Task_Params_init(&taskParams);
    Log_print0(Diags_ENTRY, "Task Params Init");
    taskParams.instance->name = "smain";
    taskParams.arg0 = (UArg)argc;
    taskParams.arg1 = (UArg)argv;
    taskParams.stackSize = 0x1000;
    Log_print0(Diags_ENTRY, "Params Set -> Create Task");
    Task_create(smain, &taskParams, &eb);
    Log_print0(Diags_ENTRY, "Task Created");
    if (Error_check(&eb)) {
        System_abort("main: failed to create application startup thread");
    }
    Log_print0(Diags_ENTRY, "Starting BIOS");
    /* start scheduler, this never returns */
    BIOS_start();

    /* should never get here */
    Log_print0(Diags_EXIT, "<-- main:");
    return (0);
}

I tried running the MessageQApp that is part of the tisdk-server-extra-rootfs filesystem I am using, if I manually set the symbolic link to /lib/firmware/ipc/ti/ti_platforms_evmOMAPL138_DSP/messageq_single.xe674 and restart the dsp with echo 'start' > /sys/class/remoteproc/remoteproc0/state it works fine (same for the ping_rpmsg prebuilt binaries). 

Additionally ever since I rebuild the filesystem and kernel to boot from SD Card there's a mismatched VGA Output that my monitor won't display since it's "analog is out of range", this was no issue with the out of box SD card partitions. I appreciate any help on this matter since it completely blocks me from any progress to work on applications that can communicate with each other on the two cores which is the main focus of my current project.

Best regards

Julian


Viewing all articles
Browse latest Browse all 17527

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>