2013-09-22 03:01:24 -03:00
|
|
|
|
|
|
|
|
|
|
|
#ifndef __AP_HAL_LINUX_MAIN_H__
|
|
|
|
#define __AP_HAL_LINUX_MAIN_H__
|
|
|
|
|
2014-07-06 23:03:26 -03:00
|
|
|
#if CONFIG_HAL_BOARD == HAL_BOARD_LINUX
|
2013-09-22 03:01:24 -03:00
|
|
|
#define AP_HAL_MAIN() extern "C" {\
|
|
|
|
int main (int argc, char * const argv[]) { \
|
|
|
|
hal.init(argc, argv); \
|
|
|
|
hal.scheduler->system_initialized(); \
|
2014-07-06 20:00:58 -03:00
|
|
|
setup();\
|
2014-05-02 06:57:19 -03:00
|
|
|
for(;;) loop();\
|
2013-09-22 03:01:24 -03:00
|
|
|
return 0;\
|
|
|
|
}\
|
|
|
|
}
|
2014-07-06 23:03:26 -03:00
|
|
|
#endif // HAL_BOARD_LINUX
|
2013-09-22 03:01:24 -03:00
|
|
|
|
|
|
|
#endif // __AP_HAL_LINUX_MAIN_H__
|