Averaging from Modbus source to MySQL database
I have a device that I am collecting measurements from via Mango. It is configured as a serial Modbus source, and I can poll the device with any frequency needed.
What is the simplest/most efficient method to make use of Mango's "logging properties" (i.e. averaging over an interval) and move these averages into a MySQL database source?
I would really appreciate any thoughts, pointers, or warnings you may have. Thanks!
Quicly looking.... All the features needed for this are in mango. You could use Modbus datasource to read values, meta data points (source) to do the calculation and then SQL datasource to feed the results to MySql. Event handler might be needed to trigger the setting of the SQL data point.
There is one small detail missing from the online help. The SQL update statement should be something like "UPDATE
A='1' ;" When the point value is set mango replaces the question mark with the point value in the update statement.
Another idea is to just use MySQL as Mango's database (either brand new or converting from an existing Derby instance). Then, other applications can directly access the pointValues/pointValueAnnotations tables.