Ceedling with STM32
Mocking LL
Mocking the STM32 LL can be very convenient. Unfortunately, it can be challenging due to some functions being static inlines in the headers.
This is the reason why my first iteration of testing when using the ST LL I had to instead simulate the registers' memory (which is useful but unnecessary in some cases)
​
Ceedling/CMock has a feature that attempts to sort this issue and allows to mock said inline functions in the headers. I've attempted this with snapshot 0.32.0-9b8d8a9. I've tried this with a previous snapshot and didn't work.
​
To get this to work use the option :treat_inlines: :include . Example in project.yml:
# Configuration Options specific to CMock. See CMock docs for details :cmock: :mock_prefix: mock_ :when_no_prototypes: :warn :enforce_strict_ordering: TRUE :plugins: - :ignore - :callback :treat_as: uint8: HEX8 uint16: HEX16 uint32: UINT32 int8: INT8 bool: UINT8 :treat_inlines: :include
Avenir Light is a clean and stylish font favored by designers. It's easy on the eyes and a great go-to font for titles, paragraphs & more.