tof3DMain.cpp 874 B

1234567891011121314151617181920212223242526272829
  1. //
  2. // Created by zx on 2023/10/7.
  3. //
  4. #include <iostream>
  5. #include "log/log.h"
  6. #include "tof3d_manager.h"
  7. #include "communication/rabbitmq_communication.h"
  8. int main(int argc, char * argv[]) {
  9. // 初始化日志系统
  10. ZX::InitGlog(PROJECT_NAME, ETC_PATH PROJECT_NAME "/LogInfo/");
  11. /*LOG(INFO) << "begain init rabbitmq.";
  12. auto ret = RabbitmqCommunicationTof3D::get_instance_references().rabbitmq_init_from_protobuf(ETC_PATH"Tof3d/rabbitmq.prototxt");
  13. if (ret != SUCCESS) {
  14. LOG(ERROR) << "system communication mq init failed: " << ret.to_string();
  15. return -1;
  16. }
  17. RabbitmqCommunicationTof3D::get_instance_references().set_encapsulate_status_cycle_time(100);
  18. */
  19. tof3dManager tof3d;
  20. auto err = tof3d.init();
  21. LOG(INFO) << err.to_string();
  22. while (1) {
  23. usleep(2000 * 1000);
  24. }
  25. return err.get_error_code();
  26. }