Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Real Time Graph stops to replot while I click the main window
Forum Updated to NodeBB v4.3 + New Features

Real Time Graph stops to replot while I click the main window

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 223 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    Daniele90
    wrote on last edited by
    #1

    Hi everybody,
    I have a very simple main window with a graph, a start button, and a stop button. The start button sends, via serial port, a command to a USB device connected; then the USB device connected starts to send back some data that I want to plot inside the graph. The real-time plot is performed inside
    QObject::connect(&serial, &QSerialPort::readyRead, [&]
    {
    ...
    }
    So, when some data arrives at the serial port, the signal readyRead is managed to collect the data and plot them. Everything works fine unless I click the main window; in that case, for all the time in which I keep pressing the mouse, the serial data are stored in the USB buffer but not handled. When I release the mouse, the replot resumes, without the data stored inside the USB buffer during the click. It seems like the readyRead signal is not handled if I click the main window. How can I solve this problem?
    Thanks in advance,
    Daniele

    K 1 Reply Last reply
    0
    • D Daniele90

      Hi everybody,
      I have a very simple main window with a graph, a start button, and a stop button. The start button sends, via serial port, a command to a USB device connected; then the USB device connected starts to send back some data that I want to plot inside the graph. The real-time plot is performed inside
      QObject::connect(&serial, &QSerialPort::readyRead, [&]
      {
      ...
      }
      So, when some data arrives at the serial port, the signal readyRead is managed to collect the data and plot them. Everything works fine unless I click the main window; in that case, for all the time in which I keep pressing the mouse, the serial data are stored in the USB buffer but not handled. When I release the mouse, the replot resumes, without the data stored inside the USB buffer during the click. It seems like the readyRead signal is not handled if I click the main window. How can I solve this problem?
      Thanks in advance,
      Daniele

      K Offline
      K Offline
      kuzulis
      Qt Champions 2020
      wrote on last edited by
      #2

      @Daniele90 , move QSP to thread.

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved