How do I extend the CAF LED module?

I am currently using the CAF LED modules. This works fine with a mono-color LED or a tri-color RGB LED.

question 1:
My problem is that unfortunatly my hardware board has only Bi-color LED e.g. red+green.
Is there any (hidden) configuration settings in CAF to disable the "blue" color in the LED module.

without hitting the assert in function leds_init at line 186

   __ASSERT_NO_MSG((led->color_count == 1) || (led->color_count == 3));

Question2:
An small architectural question:
How can I overload or inherit the CAF LED module correctly, without copy-paste the code to my custom sdk (as extended library to zephyr)

Any idea / hint / tip how to fix this correctly.

Thx.

Parents Reply Children
Related