Lines Matching +full:led +full:- +full:current
4 * SPDX-License-Identifier: Apache-2.0
8 #include <zephyr/drivers/led.h>
9 #include <zephyr/drivers/led/is31fl3733.h>
15 /* LED matrix is addressed using a row major format */
20 static int led_channel_write(const struct device *led) in led_channel_write() argument
34 ret = led_write_channels(led, 0, sizeof(led_state), led_state); in led_channel_write()
36 printk("Error: could not write LED channels (%d)\n", ret); in led_channel_write()
40 /* Disable quadrant of LED display */ in led_channel_write()
41 printk("Disable LED quadrant\n"); in led_channel_write()
48 ret = led_write_channels(led, 0, in led_channel_write()
51 printk("Error: could not write LED channels (%d)\n", ret); in led_channel_write()
58 static int led_brightness(const struct device *led) in led_brightness() argument
63 /* Set LED brightness to low value sequentially */ in led_brightness()
67 ret = led_set_brightness(led, LED_MATRIX_COORD(row, col), in led_brightness()
70 printk("Error: could not enable led " in led_brightness()
81 static int led_on_off(const struct device *led) in led_on_off() argument
86 printk("Toggle each led\n"); in led_on_off()
87 /* Turn on each led for a short duration */ in led_on_off()
90 ret = led_off(led, LED_MATRIX_COORD(row, col)); in led_on_off()
92 printk("Error: could not disable led " in led_on_off()
98 ret = led_on(led, LED_MATRIX_COORD(row, col)); in led_on_off()
100 printk("Error: could not enable led " in led_on_off()
119 printk("Error- LED device is not ready\n"); in main()
137 /* Select lower current limt */ in main()
138 printk("Restarting sample with lower current limit\n"); in main()
142 printk("Could not set LED current limit (%d)\n", ret); in main()
146 /* Select higher current limt */ in main()
147 printk("Restarting sample with higher current limit\n"); in main()
151 printk("Could not set LED current limit (%d)\n", ret); in main()