and how everything fits together
All of these are “analog”
“Analog transmission is a method of conveying […] information using a signal which varies in amplitude, phase, or some other property”
Most “common sense” since it can vary
Bus capacitance, stray inductance and resistances, all affect the analog signal massively.
For the communication to be reliable,
we need it to be digital.
The byte is a unit of digital information. It is the smallest addressable unit of memory in many computer architectures.
A bit is the smallest unit of storage. The modern de facto standard of eight bits in a byte permits binary values 0 through 28=255 for one byte. Modern architectures typically use 32- or 64-bit words, built of four or eight bytes.
once again from Wikipedia:
A duplex communication system is a point-to-point system composed of two or more connected parties or devices that can communicate with one another in both directions.
Basically a metronome for digital synchronous circuits.
|RX is controlled||no start bit||set 1 baud rate|
|RX is unpredictable||need start bit||set 2 baud rates|
|RX is controlled||clock signal can be antenna||clock always on|
|RX is unpredictable||data only live when needed, no clock||no clock|
Basically sum of the data and divide it
eg, if the data is 10001100, parity bit is 1:
TX 🡒 RX
RX 🡐 TX
SDA ⟺ SDA
SCL 🡒 SCL
MOSI 🡒 MOSI
MISO 🡐 MISO
SCK 🡒 SCK
SS 🡒 SS
We don’t really need to know the next few for cup, they are mostly used for other industrial purposes
These are all differential protocols. They usually don’t exist for normal microcontrollers since it’s difficult to implement
D+ ⟺ D+
D- ⟺ D-
Probably no time to do interference separately, it’s boring anyways and it only really occurs for i2c so:
tl;dr, if you need to use i2c (most probably will):
wherever possible (mostly between µC) opt for UART as it’s more stable and the complex hardware implementation is done for us already.
SPI may be preferred but slave mode is not always well implemented in hardware, and software emulation is not that good
But we cannot escape i2c, and it’s not THAT bad anyways, mostly just BNO055’s implementation and wonky pull ups.