Is it possible to send pysense data via physical cable to our PC/raspberry pi?
-
Hello fellows.
I'm currently working on a project that requires the use of pysense + lopy4. It is the first time i work with them and I'm still looking for information.
I've already see a lot of projects sending data via WiFi, LOrA and so on. But is there any physical alternative, for instances, via USB to send the data to a computer or a processor like raspberrypi?Thank you!
-
@Pedro-Almeida You can for instance use UART, which is robust and simple. Just 3 wires for a bidirectional link. The speed is not very high, but 1-2 MBit/s should be possible with a short link.
With the pysense board, you can simply use the USB interface of the Pysense connected to a PC, where it shows up as a serial interface. The default baud rate is 115200. At the LoPy4, you would use print() or sys.stdout.write() for sending and sys.stdin.read() for receiving. That interface can as well be used as UART 0, allowing you to use the UART API. -
First of all, thank you for the answer.
And it should work as well on raspberry pi right? Since rasp is such a PC as well with USB serial inputs. -
@Pedro-Almeida I can replicate this behavior. But there is little that canbe done in the uftpd code, since it does not get noticed. For uftpd, the session continues to exist.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login