In Water Vel Sensor FFT SD Logging Test
Test Details
Date: 2020-07-08 to 2020-07-15
Location: (-37.844963, 145.210917)
Hardware ID: 5K6
BoSL Velocity Database ID: VEL_SD_TEST
Description: Logging of FFT output of velocity sensor to determine the best way to extract velocity information and determine the effect of different speed particles.
Data:
1. CSV file uploaded to: http://www.bosl.com.au/IoT/testing/a.php, SITE ID: VEL_SD_TEST,
2. CSV file retrieved from SD card
3. CSV file retrieved from hach velocity sensor
Hardware
A BoSL Velocity sensor is to be installed next to a hach probe. The BoSL sensor is to be connected to an Arduino Uno with SIM5320 shield and SD card reader. Wiring is as follows.
BoSL Velocity | Arduino Uno |
---|---|
GREEN | 5V |
HALF GREEN | GND |
ORANGE | D7 |
BLUE | A1 |
BROWN | A0 |
SD Card Shield | Arduino Uno |
---|---|
5V | 5V |
GND | GND |
CS | D6 |
MISO | D12 |
SCK | D13 |
MOSI | D11 |
The SD card should be format as FAT16 and empty before inserted. Only remove the SD card when the blue "W" LED is flashing on the SIM5320, else corruption of data may occur.
Code
Code to be uploaded to Arduino Uno: File:SIM5320SD.ino
Velocity sensor:
File:Velocity Code.zip
The board selected in the Arduino IDE should be: Arduino Pro/Pro Mini 3V3 8 MHz
To upload code to the velocity sensor. The velocity sensor should be wired
BoSL Velocity | USB - TTL Converter |
---|---|
GREEN | 5V |
HALF GREEN | GND |
ORANGE | RESET |
BLUE | RX/TX |
BROWN | TX/RX |
Note: the RX/TX labeling is not always constant so both combinations may need to be tried.
Data Format
1.
This is a CSV with sample line:
02/07/20 08:44:00 AM,10 ,,,,,,52 ,0 ,,,,
[DATE] , [LOG ID],,,,,,[VEL],[VEL SD],,,,
DATE -- datetime of logging (UTC)
LOG ID -- number incremented each log. Used to synchronize with logs on SD card. Reset on power up.
VEL -- Calculated velocity (mm/s).
VEL SD -- Calculated standard deviation of velocity FFT peak (mm/s).
2.
This is a CSV with sample line:
6 ,,,1331.67,26003.81,...[x128 total]...,17.86,J ,19.69 ,,,,276 ,214
[LOG ID],,,[VEL BIN x128] ,[J],[SCALE],,,,[VEL],[VEL SD]
LOG ID -- number incremented each log. Used to synchronize with logs on SD card. Reset on power up.
[VEL BIN x128] -- amplitude of velocity bin of FFT, lowest frequency bin first.
[J] -- Break character to signal end of FFT
[SCALE] -- Scale factor which all the raw data has been multiplied by to achieve a good FFT result. Not needed to be compensated for in FFT bin data.
VEL -- Calculated velocity (mm/s). (Same as upload)
VEL SD -- Calculated standard deviation of velocity FFT peak (mm/s). (Same as upload)
3.
This is a CSV with sample line:
19/JUN/20 16:02 0.081 0.12
[DATE] [TIME] [LEVEL] [VEL]
[DATE], [TIME] -- datetime of logging timezone of logger. Not always same as BoSL date
[LEVEL] -- water depth (m)
[VEL] -- Water velocity (m)
Data
1. File:In water velocity sensor FFT sd logging test 1.csv
2. File:In water velocity sensor FFT sd logging test 2.1.csv, File:In water velocity sensor FFT sd logging test 2.2.csv, File:In water velocity sensor FFT sd logging test 2.3.csv
3. File:In water velocity sensor FFT sd logging test 3.csv
In the second week of the test the following data was collected.
1. File:In water velocity sensor FFT sd logging test 1 week2.csv
2. File:In water velocity sensor FFT sd logging test 2 week2.csv
3. File:In water velocity sensor FFT sd logging test 3 week2.csv
Week 3:
Week 4: