Seite 1 von 1

Realtime data

Verfasst: 15 Apr 2022, 14:41
von Alan97
Hello,

I want to ask if it is possible to write data in real time to Excel or another database. In RoboPro I have a variable whose value is sent to Excel. The problem is that data is written in Excel only after the program has been executed and not in real time. Thank you for help.

Bild

Re: Realtime data

Verfasst: 15 Apr 2022, 15:02
von fishfriend
Hallo...
Wihtout RoboPro:
As far as i know, you can open a sheet. Tis sheet can be canged from different sources with Excel running. If someone save the sheet, all others get the changing. But this with a TXT?

Maybe 10 years ago, there was a interface in Excel, to read extern data from a serial com. If you running RoboPro you have no other COM to send the Data - or you use a seperat interface mybe to the USB. So you must send the Data to the USB Interface and then read there the Data with Excel.

With best regards
fishfriend
Holger Howey

Re: Realtime data

Verfasst: 15 Apr 2022, 16:21
von vleeuwen
Yes, it is easy possible.
I am doing this in several ways with the use of the RoboPro extension element SLI's.
-) As MQTT messages, (MQTT broker is available an running on the TXT)
Nice to use in combination with Node-Red, saving data (file or SQL) with Node-Red is also possible.
-) Direct to local files on the TXT
-) To a SQLite3 data base (part of the Embedded Civet web server)
-) With a Web Socket (part of the Embedded Civet web server)
-) With a Berkeley socket.
Most of the option are used in the local mode RoboPro, some runs in local an on-line mode)
( On the TXT is already a Civetweb server active, with this one it is also possible to have data communication.
https://github.com/civetweb/civetweb)


Examples of semi real time MQTT data:
The Mq_testPub1 sub routine, the message has an ID and max 5 values:
RoboPro04Mqtt.JPG
RoboPro04Mqtt.JPG (136.6 KiB) 1042 mal betrachtet
The subroutine in use
forum01.JPG
forum01.JPG (99.9 KiB) 1042 mal betrachtet
Example of saving to a file (code example on fischertechnik Github: txt_demo_ROBOPro_SLI/FtTxtExamples/SLI_TxtSliSave4C ):
forum02.JPG
forum02.JPG (95.32 KiB) 1042 mal betrachtet