Other Parts Discussed in Thread: SYSBIOS, AM3359
Tool/software: TI-RTOS
Hi,
I have a Beaglebone Black board, and I'm trying to build TI-RTOS applications for it. I don't own an emulator; therefore, I'm trying to load the application binary to a microSD card and boot the board with it. To that end, I'll convert the *.OUT file generated by CCS to a *.BIN file via tiobj2bin utility, rename the result as "app", and put it to the microSD card alongside the MLO file from the Starterware kit.
I have installed Processor SDK RTOS ver.5.02.00.10, which includes:
- SYS/BIOS 6.73.1.01
- AM335x PDK 1.0.13
- CCS 8.2.0
I want to access the GPIO and UART peripherals of the board, so I did some reading and learnt that I must use the Board_init() API from the <ti/board/board.h> file. I created a TI-RTOS Project and included the following lines of code before BIOS_start():
Board_initCfg uiInitCfg = BOARD_INIT_PLL | BOARD_INIT_DDR | BOARD_INIT_UART_STDIO | BOARD_INIT_MODULE_CLOCK;
Board_STATUS iStatus = Board_init(uiInitCfg);
However, I never managed to compile this code. First, the compiler was throwing an "undefined reference to Board_init" error (whose prototype was clearly declared in the included header file), then, for some reason, it's throwing the following linking error (undefined reference to main?) now:
Invoking: GNU Linker
"/home/okancalis/ti/ccsv8/tools/compiler/gcc-arm-none-eabi-7-2017-q4-major/bin/arm-none-eabi-gcc" -mtune=cortex-a8 -marm -Dam3359 -Og -g -gdwarf-3 -gstrict-dwarf -Wall -mfloat-abi=hard -Wl,-Map,"BeagleBoneBlackTest.map" -nostartfiles -static -Wl,--gc-sections -L"/home/okancalis/ti/bios_6_73_01_01/packages/gnu/targets/arm/libs/install-native/arm-none-eabi/lib/hard" -Wl,--defsym,STACKSIZE=0x1C000 -Wl,--defsym,HEAPSIZE=0x400 --specs=nano.specs -o"BeagleBoneBlackTest.out" -Wl,-T"configPkg/linker.cmd" -Wl,--start-group -lgcc -lm -lnosys -lc -Wl,--end-group
makefile:142: recipe for target 'BeagleBoneBlackTest.out' failed
/home/okancalis/workspace_v8/BeagleBoneBlackTest/Debug/configPkg/package/cfg/app_pa8fg.oa8fg: In function `.LANCHOR40':
app_pa8fg.c:(.data.ti_sysbios_knl_Task_Object__table__V+0x28): undefined reference to `taskFxn'
/home/okancalis/ti/bios_6_73_01_01/packages/gnu/targets/arm/rtsv7A/lib/boot.aa8fg(startup.oa8fg): In function `gnu_targets_arm_rtsv7A_startupC':
/db/ztree/library/trees/xdctargets/xdctargets-r09/src/gnu/targets/arm/rtsv7A/startup.c:75: undefined reference to `main'
collect2: error: ld returned 1 exit status
gmake[1]: *** [BeagleBoneBlackTest.out] Error 1
gmake: *** [all] Error 2
makefile:138: recipe for target 'all' failed
I think I have sufficient knowledge on the scheduling part of SYS/BIOS (I've watched the online workshop), but I have almost no clue on how to proceed in my current situation. Could you please help?
(I've attached the RTOS Project in case it helps.)