It is possible to save the raw data to a database via the HMI. Every I/O type can be saved by opening the context menu of an I/O control. When data is saved to the database a "disc" icoon or the text "Database logging On" is shown on the form and the saved I/O value is presented bold. Digital I/O is saved everytime the I/O is changed, analogue I/O is polled and writen to the database. The polling frequency is determined by the HMI (it is on the list for making this changable in the context menu). You can save every tag present on the form. When the HMI is stopt, the logging is also halted. Be aware that the information for Database logging is send to the board, so when the HMI is started again, the logging to the database will continue as long as the board isn't reset or the logging is turned of by the user via de context menu. See also the example below.   


 windows 10 logo 100739284 large   RPi Logo Reg SCREEN

For windows a MS Access database is available and for Raspberry it is a MySql database. The communication between the board and the different platforms is identical. Also the database structure is the same for both platforms.  Rows for (new) controls and the creation of the columns for the Tags is done automatic (when not existing they will be created).  


Example: the MS Access database structure

Monitor Access


Below the presentation of the database model. It is very simple. When a new Visual Basic GUI is started with a new name, the application will make a new row in the "Applications"-table. This also applies for the "Tags"-table. When a Tag is selected for DB logging and the tag doesn't exists, the programm will make an entry in the "Tags"-table with the tagname and the I/O-type. This will make the selection of the data easier. All raw data will be writen to the "RAW"-table. The only table that will not change is the "Datatypes"-table. It is recommented to never delete rows from this table. Rows in other tables are dynamic and can be deleted by the user. All tables are related. So when you delete a row from the "Applications"-table, all related rows in the "Tags"- and "RAW"-table are deleted.


DB model


Below a picure of the content of the "RAW"-table.