Closed peterantypas closed 8 months ago
Sound like a good idea. On the boat connections can be unreliable. Making the MAIANA more resistant to these is good idea
I reproduced the problem by constructing an adapter on a breadboard. The culprit is the TX_OFF signal. This signal is a 3.3V "high" logic to the MAIANA main board to inhibit transmission. The source of the signal is each adapter's local 3.3V rail.
When the GND contact is severed, the entire MAIANA mainboard is floating at about 10-11V with respect to the adapter's GND, and that causes large reverse current flow into the adapter's 3.3V rail if the TX_OFF signal is high (TX disabled). When the TX_OFF signal is low (pulled directly to GND), MAIANA appears to work until it tries to transmit and then things go haywire.
The solution is to modify all adapters to have a large inline resistor with this signal. 2.2KOhm seems to work well. I will try to find the largest value that is still safe, given that it forms a divider with a 10K pulldown inside MAIANA and it has to drive an NMOS gate.
FYI: On the MacArthur HAT, we have a 4.7k 1k resistor in series between the 3.3V LDO and the TX_OFF switch. Mainly to limit current in case someone shorts the connector to GND.
We also had a user accidentally connect an Ethernet router to the RJ45 connector (easy to mix up when stacked on a Pi), which blew an ESD diode on our board. The 12V ends up coming back out of the TX_OFF pin if you do that. Due to this, we planned to add a diode on TX_OFF for a future rev.
I'm very close to 11.9.0 being ready (like a day before sending to fab). I'll add a diode to TX_OFF now.
I didn't had a chance to test the diode fix yet. So caveat emptor.
Just checked your latest commit, and I think you misunderstood my comment re the diode.
The 12V issue is with the adapter boards, not MAIANA itself. When a 12V powered adapter board is plugged into a regular network router. The 12V will travel via the magnetics in the router back to the adapter board, coming out of the TX_OFF pin.
I don't think much will happen if someone plugs MAIANA itself into a network, as in that case MAIANA won't be powered.
The issue occurs when MAIANA loses the Cat5 GND while plugged into any of the existing adapters. If TX_OFF is pulled to GND, a false, high impedance ground is created via some path that causes MAIANA to brown out during transmission. If TX_OFF is high, the 3.3V rail will see 11+ V from MAIANA and cause the regulator to burn.
I tested the diode and series resistor on the TX_OFF signal and it fixed this. Now if the Cat5 GND is lost, MAIANA stops working which is what should happen.
11.9.1 has addressed this. Back-powering is no longer possible.
One of the pitfalls of designing low power circuits is that said circuits can be inadvertently back-powered from weak power sources.
As it turns out, if the CAT5 cable's "GND" connector is severed, MAIANA can actually run via the UART with its I/Os acting as a "false ground", despite the fact that these pins feature 1.1 KOhm series resistors. This causes unsafe voltages to appear at the adapter and can damage it.
Right now, I'm leaning toward redesigning the main board to use a fully isolated DC/DC module plus appropriate isolators for all of its I/Os. This will push all galvanic isolation into the main board and away from the adapters. It will also require a supercapacitor for the transmitter as well as slightly higher power draw than before.
If anyone has a simpler idea, please leave a comment here.