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.

Porting serial port service to simpleperipheral

Other Parts Discussed in Thread: BLE-STACK, CC2650STK, SYSBIOS, CC2640

I'm trying to apply the serial port service along with the SDI from https://github.com/ti-simplelink/ble_example

to the simple_peripheral_cc2650stk project. I haven't found a guide on how to port this using the latest ble-stack.

My problem is when I add the line to create the sditask in main.c( SDITask_createTask();), I get the following errors:

>> Compilation failure
makefile:204: recipe for target 'simple_peripheral_cc2650stk_app.out' failed

 undefined                            first referenced
  symbol                                  in file     
 ---------                            ----------------
 ti_sysbios_knl_Event_Params__init__S <whole-program>
 ti_sysbios_knl_Event_construct       <whole-program>
 ti_sysbios_knl_Event_pend__E         <whole-program>
 ti_sysbios_knl_Event_post__E         <whole-program>

error #10234-D: unresolved symbols remain
error #10010: errors encountered during linking; "simple_peripheral_cc2650stk_app.out" not built
gmake: *** [simple_peripheral_cc2650stk_app.out] Error 1
gmake: Target 'all' not remade because of errors.

Any ideas?

Thanks,
Mike.

  • To add UART support to SimpleBLEPeripheral, I suggest you to refer to section 6.3.2 UART in SWRU393_CC2640_BLE_Software_Developer's_Guide.pdf
  • Thank you for your reply.
    I have read this documentation multiple times, it does not help me.
  • Looks like you might be missing a TI RTOS system include for Events, try adding:
    #include <ti/sysbios/knl/Event.h>

    Then rebuild the project. (So it can build the proper TI RTOS library)

    Regards,
    -Rebel
  • Thank you for your reply.

    Yea I thought the same thing, but it is included in sdi_task.c, which is the file where the call to SDITask_createTask takes place, is there any other place it needs to be included?

    Btw, I can't find any documentation about the sdi, is there any?

    Thanks,
    Mike
  • Mike,

    Good catch! Sorry I should have also told you to add 'USE_EVENTS' to your preprocessor defines. (This adds the TI RTOS Event Module to your TIRTOS config file)

    Now you should be able to rebuild (it'll recompile the TI RTOS libraries) and your include should work now.

    Regards,
    -Rebel

  • I tried adding USE_EVENTS, it didn't help though.
    I solved it changing Semaphore.supportsEvents to true in app_ble.cfg. I still don't see why this was the issue.
    When I open the spp_ble_server-project that uses the SDI, this project uses Semaphore.supportsEvents = false, and still builds without any issue. Do you have any idea why this is?

    Thank you for your time,
    Mike

  • Mike,

    I'm not sure either, without the code it's hard to tell. I'm glad you got it working though!

    My best guess is that after you did 'USE_EVENTS', the event module was built but wasn't linked too. Then when you removed the flag, the library remained, so the Linker was able to link to it? What you're seeing is sort of an artifact? Again, it's hard to tell,

    Regards,
    -Rebel