2022-01-18 21:59:42 +08:00
|
|
|
#include <cassert>
|
|
|
|
|
|
|
|
|
|
#include "selfdrive/boardd/boardd.h"
|
2022-05-18 14:11:57 -07:00
|
|
|
#include "common/swaglog.h"
|
|
|
|
|
#include "common/util.h"
|
2022-06-11 16:38:24 -07:00
|
|
|
#include "system/hardware/hw.h"
|
2022-01-18 21:59:42 +08:00
|
|
|
|
|
|
|
|
int main(int argc, char *argv[]) {
|
|
|
|
|
LOGW("starting boardd");
|
|
|
|
|
|
|
|
|
|
if (!Hardware::PC()) {
|
|
|
|
|
int err;
|
|
|
|
|
err = util::set_realtime_priority(54);
|
|
|
|
|
assert(err == 0);
|
2022-06-02 15:20:51 +02:00
|
|
|
err = util::set_core_affinity({4});
|
2022-01-18 21:59:42 +08:00
|
|
|
assert(err == 0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
std::vector<std::string> serials(argv + 1, argv + argc);
|
|
|
|
|
boardd_main_thread(serials);
|
|
|
|
|
return 0;
|
|
|
|
|
}
|