PX4 Firmware
PX4 Autopilot Software http://px4.io
|
#include <uORBTest_UnitTest.hpp>
Public Member Functions | |
~UnitTest ()=default | |
int | test () |
template<typename S > | |
int | latency_test (orb_id_t T, bool print) |
int | info () |
UnitTest (const uORBTest::UnitTest &)=delete | |
Static Public Member Functions | |
static uORBTest::UnitTest & | instance () |
Private Member Functions | |
UnitTest () | |
int | pubsublatency_main () |
int | pub_test_multi2_main () |
int | test_single () |
int | test_multi () |
int | test_multi_reversed () |
int | test_unadvertise () |
int | test_multi2 () |
int | test_queue () |
int | pub_test_queue_main () |
int | test_queue_poll_notify () |
int | test_fail (const char *fmt,...) |
int | test_note (const char *fmt,...) |
Static Private Member Functions | |
static int | pubsubtest_threadEntry (int argc, char *argv[]) |
static int | pub_test_multi2_entry (int argc, char *argv[]) |
static int | pub_test_queue_entry (int argc, char *argv[]) |
Private Attributes | |
volatile bool | _thread_should_exit |
bool | pubsubtest_passed |
bool | pubsubtest_print |
int | pubsubtest_res = OK |
orb_advert_t | _pfd [4] |
used for test_multi and test_multi_reversed More... | |
volatile int | _num_messages_sent = 0 |
Definition at line 73 of file uORBTest_UnitTest.hpp.
|
default |
|
delete |
|
inlineprivate |
Definition at line 88 of file uORBTest_UnitTest.hpp.
int UnitTest::info | ( | ) |
Definition at line 263 of file uORBTest_UnitTest.cpp.
References OK.
|
static |
Definition at line 59 of file uORBTest_UnitTest.cpp.
Referenced by pub_test_multi2_entry(), pub_test_queue_entry(), pubsubtest_threadEntry(), and uorb_tests_main().
int UnitTest::latency_test | ( | orb_id_t | T, |
bool | |||
) |
Definition at line 125 of file uORBTest_UnitTest.hpp.
References hrt_absolute_time(), orb_advert_t, orb_advertise(), orb_publish(), orb_unadvertise(), and pubsubtest_threadEntry().
Referenced by uorb_tests_main().
|
staticprivate |
Definition at line 433 of file uORBTest_UnitTest.cpp.
References instance(), and pub_test_multi2_main().
Referenced by test_multi2().
|
private |
Definition at line 439 of file uORBTest_UnitTest.cpp.
References _thread_should_exit, hrt_absolute_time(), orb_advert_t, orb_advertise_multi(), ORB_ID, ORB_PRIO_DEFAULT, orb_publish(), orb_unadvertise(), orb_test_medium::time, and orb_test_medium::val.
Referenced by pub_test_multi2_entry().
|
staticprivate |
Definition at line 739 of file uORBTest_UnitTest.cpp.
References instance(), and pub_test_queue_main().
Referenced by test_queue_poll_notify().
|
private |
Definition at line 745 of file uORBTest_UnitTest.cpp.
References _num_messages_sent, _thread_should_exit, orb_advert_t, orb_advertise_queue(), ORB_ID, orb_publish(), orb_unadvertise(), test_fail(), and orb_test_medium::val.
Referenced by pub_test_queue_entry().
|
private |
Definition at line 65 of file uORBTest_UnitTest.cpp.
References f(), hrt_elapsed_time_atomic(), orb_copy(), ORB_ID, orb_subscribe_multi(), orb_unsubscribe(), pubsubtest_passed, pubsubtest_print, pubsubtest_res, px4_poll(), orb_test_large::time, and orb_test_large::val.
Referenced by pubsubtest_threadEntry().
|
staticprivate |
Definition at line 874 of file uORBTest_UnitTest.cpp.
References instance(), and pubsublatency_main().
Referenced by latency_test().
int UnitTest::test | ( | ) |
Definition at line 189 of file uORBTest_UnitTest.cpp.
References OK, test_multi(), test_multi2(), test_multi_reversed(), test_queue(), test_queue_poll_notify(), test_single(), and test_unadvertise().
Referenced by uorb_tests_main().
|
private |
Definition at line 847 of file uORBTest_UnitTest.cpp.
Referenced by pub_test_queue_main(), test_multi(), test_multi2(), test_multi_reversed(), test_queue(), test_queue_poll_notify(), test_single(), and test_unadvertise().
|
private |
Definition at line 344 of file uORBTest_UnitTest.cpp.
References _pfd, orb_advertise_multi(), orb_copy(), ORB_ID, ORB_PRIO_MAX, ORB_PRIO_MIN, orb_priority(), orb_publish(), orb_subscribe_multi(), orb_unsubscribe(), test_fail(), test_note(), and orb_test::val.
Referenced by test().
|
private |
Definition at line 490 of file uORBTest_UnitTest.cpp.
References _thread_should_exit, hrt_abstime, orb_check(), orb_copy(), ORB_ID, orb_subscribe_multi(), orb_unsubscribe(), pub_test_multi2_entry(), test_fail(), test_note(), and orb_test_medium::time.
Referenced by test().
|
private |
Definition at line 555 of file uORBTest_UnitTest.cpp.
References _pfd, orb_advertise_multi(), orb_copy(), ORB_ID, ORB_PRIO_MAX, ORB_PRIO_MIN, orb_publish(), orb_subscribe_multi(), test_fail(), test_note(), and orb_test::val.
Referenced by test().
|
private |
Definition at line 861 of file uORBTest_UnitTest.cpp.
References OK.
Referenced by test_multi(), test_multi2(), test_multi_reversed(), test_queue(), test_queue_poll_notify(), test_single(), and test_unadvertise().
|
private |
Definition at line 626 of file uORBTest_UnitTest.cpp.
References CHECK_COPY, CHECK_NOT_UPDATED, CHECK_UPDATED, orb_advert_t, orb_advertise_queue(), orb_check(), orb_copy(), ORB_ID, orb_publish(), orb_subscribe(), orb_unadvertise(), test_fail(), test_note(), and orb_test_medium::val.
Referenced by test().
|
private |
Definition at line 782 of file uORBTest_UnitTest.cpp.
References _num_messages_sent, _thread_should_exit, orb_copy(), ORB_ID, orb_subscribe(), pub_test_queue_entry(), px4_poll(), test_fail(), test_note(), and orb_test_medium::val.
Referenced by test().
|
private |
Definition at line 268 of file uORBTest_UnitTest.cpp.
References orb_advert_t, orb_advertise(), orb_check(), orb_copy(), ORB_ID, orb_publish(), orb_subscribe(), orb_unadvertise(), orb_unsubscribe(), test_fail(), test_note(), and orb_test::val.
Referenced by test().
|
private |
Definition at line 230 of file uORBTest_UnitTest.cpp.
References _pfd, orb_advertise_multi(), ORB_ID, ORB_PRIO_MAX, orb_unadvertise(), test_fail(), and test_note().
Referenced by test().
|
private |
Definition at line 118 of file uORBTest_UnitTest.hpp.
Referenced by pub_test_queue_main(), and test_queue_poll_notify().
|
private |
used for test_multi and test_multi_reversed
Definition at line 102 of file uORBTest_UnitTest.hpp.
Referenced by test_multi(), test_multi_reversed(), and test_unadvertise().
|
private |
Definition at line 96 of file uORBTest_UnitTest.hpp.
Referenced by pub_test_multi2_main(), pub_test_queue_main(), test_multi2(), and test_queue_poll_notify().
|
private |
Definition at line 98 of file uORBTest_UnitTest.hpp.
Referenced by pubsublatency_main().
|
private |
Definition at line 99 of file uORBTest_UnitTest.hpp.
Referenced by pubsublatency_main().
|
private |
Definition at line 100 of file uORBTest_UnitTest.hpp.
Referenced by pubsublatency_main().