I'm trying to transfer data beetween the two scripts. I'm already using the YunMesseger library (https://github.com/plotly/YunMessenger). But it only make the

Arduino -> Python

communication. I would like to know how to make the reverse way.

I would like to point that I'm search for a solution that doesn't involve the use of the Bridge, because I don't want to have concurrency problems.

  • What do you mean by concurrency problems? For example, if you use bridge's mailbox, I'm pretty sure that messages from multiple sources just go into a queue on the Linux side, and the 32u4 can check this queue at it's leisure. – DaveP Feb 25 '15 at 6:02

One option is to use spacebrew. This is a cloud-based service, however you can run your own server which is based on node.js, so it should work on the Yun.

Your Arduino can then send or receive data using yunSpacebrew, and you can connect it to python using pySpacebrew. This is a pure python library, so it ought to run fine on the Yun.

| improve this answer | |
  • Thanks for the comment. I'm aware of spacebrew, however I'm trying to build a service similar to theirs but integrated with other solutions I'm developing. That's why I need to know how to make this communication. Looking at their source files I saw that they use Console.read() in the arduino part, but I couldn't find how they do the python part. – Renan Ferreira Feb 25 '15 at 11:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.