serial data save in MySQL database and video stream display at host pc

Hi I have an application which I want to show the video streaming as it is now in the IDE but I want to be able to access the blob’s data sent in the terminal so i can save them in MySQL database via another script in the host pc. Is there any way to use the data from the IDE show in the terminal window otherwise is there any other method or programme which i can display the video as normal but interact with the blob data they are sent to virtual serial?
Thanks in advance

Hi, when you execute the print() statement and there’s no IDE connected the data from the print statement is sent over the serial port to the PC via the VCP UART the OpenMV Cam appears as. Any application can open the serial port can read the data. Make sure to set the DTR line high when doing this.

Ok I tried this but I couldn’t get it to work. Here’s how I set it up. I saved the script to the camera then disconnected the IDE (even closed the IDE). On my pc you can see the COM6 port. So I opened up an Arduino IDE and was able to attach at the same baud 115200 but couldn’t see the fps time that you can see when printing it out on OPENMV IDE terminal.

The difference is that when you open the OPENMV ide terminal you have to press the play button to start seeing the stream and with the Arduino (like you would do if you opened the terminal in a python script) this features seems not to be available.

You need to make the DTR line high.

Please use another serial terminal in which you can control the DTR line. Parallax serial terminal will work. Google that term. Parallax serial terminal.

Ok this makes no sense??? Good grief you are like a riddler. :unamused: Who uses Parallex now adays anyway. Hell you have arduino references in your IDE but you can’t get demonstrate how to use the arduino IDE?

Hi, in the passenger seat in a car on my phone. I answer most of these help support emails on my phone. I just thought of a serial terminal that works that I’ve used before.

Arduino IDE does not set the DTR line. Note that the OpenMV Cam does not work with that IDE. We aren’t an Arduino and don’t advertise this…

As for why this behavior it’s because of how the creator of MicroPython programmed the REPL system. He made it not output data on the DTR line being low. Since we are a MicroPython board we act like one using as much of the MicroPython stack as possible.

Since the Arduino IDE doesn’t have a checkbox for setting the line you can’t use it. You can use something like Terra term or other if you want to use a different serial terminal.

Note that in most programming languages you can control these lines directly in the API for a serial port object. For example, a pyserial object has a setDTR() method that causes things to work once turned on.

I think “rister” is misleading my question, all i wna to do is both stream the video to host pc and access the data which arrive at the terminal so i can save them in mysql via a script.


Super doupler ! Thanks, that is awesome :smiley:
You are doing a great job guys, much appreciated