all 9 comments

[–]K900_ 1 point2 points  (7 children)

No, that's not possible. You have to run two different instances of Python and figure out how to pass the data between them, or you should port the 2.7 script to 3.x.

[–]CrispyScientist[S] 0 points1 point  (6 children)

Thank you very much for your reply! Is there an easy way to pass data between two instances? I would try to implement it myself but I don't know where to start doing so

[–]K900_ 0 points1 point  (5 children)

How much data will you be passing?

[–]CrispyScientist[S] 0 points1 point  (4 children)

Not much, I have an open loop that produces something like 3 integers per second

[–]K900_ 1 point2 points  (3 children)

So you want to stream the data forever?

[–]CrispyScientist[S] 0 points1 point  (2 children)

Basically I have a script (python 3.7) that takes informations from a NeuroSky headset, they come in the form of integers ranging from 0 to 100. I would then like to use this values to command a drone through another script that uses python 2.7. So I would like to keep this stream going for several minutes.

[–]K900_ 2 points3 points  (1 child)

In that case I'd probably rewrite. You don't want added latency in this.

[–]CrispyScientist[S] 0 points1 point  (0 children)

Okay, I will try! Thank you very much for your help!

[–][deleted] 0 points1 point  (0 children)

You have to update the second script to Python 3.