pybricks-micropython icon indicating copy to clipboard operation
pybricks-micropython copied to clipboard

platform/ev3: Integrate am18x-lib.

Open laurensvalk opened this issue 1 year ago • 5 comments

This integrates the library part of https://github.com/turmary/am18x-lib (not its many examples) into the bare metal EV3 port to do some experimentation with AM1808 peripherals, interrupts, and so on. It's not quite a full low level HAL, but it's a lot more than nothing.

We don't have to merge or use this, but having something that actually works and can print debugging information is helpful, so I wanted to at least archive this intermediate result as a pull request.

For example, this could be used to implement the clock driver and the __wfi to get basic waiting working, as done in the final commit.

Maybe I should now repeat this exercise with the TI Starterware... :nerd_face:

laurensvalk avatar Jun 10 '24 18:06 laurensvalk

Coverage Status

coverage: 56.592%. remained the same when pulling 43d18dea0f6414813c47e045d0eb5746a2fc67df on ev3-am18x-lib into d16a98f1e74fefe030ce6cd0981c92339662ce94 on master.

coveralls avatar Jun 10 '24 18:06 coveralls

Coverage Status

coverage: 56.592%. remained the same when pulling 503152acde03e758d8cb7ddd1bc43f9aee2c9622 on ev3-am18x-lib into d16a98f1e74fefe030ce6cd0981c92339662ce94 on master.

coveralls avatar Jun 11 '24 08:06 coveralls

Coverage Status

coverage: 56.592%. remained the same when pulling a5b91ee2d96e6b788d53258be3ba9376d3237b4f on ev3-am18x-lib into 731a34bfc1eafbc310d29616f7884a923d378f97 on master.

coveralls avatar Jul 29 '24 12:07 coveralls

This can probably be merged. The only existing code this touches is bricks/_common/arm_none_eabi.mk, but the additions are protected by ifeq ($(PB_MCU_FAMILY),TIAM1808).

This will require some minor changes to the automatically starting program in #254 , so I'll leave it open for the time being.

laurensvalk avatar Jul 29 '24 12:07 laurensvalk

This pull request is a nice way to archive this exploration. Let's close it for the time being. Keeping the existing bare metal EV3 build as-is makes it a nice starting point for new ports.

laurensvalk avatar Sep 16 '24 08:09 laurensvalk