2 ms·
> now their hardware abstraction layer, the HAL library, leaves quite a bit to be desired, but it's nice to get a starting point for newbies. libopencm3 is a v
by berti 8y ago
> now their hardware abstraction layer, the HAL library, leaves quite a bit to be desired, but it's nice to get a starting point for newbies.
libopencm3 is a very good alternative with a much better license if you're looking to open source your work [0]. They give you some nice examples [1], and a project template [2]. The documentation is okay, but like most doxygen projects, I find it easier to just read the headers myself.
[0] http://libopencm3.org http://libopencm3.org
[1] https://github.com/libopencm3/libopencm3-examples.git https://github.com/libopencm3/libopencm3-examples.git
[2] https://github.com/libopencm3/libopencm3-template https://github.com/libopencm3/libopencm3-template
- TD-Linux 8y agoST fixed their STM32Cube licenses so that most of it is BSD licensed, but yeah I also agree that libopencm3 is great. ST has good datasheets that allow anyone to easily create their own HAL or set things up directly if needed. There's also HALs for other language, such as Rust.
- berti 8y agoYes, I love ST reference manuals. Sometimes it's easier to poke registers directly using the definitions in the CMSIS headers when you're doing something more complicated with the ST reference manual as your reference. The layer of indirection introduced by a HAL makes working off the ref manual more difficult, and sometimes impossible without poking at least a couple of registers directly. Typically I'd do that as a first cut, and look to add some abstraction once it's already working. I haven't gone down the Rust rabbit hole so far, mostly due to lack of time. Hopefully the embedded support will have matured nicely by the time I do. I see there are a couple of viable looking RTOSs making good progress.