Check out my first novel, midnight's simulacra!

InaMORAta: Difference between revisions

From dankwiki
Line 77: Line 77:


The MEGA publishes measured RPM and water temperature levels, along with the currently applied PWM, to the Heltec over the UART. Values may be published in any order, at any time. These values are published in a human-readable form, one after another with no intervening content. They are of the form `Tf`, `Ri`, and `Pi`, where `f` is a float and `i` is an integer.
The MEGA publishes measured RPM and water temperature levels, along with the currently applied PWM, to the Heltec over the UART. Values may be published in any order, at any time. These values are published in a human-readable form, one after another with no intervening content. They are of the form `Tf`, `Ri`, and `Pi`, where `f` is a float and `i` is an integer.
===UART===
We can transmit from the Heltec to the Arduino directly; the 3.3V high logic level of the Heltec registers as high on the MEGA. Sending from the 5V MEGA directly to the Heltec will damage the latter. We instead go through a TXS0108E level shifter. The 5V line is taken to VB, while the 3.3V line is taken to VA. TX2 (pin 16) on the MEGA is taken to B7 on the level shifter. A7 goes to pin 36 on the Heltec, which is configured as RX2. The Heltec transmits from 17 directly to RX2 (pin 17) on the MEGA. Finally, the Heltec's 5V output is connected to OE on the level shifter.


[[CATEGORY:Projects]]
[[CATEGORY:Projects]]
[[CATEGORY:Hardware]]
[[CATEGORY:Hardware]]