remove unnecessary variable

This commit is contained in:
Thomas Gubler 2014-11-28 09:45:39 +01:00
parent 36bf0c04c8
commit 946d1203cf
1 changed files with 4 additions and 2 deletions

View File

@ -84,8 +84,10 @@ PX4_MAIN_FUNCTION(subscriber)
// n.subscribe(PX4_TOPIC(rc_channels), [&](const PX4_TOPIC_T(rc_channels) &msg){rc_channels_callback(msg);});
// n.subscribe(PX4_TOPIC(rc_channels), [&](int i){ return rc_channels_callback(i);});
// CallbackFunction cbf = [](int i){ return rc_channels_callback(i);};
std::function<void(const PX4_TOPIC_T(rc_channels)&)> cbf = [](const PX4_TOPIC_T(rc_channels)& msg){ return rc_channels_callback(msg);};
n.subscribe<PX4_TOPIC_T(rc_channels)>(PX4_TOPIC(rc_channels), cbf);
// std::function<void(const PX4_TOPIC_T(rc_channels)&)> cbf = [](const PX4_TOPIC_T(rc_channels)& msg){ return rc_channels_callback(msg);};
// n.subscribe<PX4_TOPIC_T(rc_channels)>(PX4_TOPIC(rc_channels), cbf);
n.subscribe<PX4_TOPIC_T(rc_channels)>(PX4_TOPIC(rc_channels),
[](const PX4_TOPIC_T(rc_channels)& msg){ return rc_channels_callback(msg);});
PX4_INFO("subscribed");
/**