Skip to content

Commit

Permalink
FMUv5: Fix RGB led usage - these are individual status leds.
Browse files Browse the repository at this point in the history
  • Loading branch information
LorenzMeier committed Jun 6, 2018
1 parent 02eaf2c commit f87fa91
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmake/configs/nuttx_px4fmu-v5_default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ set(config_module_list
drivers/px4fmu
drivers/px4io
drivers/rgbled
drivers/rgbled_pwm
# Enable the line below to put the three leds into PWM RGB mode
#drivers/rgbled_pwm
drivers/stm32
drivers/stm32/adc
drivers/stm32/tone_alarm
Expand Down
3 changes: 3 additions & 0 deletions src/modules/commander/commander_helper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,9 @@ int led_init()
return PX4_ERROR;
}

/* the green LED is only available on FMUv5 */
(void)h_leds.ioctl(LED_ON, LED_GREEN);

/* the blue LED is only available on AeroCore but not FMUv2 */
(void)h_leds.ioctl(LED_ON, LED_BLUE);

Expand Down

0 comments on commit f87fa91

Please sign in to comment.