crazyflie BugFix:Prevent a value of 0 being passed to px4_arch_configgpio

This prevents the meta value of 0 => not used from being passed to
  px4_arch_configgpio. As this would map to PORTA|PIN0 and is not
  the intended use.
This commit is contained in:
David Sidrane 2017-01-19 08:40:43 -10:00 committed by Lorenz Meier
parent c1b1d03515
commit 3ea5a24924

View File

@ -74,7 +74,9 @@ __EXPORT void led_init()
{
/* Configure LED1 GPIO for output */
for (size_t l = 0; l < (sizeof(g_ledmap) / sizeof(g_ledmap[0])); l++) {
px4_arch_configgpio(g_ledmap[l]);
if (g_ledmap[l]) {
px4_arch_configgpio(g_ledmap[l]);
}
}
}