Software for recording measurements made by sensors
1.0
2021-03-18
Displays on the screen values of magnitudes measured and sent to the RS232 serial port of a computer
- Download
Arduino IDE
- Install Arduino IDE
- Load /src/RandomData_Generator.ino into the Arduino IDE, select an Arduino UNO board, select the serial port and upload the Sketch.
- Download
Processing IDE
- Install Processing IDE
- Load /src/SensorViewer.pde into the Porcessing IDE
- Configure the files: serialport.json, sensorviewer.json and parameters.json
- In the Sketch menu select Run
- serialport.json
JSON file for the configuration of the connection to the RS232 port
- sensorviewer.json
JSON file for the configuration of the sensor value records
- parameters.json
JSON file for the configuration of the magnitudes and units of measurement that will be displayed
Example configuration in MacOS:
This software can be tested by loading in an Arduino UNO the file /src/RandomData_Generator.ino, the configuration files corresponding to this example are in /src/configfiles.
- serialport.json
{
"SerialPort": "/dev/cu.usbserial-1470",
"BaudRate": 9600,
"DataBits": 8,
"StopBits": 1,
"Parity": "N"
}
- sensorviewer.json
{
"Reading_Frequency": 5000,
"Field_Separator": ";",
"Dumpfile": 1,
"Filename": "dumpfile.txt",
"AddDateAndTime": 1
}
Parameterization
Reading_Frequency
Frequency in milliseconds for saving data to file.
Field_Separator
Data separator.
Dumpfile
1 Save the data to a file.
0 Data display only.
Filename
Filename where the data will be saved.
AddDateAndTime
1 The first column will store the date and time.
0 The first column will store the values of the first magnitude.
- parameters.json
[
{
"parameter":"TDS",
"unit":"ppm"
},
{
"parameter":"Temperature",
"unit":"°C"
},
{
"parameter":"Conductivity",
"unit":"mS/cm"
},
{
"parameter":"Salinity",
"unit":"PSU"
},
{
"parameter":"Depth",
"unit":"m"
},
{
"parameter":"pH",
"unit":""
}
]