Send/Receive data from Linux

For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
clpie
 
Posts: 21
Joined: Fri Jul 02, 2021 5:38 am

Send/Receive data from Linux

Post by clpie »

Hi there,

I was just wondering what the best method might be to have bi-directional communication with a linux machine, perhaps by serial console?

I was able to connect node.js to the CLUE via serial port and get console output from CLUE, but how do I then send data back to the CLUE? I'd like to have code running on the CLUE that can receive commands or info from a Linux computer via USB.... - is there a way to receive serial data in the circuit python code?

Thank you :D

User avatar
adafruit_support_carter
 
Posts: 29056
Joined: Tue Nov 29, 2016 2:45 pm

Re: Send/Receive data from Linux

Post by adafruit_support_carter »

Take a look at the approach suggested here:
https://learn.adafruit.com/customizing- ... -3096573-5

Basically a secondary serial path you could use for any arbitrary back and forth.

User avatar
clpie
 
Posts: 21
Joined: Fri Jul 02, 2021 5:38 am

Re: Send/Receive data from Linux

Post by clpie »

Thank you -

Do you know if there are any circuit python code examples or libraries for sending/receiving arbitrary data over serial port? I couldn't find any on that page or searching around....

How might I send/receive data in code.py over the additional serial port?


Thanks :)

Locked
Please be positive and constructive with your questions and comments.

Return to “CLUE Board”