My Week in Code #1

Hello everyone. I am starting a new series of weekly posts to go over stuff I worked on/found interesting over the week. I will try to post one every Sunday, but I might skip uneventful weeks.

Since I work as an embedded systems engineer at BeagleBoard.org, many updates will be about BeagleBoard stuff. Still, I might throw some Rust std and other things in occasionally. Let’s see how this goes.

MikroBUS Patches

I finally sent v1 of MikroBUS patches using the approach described by Andrew Davis. I got the approach to work for GPIO, UART, and I2C but not for SPI.

I wrote the driver in Rust to see how it would go, and it was a pretty good experience. Danilo Krummrich will post patches for platform device and driver abstractions for Rust, so any future patches will probably not need to carry those either.

There is also a talk in LPC this week: Runtime hotplug on non-discoverable busses with device tree overlays, so I will be looking forward to it.

Beagle-Y-AI Hacking Sessions

We at BeagleBoard have started weekly hacking sessions for Beagle-Y-AI. Currently, we are working on adding Zephyr support for the R5 core, so feel free to join in. Here is the event invite.

GPIO Nexus Node dtschema

In the MikroBUS patches, I was asked to put the GPIO nexus node dtschema in the upstream dtschema. So just a basic PR to add dtschema for GPIO nexus nodes.

PWM in BeaglePlay

While working on MikroBUS patches, I realized that PWM support was not enabled in the upstream device tree for BeaglePlay. So, I decided to send a patch to enable it.

Once the patch is added to the kernel tree, it will be possible to use the PWM pin in the MikroBUS connector as described in Linux kernel docs.

Fix MicroBlocks for BeagleConnect Freedom

Around two weeks ago, the CI MicroBlocks for BeagleConnect Freedom broke. After checking the CI logs, it seems MicroBlocks started using digitalPinToInterrupt, which was missing in Arduino Module for Zephyr. I created a PR for it, and now the CI is fixed again.

Ending Thoughts

That is all for the week. Hopefully, I can stick to the weekly schedule.

Consider supporting me if you like my work.

Helpful links