Skip to content

Implement serial interface #1

@Peque

Description

@Peque

The serial interface should implement the three methods in SerialInterface class.

  • __init__: I would suggest you to hard-code your serial initialization code there. I would suggest you to hard-code your settings and we will think about how to connect to other targets when we need it (i.e.: maybe we could list available targets and let the user choose, or load preferred targets from a local config file, or add a command line option...)
  • send: your code to send a message (assumed previously formatted) through serial.
  • receive: reads up to N bytes from the serial port (I set it to 1024 in my Bluetooth interface). It has a timeout (I set it to 10 ms). So basically, read raw bytes and avoid blocking here. I am assuming you can do that with the serial module you use.

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions