Skip to content

Commit

Permalink
AP_Notify: fix nullptr in ToshibaLED example
Browse files Browse the repository at this point in the history
  • Loading branch information
peterbarker authored and lucasdemarchi committed Sep 20, 2018
1 parent 71c9c91 commit 5ae3c60
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ void blink();

const AP_HAL::HAL& hal = AP_HAL::get_HAL();

AP_Notify notify;

static ToshibaLED_I2C toshiba_led(1);

void setup(void)
Expand All @@ -20,6 +22,7 @@ void setup(void)
if (toshiba_led.init()) {
hal.console->printf("Failed to initialise Toshiba LED\n");
}
toshiba_led.pNotify = &notify;

// turn on initialising notification
AP_Notify::flags.initialising = false;
Expand Down

0 comments on commit 5ae3c60

Please sign in to comment.