albertaloop / T_SWE_2019_2020

Software for AlbertaLoop's first-generation pod.
MIT License
3 stars 1 forks source link

Initial CANBus design #37

Open mbardwell opened 2 years ago

mbardwell commented 2 years ago

Summary

The current architecture contains two types of client:

  1. "Node": a Teensy microcontroller with a CANBus interface
  2. "Base Station": a laptop with a USB interface

Each client should be capable of interpreting the serialised data sent over the wire. This is best done in a "library" fashion, where the data structure is provided in a configuration file and that library is shared between executables.

One thought that is optional but might make our lives a lot easier: have one PlatformIO project generate all of the Node binaries. This way, it is easy to share the library code. Currently, we have many PlatformIO projects in this repository, which will need to be merged together.

Like many a communication stack, we should aim to structure our architecture after the OSI model. We do not need to have logic for each layer, especially for the minimum viable product (MVP). For example, we will ignore encryption and compression at the moment. I have included a diagram abloop communication v0.1.1.drawio

Description Image
Modified OSI model image
OSI model image
Serialisation implementation details image

Acceptance Criteria

mbardwell commented 2 years ago

https://drive.google.com/file/d/1n_33n3OspavOohZwNWJWEWEBbwVG75p0/view?usp=sharing

mbardwell commented 2 years ago

image

From Drive