The past few weeks were all about the 6-wire port interface. Aside from the plug, EV3 cables are very similar to Powered Up cables:
1/2: Motor power
3/4: Ground and 3V3
5/6: Data wires
My goal is to generalize the Pybricks port interface drivers that we have already written for SPIKE in such a way that they can run on EV3 too. This avoids code duplication and makes it easier to maintain in the long run. You can see parts of this effort here. (I normally create small commits, but sometimes you just have to do a giant overhaul like this!)
This major revision also got us a few steps closer to a popular request we frequently get from advanced users: direct access to the data pins on the ports. Now that we can switch modes between different LEGO protocols, there will also be an option to turn off the LEGO protocol entirely. This gives you the power and freedom to interface with custom devices.
Fortunately, LEGO published the EV3 schematics a long time ago, so we don't have to reverse-engineer how it works!

Not everything works the same between both platforms, though. The EV3 also has additional analog inputs on the motor and data pins. We'll need to enable those to detect and use analog devices like the EV3 touch sensor and NXT sensors. The same goes for I2C as used by some NXT sensors.
The EV3 supports UART on all four sensor ports, but only ports 1 and 2 have real UART peripherals. Ports 3 and 4 use an emulated UART on a dedicated PRU co-processor. These are challenging to set up, but I'm excited to share that we have signs of life coming out of those ports too.
As always, a huge thanks for your support! If you'd like to see more of such updates, please let me know. Special requests are welcome too. I'm happy to zoom in on the development of your favorite topics.
Gregor Gramlich
2025-01-24 15:17:30 +0000 UTCGregor Gramlich
2025-01-24 15:15:58 +0000 UTCchris
2025-01-24 09:47:44 +0000 UTC