Qt Labs Forum » General discussions

Passing signals between different instances

(2 posts)
  • Started 4 months ago by 1DWaveEquation
  • Latest reply from kitsune

  1. Greetings all:
    My main interest is scientific instrumentation and remote control

    I'm wondering if anyone has experimented with passing signals between different running applications? If anyone here is familiar with Labview Datasocket....this is the sort of functionality I'm looking for....to be able to turn a knob on one applicaton, and have a corresponding dial read out on a different application...or even a different computer. (If someone can tell me how to send signals across instances, I think I can figure out the networking part).

    Thanks, one and all!

    Posted: 4 months #
  2. If you're developing this on a Linux (and probably other *nix system) you could use Qt's D-Bus support (http://doc.trolltech.com/4.4/intro-to-dbus.html) which should make this relatively simple.

    If that isn't really an option for you, you could use QLocal{Socket,Server}. You could give each signal a unique int value, so whenever it needs to be transmitted to the remote end the signal's unique value would be sent across the wire, followed by a serialized version of all the arguments. The remote end would see the signal's number and be hard coded to expect certain types of data to follow it, then to emit the signal on its end with that data.

    Using QtDBus would probably be far more flexible and reliable (IIRC, theres a day to have DBus operate over the network as well), but the QLocalSocket/Server method should (hopefully) work as well, although being rather brittle and might be rather hard to support signals that want a return value.

    Posted: 3 months #

RSS feed for this topic

Reply

You must log in to post.



© 2008 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide.
All other trademarks are property of their respective owners.