How to analysis the data sending from RAK5205


(Fomi Tong) #1

The data port:

  1. GPS
    Port: APP_PORT_GPS(2)
  2. Battery Level
    Port: APP_PORT_TEMP(3)
  3. LIS3DH sensor
    Port: APP_PORT_ACC(4)
  4. BME680 sensor
    Port: APP_PORT_GAS(5)
    For example(shown on TTN):
    image
    Note: all data are in HEX format
    Now, let’s analysis the above data which are shown on TTN. The first two bytes of data are data flag, and other bytes are sensor data.
  1. Analysis GPS data
    As shown in the above picture, port 2 is GPS data: 01 88 05 37 A9 10 9D 5B 00 C0 F8 00 16
    “01 88” is data flag.
    “05 37 A9” is latitude, and the value of latitude is 34.1929
    “10 9D 5B” is longitude, and the value of longitude is 108.8859
    “00 C0 F8” is altitude, and the value of altitude is 494m
    “00 16” is NmeaSpeed, and the value of NmeaSpeed is 0.22km/h
  2. Analysis battery level
    As shown in the above picture, port 3 is battery level data: 07 02 01 9F
    “07 02” is data flag.
    “01 9F” is battery level, and the value of battery level is 4.15V
  3. Analysis LIS3DH sensor data
    As shown in the above picture, port 4 is LIS3DH sensor data: 03 71 FF 00 FF F0 00 50
    “03 71” is data flag.
    “FF 00” is Acceleration X, and the value is -256mg
    “FF F0” is Acceleration Y, and the value is -16mg
    “00 50” is Acceleration Z, and the value is 80mg
  4. Analysis BME680 sensor data
    As shown in the above picture, port 5 is BME680 sensor data: 02 67 01 30 05 68 21 06 73 25 B4
    “02 67” is data flag.
    “01 30” is Temperature, and the value is 30.4℃
    “05 68” is Humidity flag
    “21” is Humidity, and the value is 16.5%RH=33*500/1000.0, 0x21=33
    “06 73” is Pressure flag
    “25 B4” is Pressure, and the value is 965.2hPa

If you want to know more details, please check the source code of RAK5205 on Github: https://github.com/RAKWireless/RAK5205-WisTrio-LoRa


RAK5205 two weeks of test: some questions/problems
Wistrio RAK5205 not get data on TTN