I noticed in Zephyr OS there is an API LED:
led_on(dev_io, RED); <-- does not work
gpio_pin_set(dev_io, RED, 1); <-- works well
what can be the reason ?
can you show a working example with "led_on" ?
Check out the sample <ncs location>zephyr/samples/drivers/led_pwm, it used the led_on() function.
I tested it with the nRF9160 DK and NCS v1.8.0 and it (almost) worked.
Initially when I built the sample with the board nrf9160dk_nrf9160_ns I got the error "spm/libspmsecureentries.a.. No such file or directory", but after changing the name to led_pwm2 (samples/drivers/led_pwm2), it built fine. I will investigate this bug.
I flashed the sample and I saw that LED1 blinked.
Best regards,
Simon