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.

CC2340 and I2C driver

Other Parts Discussed in Thread: SYSCONFIG, CC2340R5

Hi,

Our current project uses a cc2340 chip for Bluetooth. 

With the SDK Version:simplelink_cc23xx_sdk_6_20_00_01_eng there is an issue once the I2C driver is opened (I2C_Open is called), the Bluetooth stops working.

  • Hi Chris,

    Thank you for your interest for our new device.

    This issue is likely to be due to a software bug in the kernel implementation of SDK 6.20.

    I recommend you migrate to SDK 6.30 (now available on the MySecureResources folder) where the issue mentioned before has been fixed.

    Best regards,

  • Thank you.  I am trying out the new SDK now but it seems to have a faultISR when we try to call the xQueueSend function.

  • Hi,

    Could you please share the code and example you are using?

    Can you also share details on your testing system? What is the I2C device you are interfacing with?

    Best regards,

  • Ok, I have managed to figure out that I had not configured all of code composer to use the new SDK and sysconfig.  Now I think I have done that, but get this error when I build.


    Building file: "../tsx_app.syscfg"
    Invoking: SysConfig
    "C:/ti/ccs1200/ccs/utils/sysconfig_1.14.0/sysconfig_cli.bat" -s "C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/.metadata/product.json" --script "C:/Projects/KAZ/TSX/Source_TSX/tsx_app_cc2340r5/tsx_app.syscfg" -o "syscfg" --compiler ticlang
    subdir_rules.mk:16: recipe for target 'build-1865349745' failed
    Device not found: CC2340R5RKP. This device may be available in a newer version of SysConfig
    gmake: *** [build-1865349745] Error 1
    gmake: Target 'all' not remade because of errors.

    **** Build Finished ****

  • Hi,

    This last error might be due to CCS using "its own" SysConfig installation. You should re-configure CCS to make sure it uses the patched SysConfig (i.e. the one downloaded on the MySecureResources folder).

    (More details can be found in the quick-start guide, in the User's Guide).

    I hope this will help,

    Best regards,

  • Yes that did help.  Now I get this build error.  (Almost there)

    Building target: "tsx_app_cc2340r5.out"
    Invoking: Arm Linker
    "C:/ti/ccs1200/ccs/tools/compiler/ti-cgt-armllvm_2.1.2.LTS/bin/tiarmclang.exe" @"C:/Projects/KAZ/TSX/Source_TSX/tsx_app_cc2340r5/Release/syscfg/ti_ble_app_config.opt" @"C:/Projects/KAZ/TSX/Source_TSX/tsx_app_cc2340r5/Release/syscfg/ti_build_config.opt" @"C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/source/ti/ble5stack_flash/config/build_components.opt" @"C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/source/ti/ble5stack_flash/config/factory_config.opt" -march=thumbv6m -mcpu=cortex-m0plus -mfloat-abi=soft -mlittle-endian -mthumb -Oz -DCC23X0 -DDeviceFamily_CC23X0 -DNVOCMP_NWSAMEITEM=1 -DFLASH_ONLY_BUILD -DUSE_RCL -DFREERTOS -DNVOCMP_POSIX_MUTEX -DBOARD_DISPLAY_USE_UART=0 -DBOARD_DISPLAY_USE_UART_ANSI=0 -DHAL_IMAGE_B -DICALL_EVENTS -DICALL_JT -DICALL_LITE -DICALL_MAX_NUM_ENTITIES=6 -DICALL_MAX_NUM_TASKS=3 -DMAX_NUM_BLE_CONNS=1 -DPOWER_SAVING -DOSAL_SNV=1 -DSECURITY -DTBM_ACTIVE_ITEMS_ONLY -DUSE_ICALL -DDEBUG_IGNORE_LF -gdwarf-3 -Wl,-m"tsx_app_cc2340r5.map" -Wl,-i"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source" -Wl,-i"C:/Projects/KAZ/TSX/Source_TSX/tsx_app_cc2340r5/Release/syscfg" -Wl,-i"C:/Projects/KAZ/TSX/Source_TSX/freertos_builds_CC23X0R5_LAUNCHXL_release_ticlang/Debug" -Wl,-i"C:/ti/ccs1200/ccs/tools/compiler/ti-cgt-armllvm_2.1.2.LTS/lib" -Wl,--reread_libs -Wl,--define=FLASH_ONLY_BUILD=2 -Wl,--diag_suppress=16002-D -Wl,--diag_suppress=10247-D -Wl,--diag_suppress=10325-D -Wl,--diag_suppress=10229-D -Wl,--diag_suppress=16032-D -Wl,--diag_wrap=off -Wl,--display_error_number -Wl,--warn_sections -Wl,--xml_link_info="tsx_app_cc2340r5_linkInfo.xml" -Wl,--rom_model -o "tsx_app_cc2340r5.out" "./main_freertos.o" "./syscfg/ti_ble_config.o" "./syscfg/ti_devices_config.o" "./syscfg/ti_drivers_config.o" "./Application/Sensor.o" "./Application/TSX.o" "./Application/TSX_states.o" "./Application/database.o" "./Application/demo.o" "./Application/digipile.o" "./Application/i2c.o" "./Application/lcd.o" "./Application/simple_peripheral.o" "./Application/uart.o" "./Application/util.o" "./Application/vdd_closed_loop.o" "./Include/utc_clock.o" "./Profiles/battery.o" "./Profiles/devinfoservice.o" "./Profiles/simple_gatt_profile.o" "./Startup/ble_setup.o" "./Startup/osal_icall_ble.o" "./Startup/rom_init.o" "./Trace/trcAssert.o" "./Trace/trcCounter.o" "./Trace/trcDiagnostics.o" "./Trace/trcEntryTable.o" "./Trace/trcError.o" "./Trace/trcEvent.o" "./Trace/trcEventBuffer.o" "./Trace/trcExtension.o" "./Trace/trcHardwarePort.o" "./Trace/trcHeap.o" "./Trace/trcISR.o" "./Trace/trcInternalEventBuffer.o" "./Trace/trcInterval.o" "./Trace/trcKernelPort.o" "./Trace/trcMultiCoreEventBuffer.o" "./Trace/trcObject.o" "./Trace/trcPrint.o" "./Trace/trcSnapshotRecorder.o" "./Trace/trcStackMonitor.o" "./Trace/trcStateMachine.o" "./Trace/trcStaticBuffer.o" "./Trace/trcStreamingRecorder.o" "./Trace/trcString.o" "./Trace/trcTask.o" "./Trace/trcTimestamp.o" "./iCall/icall_POSIX.o" "./iCall/icall_cc23x0.o" "./iCall/icall_user_config.o" "./iCallBLE/ble_user_config.o" "./iCallBLE/ble_user_config_stack.o" "./iCallBLE/icall_api_lite.o" "../cc23x0_app_freertos.cmd" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/ti/devices/cc23x0/driverlib/lib/ticlang/driverlib.a" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/third_party/spiffs/lib/ticlang/m0/spiffs.a" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/ti/drivers/rcl/lib/ticlang/m0p/rcl_cc23x0.a" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/ti/drivers/lib/ticlang/m0/drivers_cc23x0.a" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/ti/display/lib/ticlang/m0/display_cc23x0.a" -Wl,-l"C:/Projects/KAZ/TSX/Source_TSX/simplelink_cc23xx_drivers/source/third_party/ecc/lib/ticlang/m0/ecc.a" -Wl,-l"C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/source/ti/ble5stack_flash/lib_projects/CC2340R5/OneLib/lib/ticlang/m0p/OneLib.a" -Wl,-l"C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/source/ti/ble5stack_flash/lib_projects/CC2340R5/StackWrapper/lib/ticlang/m0p/StackWrapper.a" -Wl,-lfreertos_builds_CC23X0R5_LAUNCHXL_release_ticlang.lib -Wl,-llibc.a
    makefile:220: recipe for target 'tsx_app_cc2340r5.out' failed

    undefined first referenced
    symbol in file
    --------- ----------------
    NVOCMP_loadApiPtrsMin C:/ti/simplelink_cc23xx_sdk_6_30_00_20_eng/source/ti/ble5stack_flash/lib_projects/CC2340R5/StackWrapper/lib/ticlang/m0p/StackWrapper.a<StackWrapper_OSAL_osal_snv_wrapper.obj>
    PowerCC23X0_notify C:/Projects/KAZ/TSX/Source_TSX/freertos_builds_CC23X0R5_LAUNCHXL_release_ticlang/Debug/freertos_builds_CC23X0R5_LAUNCHXL_release_ticlang.lib<PowerCC23X0_freertos.o>
    PowerCC23X0_qualifyLfClock ./syscfg/ti_drivers_config.o
    PowerCC23X0_setLfClockSource ./syscfg/ti_drivers_config.o

    error #10234-D: unresolved symbols remain
    error #10010: errors encountered during linking; "tsx_app_cc2340r5.out" not built
    tiarmclang: error: tiarmlnk command failed with exit code 1 (use -v to see invocation)
    gmake[1]: *** [tsx_app_cc2340r5.out] Error 1
    gmake: *** [all] Error 2
    makefile:213: recipe for target 'all' failed

    **** Build Finished ****

  • Hi,

    Yes, almost there :)

    Looks like your project is missing a few includes...

    > NVOCMP_loadApiPtrsMin 
    Looks like you are missing the file nvocmp.c (from <SDK>\source\ti\common\nv\nvocmp.c)
    1- Add the following path to the search path: ${COM_TI_SIMPLELINK_CC23XX_SDK_INSTALL_DIR}/source/ti/common/nv
    2- Add a link to this file in Drivers/NV

    > PowerCC23X0_notif, PowerCC23X0_qualifyLfClock, PowerCC23X0_setLfClockSource
    It looks like the driver library used is still the one from the previous SDK version. In the library include menu change {COM_TI_SIMPLELINK_CC23XX_SDK_INSTALL_DIR}/source/ti/drivers/lib/ticlang/m0p/drivers_cc23x0.a into {COM_TI_SIMPLELINK_CC23XX_SDK_INSTALL_DIR}/source/ti/drivers/lib/ticlang/m0/drivers_cc23x0.a

    I hope this will help,

    Regards,

  • I have it working now.  Thanks.