Skip to content

samples: led: consolidate LED samples under same directory #146852

samples: led: consolidate LED samples under same directory

samples: led: consolidate LED samples under same directory #146852

Triggered via pull request August 31, 2024 12:37
Status Failure
Total duration 2m 53s
Artifacts 1

compliance.yml

on: pull_request
Run compliance checks on patch series (PR)
2m 43s
Run compliance checks on patch series (PR)
Fit to window
Zoom out
Zoom in

Annotations

4 errors, 1 warning, and 10 notices
E0001: doc/_scripts/redirects.py#L228
doc/_scripts/redirects.py:228 Parsing failed: 'unterminated string literal (detected at line 228) (redirects, line 228)' (syntax-error)
Run compliance checks on patch series (PR)
Process completed with exit code 2.
Run compliance checks on patch series (PR): Pylint.txt#L1
See https://www.pylint.org/ for more details E0001:Parsing failed: 'unterminated string literal (detected at line 228) (redirects, line 228)' (syntax-error) File:doc/_scripts/redirects.py Line:228 Column:106
Run compliance checks on patch series (PR)
Process completed with exit code 1.
Run compliance checks on patch series (PR): ClangFormat.txt#L1
See https://docs.zephyrproject.org/latest/contribute/guidelines.html#clang-format for more details. You may want to run clang-format on this change: -#define SLEEPTIME K_MSEC(250) +#define SLEEPTIME K_MSEC(250) -#define GPIO_DATA_PIN 16 -#define GPIO_CLK_PIN 19 -#define GPIO_NAME "GPIO_" +#define GPIO_DATA_PIN 16 +#define GPIO_CLK_PIN 19 +#define GPIO_NAME "GPIO_" -#define APA102C_START_FRAME 0x00000000 -#define APA102C_END_FRAME 0xFFFFFFFF +#define APA102C_START_FRAME 0x00000000 +#define APA102C_END_FRAME 0xFFFFFFFF File:samples/drivers/led/led_apa102c_bitbang/src/main.c Line:34 You may want to run clang-format on this change: -#define NUM_RGB 4 +#define NUM_RGB 4 /* Number of LEDS linked together */ -#define NUM_LEDS 1 +#define NUM_LEDS 1 File:samples/drivers/led/led_apa102c_bitbang/src/main.c Line:49 You may want to run clang-format on this change: -#define SLEEP_TIME_MS 1000 +#define SLEEP_TIME_MS 1000 File:samples/drivers/led/led_is31fl3194/src/main.c Line:13 You may want to run clang-format on this change: - { 0xFF, 0x00, 0x00, "Red" }, - { 0x00, 0xFF, 0x00, "Green" }, - { 0x00, 0x00, 0xFF, "Blue" }, - { 0xFF, 0xFF, 0xFF, "White" }, - { 0xFF, 0xFF, 0x00, "Yellow" }, - { 0xFF, 0x00, 0xFF, "Purple" }, - { 0x00, 0xFF, 0xFF, "Cyan" }, - { 0xF4, 0x79, 0x20, "Orange" }, + {0xFF, 0x00, 0x00, "Red"}, {0x00, 0xFF, 0x00, "Green"}, {0x00, 0x00, 0xFF, "Blue"}, + {0xFF, 0xFF, 0xFF, "White"}, {0xFF, 0xFF, 0x00, "Yellow"}, {0xFF, 0x00, 0xFF, "Purple"}, + {0x00, 0xFF, 0xFF, "Cyan"}, {0xF4, 0x79, 0x20, "Orange"}, File:samples/drivers/led/led_is31fl3194/src/main.c Line:30 You may want to run clang-format on this change: -#define MAX_BRIGHTNESS 100 -#define LAST_LED 15 +#define MAX_BRIGHTNESS 100 +#define LAST_LED 15 -#define SLEEP_DELAY_MS 100 -#define FADE_DELAY_MS 10 -#define WRITE_CHANNELS_LEDS_COUNT 3 -#define WRITE_CHANNELS_LED_START 2 +#define SLEEP_DELAY_MS 100 +#define FADE_DELAY_MS 10 +#define WRITE_CHANNELS_LEDS_COUNT 3 +#define WRITE_CHANNELS_LED_START 2 static void pulse_led(int led, const struct device *const dev) { int status; uint8_t percent; - for (percent = 1 ; percent <= MAX_BRIGHTNESS ; percent++) { + for (percent = 1; percent <= MAX_BRIGHTNESS; percent++) { File:samples/drivers/led/led_is31fl3216a/src/main.c Line:29 You may want to run clang-format on this change: - for (percent = MAX_BRIGHTNESS; - percent <= MAX_BRIGHTNESS; percent--) { + for (percent = MAX_BRIGHTNESS; percent <= MAX_BRIGHTNESS; percent--) { File:samples/drivers/led/led_is31fl3216a/src/main.c Line:39 You may want to run clang-format on this change: - WRITE_CHANNELS_LEDS_COUNT, - brightness); + WRITE_CHANNELS_LEDS_COUNT, brightness); File:samples/drivers/led/led_is31fl3216a/src/main.c Line:59 You may want to run clang-format on this change: - for (percent = MAX_BRIGHTNESS; - percent <= MAX_BRIGHTNESS; percent--) { + for (percent = MAX_BRIGHTNESS; percent <= MAX_BRIGHTNESS; percent--) { memset(brightness, percent, sizeof(brightness)); status = led_write_channels(dev, WRITE_CHANNELS_LED_START, - WRITE_CHANNELS_LEDS_COUNT, - brightness); + WRITE_CHANNELS_LEDS_COUNT, brightness); File:samples/drivers/led/led_is31fl3216a/src/main.c Line:72 You may want to run clang-format on this change: - const struct device *const is31fl3216a = - DEVICE_DT_GET_ANY(issi_is31fl3216a); + const struct device *const is31fl3216a = DEVICE_DT_GET_ANY(issi_is31fl3216a); File:samples/drivers/led/led_is31fl3216a/src/main.c Line:85 You may want to run clang-format on this change: - for (led = 0 ; led <= LAST_LED ; led++) { + for (led = 0; led <= LAST_LED; led++) { File:samples/drivers/led/led_is31fl3216a/src/main.c Line:98 You may want to run clang-format on this change: - ret = led_write_channels(led, 0, - ((CONFIG_LED_ROW_COUNT / 2) * HW_COL_COUNT), led_state); + ret = led_write_channels(led, 0, ((CONFIG_LED_ROW_COUNT / 2) * HW_COL_COUNT), led_state); File:samples/drivers/led/led_is31fl3733/src/main.c Line:50
You may want to run clang-format on this change: samples/drivers/led/led_apa102c_bitbang/src/main.c#L34
samples/drivers/led/led_apa102c_bitbang/src/main.c:34 -#define SLEEPTIME K_MSEC(250) +#define SLEEPTIME K_MSEC(250) -#define GPIO_DATA_PIN 16 -#define GPIO_CLK_PIN 19 -#define GPIO_NAME "GPIO_" +#define GPIO_DATA_PIN 16 +#define GPIO_CLK_PIN 19 +#define GPIO_NAME "GPIO_" -#define APA102C_START_FRAME 0x00000000 -#define APA102C_END_FRAME 0xFFFFFFFF +#define APA102C_START_FRAME 0x00000000 +#define APA102C_END_FRAME 0xFFFFFFFF
You may want to run clang-format on this change: samples/drivers/led/led_apa102c_bitbang/src/main.c#L49
samples/drivers/led/led_apa102c_bitbang/src/main.c:49 -#define NUM_RGB 4 +#define NUM_RGB 4 /* Number of LEDS linked together */ -#define NUM_LEDS 1 +#define NUM_LEDS 1
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3194/src/main.c#L13
samples/drivers/led/led_is31fl3194/src/main.c:13 -#define SLEEP_TIME_MS 1000 +#define SLEEP_TIME_MS 1000
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3194/src/main.c#L30
samples/drivers/led/led_is31fl3194/src/main.c:30 - { 0xFF, 0x00, 0x00, "Red" }, - { 0x00, 0xFF, 0x00, "Green" }, - { 0x00, 0x00, 0xFF, "Blue" }, - { 0xFF, 0xFF, 0xFF, "White" }, - { 0xFF, 0xFF, 0x00, "Yellow" }, - { 0xFF, 0x00, 0xFF, "Purple" }, - { 0x00, 0xFF, 0xFF, "Cyan" }, - { 0xF4, 0x79, 0x20, "Orange" }, + {0xFF, 0x00, 0x00, "Red"}, {0x00, 0xFF, 0x00, "Green"}, {0x00, 0x00, 0xFF, "Blue"}, + {0xFF, 0xFF, 0xFF, "White"}, {0xFF, 0xFF, 0x00, "Yellow"}, {0xFF, 0x00, 0xFF, "Purple"}, + {0x00, 0xFF, 0xFF, "Cyan"}, {0xF4, 0x79, 0x20, "Orange"},
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L29
samples/drivers/led/led_is31fl3216a/src/main.c:29 -#define MAX_BRIGHTNESS 100 -#define LAST_LED 15 +#define MAX_BRIGHTNESS 100 +#define LAST_LED 15 -#define SLEEP_DELAY_MS 100 -#define FADE_DELAY_MS 10 -#define WRITE_CHANNELS_LEDS_COUNT 3 -#define WRITE_CHANNELS_LED_START 2 +#define SLEEP_DELAY_MS 100 +#define FADE_DELAY_MS 10 +#define WRITE_CHANNELS_LEDS_COUNT 3 +#define WRITE_CHANNELS_LED_START 2 static void pulse_led(int led, const struct device *const dev) { int status; uint8_t percent; - for (percent = 1 ; percent <= MAX_BRIGHTNESS ; percent++) { + for (percent = 1; percent <= MAX_BRIGHTNESS; percent++) {
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L39
samples/drivers/led/led_is31fl3216a/src/main.c:39 - for (percent = MAX_BRIGHTNESS; - percent <= MAX_BRIGHTNESS; percent--) { + for (percent = MAX_BRIGHTNESS; percent <= MAX_BRIGHTNESS; percent--) {
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L59
samples/drivers/led/led_is31fl3216a/src/main.c:59 - WRITE_CHANNELS_LEDS_COUNT, - brightness); + WRITE_CHANNELS_LEDS_COUNT, brightness);
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L72
samples/drivers/led/led_is31fl3216a/src/main.c:72 - for (percent = MAX_BRIGHTNESS; - percent <= MAX_BRIGHTNESS; percent--) { + for (percent = MAX_BRIGHTNESS; percent <= MAX_BRIGHTNESS; percent--) { memset(brightness, percent, sizeof(brightness)); status = led_write_channels(dev, WRITE_CHANNELS_LED_START, - WRITE_CHANNELS_LEDS_COUNT, - brightness); + WRITE_CHANNELS_LEDS_COUNT, brightness);
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L85
samples/drivers/led/led_is31fl3216a/src/main.c:85 - const struct device *const is31fl3216a = - DEVICE_DT_GET_ANY(issi_is31fl3216a); + const struct device *const is31fl3216a = DEVICE_DT_GET_ANY(issi_is31fl3216a);
You may want to run clang-format on this change: samples/drivers/led/led_is31fl3216a/src/main.c#L98
samples/drivers/led/led_is31fl3216a/src/main.c:98 - for (led = 0 ; led <= LAST_LED ; led++) { + for (led = 0; led <= LAST_LED; led++) {

Artifacts

Produced during runtime
Name Size
compliance.xml
4.98 KB