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.

CC2340R5: CC2340R5: RS-485 over Bluetooth LE (BLE)

Part Number: CC2340R5
Other Parts Discussed in Thread: SYSCONFIG

Tool/software:

Hi,

I have been recently asked whether the CC2340R5 device can emulate RS485 over BLE. The answer is YES and it is fairly easy to implement.

The RS-485 format and its impact on data reliability are well described in this video: https://www.ti.com/video/6107769508001.

TI offers RS-485 transceivers requiring the MCU to output data over UART and drive a GPIO high whenever UART data is transmitted - see https://www.ti.com/interface/rs-485-rs-422/overview.html

Interfacing such RS-485 transceiver with a CC2340R5 should then require to configure a GPIO as output (using SysConfig). GPIO_write() should then be called right before UART_write(). If you are in callback mode, the GPIO should then be set low in the callback function. If you are in blocking mode, the GPIO can be set low right after UART_write() returns. 

Now, in order to implement the "BLE" part, you should consider the Data Stream UART over BLE available here: https://github.com/TexasInstruments/ble_examples/tree/simplelink_low_power_f3_sdk-7.40/examples/rtos/LP_EM_CC2340R5/ble5stack/data_stream_UART_over_BLE

I hope this will help,

Best regards,