fmu & px4io:Use uORB Publish Auto

This commit is contained in:
David Sidrane
2018-07-17 08:53:29 +02:00
committed by Lorenz Meier
parent 33c9459ebe
commit a7a1607689
2 changed files with 4 additions and 16 deletions
+2 -8
View File
@@ -1870,14 +1870,8 @@ PX4IO::io_publish_raw_rc()
}
}
/* lazily advertise on first publication */
if (_to_input_rc == nullptr) {
_to_input_rc = orb_advertise(ORB_ID(input_rc), &rc_val);
} else {
orb_publish(ORB_ID(input_rc), _to_input_rc, &rc_val);
}
int instance = 0;
orb_publish_auto(ORB_ID(input_rc), &_to_input_rc, &rc_val, &instance, ORB_PRIO_HIGH);
return OK;
}