BLE Firmware Version Read
#include <io>
#include <read>
#include <float>
#include <string>
#include <core>
#include <write>
#include <define>
#include <socket>
#include <bluetooth>
#include <debug>
#define RS232_SPEED 115200
#define WORD_LENGTH WORDLENGTH_8
#define STOP_BITS STOPBITS_1
#define PARITY PARITY_NONE
new str_temp[255];
new ble_fw[50];
main()
{
Init(RS232, RS232_SPEED, WORD_LENGTH, STOP_BITS, PARITY);
debug_init(RS232);
Delay(100);
debug_print("Script started \r\n");
bt_init();
read_buf(SENSOR_BT_FIRMWARE_VERSION, sizeof(ble_fw), ble_fw);
snprintf(str_temp, sizeof(str_temp), "[INFO] Received BLE version: %s\r\n", ble_fw);
debug_print(str_temp);
while(1)
{
Delay(1000);
}
}