Bottom Page

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 Receiving large data stream using Pyserial
#1
I am having a problem where I am streaming binary data from a micro to PC and I want to graph the data. 

The data is binary data coming in around 100 kBits/sec.  So I setup a thread in python to receive the data and I save the last 2 seconds of data to an array. The issue I have ran into is that when I plot the data the receiving thread halts and appears to cause the Pyserial receive buffer to over flow.  That is the threads are not running concurrently. 

I figure I am not the first person to use Python and stream large data real time into python, does anyone have an example of how to do such a thing?

Thanks
Trampas
Quote
#2
You may need to refer to Python's threading topic: https://docs.python.org/2/library/thread...re-example

Avoid the data to be accessed by the receiving thread and plot thread concurrently.
Quote

Top Page

Possibly Related Threads...
Thread Author Replies Views Last Post
  alternative to nested loops for large data set JonnyEnglish 2 154 Feb-19-2020, 11:26 PM
Last Post: JonnyEnglish
  Receiving XML exception from nmap.scan() results. PythonNmap 4 318 Jan-21-2020, 04:41 AM
Last Post: PythonNmap
  Trying to use python-nmap but receiving however python2 or 3 can't find PortScanner. PythonNmap 21 508 Jan-19-2020, 07:54 PM
Last Post: PythonNmap
  First Byte of a string is missing while receiving data over TCP Socket shahrukh1987 3 352 Nov-20-2019, 10:34 AM
Last Post: shahrukh1987
  stream audio from pc to pc floatingshed 2 220 Sep-16-2019, 03:45 PM
Last Post: floatingshed
  pi camera stream is upside down delta1071 3 513 Sep-11-2019, 11:35 AM
Last Post: metulburr
  Need help to read a gzip stream... pythonchakri 5 1,064 Jun-07-2019, 02:33 AM
Last Post: heiner55
  how to load large data into dataframe. sandy 0 529 Feb-01-2019, 06:19 PM
Last Post: sandy
  Stream Data to Text or CSV format ekq378 0 604 Nov-16-2018, 06:32 PM
Last Post: ekq378
  Working with large volume of data (RAM is not enough) evonevo 6 845 Oct-21-2018, 09:24 PM
Last Post: Larz60+

Forum Jump:


Users browsing this thread: 1 Guest(s)