Commit Graph

90 Commits

Author SHA1 Message Date
Nffj84 5ab076368d Prevent GimbalServer from being set available
Added check to not allow GimbalServer to become available after setting allow camera commands to false.
2025-03-24 18:24:11 +02:00
Nffj84 deb607237e Set camera ready for lift and drop
Added functionality to set camera ready for bringing it down or up.
Camera will be made available for AI after bringCameraDown command is given via UDPSocket.
Camera will be made unavailable for AI after bringCameraUp command is given via UDPSocket.
2025-03-24 18:01:47 +02:00
Nffj84 f1023788e5 Added simple tool for offline use.
Tool has three inputs map_tile_folder, current_latitude and current_longitude.
With these tool will got through map tiles in given folder and list tiles in order based on their distance from given location.
2025-01-06 13:01:59 +02:00
Tuomas Järvinen 38953d0ba6 Use MAVSDK::RawMission in AzMissionController
TODO!!
- send mission indexes from AzMissionController to AzDroneController
- handle finishing of the mission
2024-12-01 21:51:02 +01:00
Tuomas Järvinen 37e8cfd3fe Use raw missions in AutoPilot
- uses MAVSDK::MissionRaw objects for missions
- added new state AZ_DRONE_STATE_MISSION_UPLOADED
- new state is used in AzDroneControllerPlane before waiting for AUTO switch

TODO!!
- move to AzMissionController
- use JSON file instead of hard coded mission items
2024-11-30 17:09:00 +01:00
Tuomas Järvinen be36fc5c50 Added logging for altitude and compass 2024-11-27 17:43:11 +01:00
Tuomas Järvinen de63892725 Minor fixes to NCNN inference
- reduced logging
- emit also empty inference results to AiEngine
2024-10-24 18:57:49 +02:00
Tuomas Järvinen e3643ea622 Small fixes to AI Controller
- removed QtSerialPort from the Qt CONFIG parameters
- remove compiler warnings
- reduced logging
- fixed FPS to show what AI really analyzed
- RTSP reader tries to connect to the stream once per second until it succeeds
2024-10-24 18:36:12 +02:00
Tuomas Järvinen 45c19baa45 Changed directory structure and renamed applications
- autopilot -> drone_controller
- rtsp_ai_player -> ai_controller
- added top level qmake project file
- updated documentation
- moved small demo applications from tmp/ to misc/
2024-10-19 14:44:34 +02:00
Tuomas Järvinen 54b7dc41ca Reduced and improved logging
- removed unnecessary logging
- print start date and time when application starts
- use std::cout instead of qDebug()
- better logging in DroneController classes
- renamed Controller states for better readability
2024-10-18 21:45:20 +02:00
Tuomas Järvinen 91257d0ce7 Added support for switching to AUTO mode in Autopilot.
When the application is started with the command parameter "plane", the
application uses the AzDroneControllerPlane class to control
initialisation. It doesn't arm or takeoff the drone. Instead, it waits
for the user to mode to AUTO (in Ardupilot, Mission in MAVSDK) with the
RC controller. When AUTO mode has been detected, the application will
start a normal mission handling.
2024-10-17 20:56:42 +02:00
Tuomas Järvinen 0975532635 Use constant font size for OPI5 inference results. 2024-10-17 20:56:38 +02:00
Alex Bezdieniezhnykh 7f333ba990 ai_player: show all frames, regardless of inference results 2024-10-17 09:14:15 +03:00
Nffj84 a3d9137b77 Changed serial connection to UDP connection.
Added ZR10 support.
Added automation to choose configuration.
2024-10-14 21:18:27 +03:00
Tuomas Järvinen 2b2af3044e Added /usr/local/lib to rpath in rstp_player OPI5 build 2024-10-11 00:34:04 +03:00
Alex B. 9d0b3bc7a9 Add ARM specfic install of mediamtx 2024-10-03 21:00:56 +03:00
Tuomas Järvinen c2bda448c6 Updated build instructions of rtsp_ai_player for OPI5 2024-10-02 19:40:10 +02:00
Tuomas Järvinen d4779b1bb0 - addedd NCNN model support to rtsp_ai_player
- added printing of inference FPS
- simple AI test bench which can be used to compare models
2024-10-02 19:15:49 +02:00
Tuomas Järvinen ef137fbc4b working yolo default model with opencv 2024-08-25 18:26:19 +03:00
Tuomas Järvinen be59a02f9b Add functionality to save inference images for the debugging purposes.
Save bmp images of inference results to /tmp as bmp files. BMP was
chosen to reduce encoding time. Saving is fully threaded. It can be
enable with qmake CONFIG+=save_images option

Also:
  - use antialised fonts in RKNN inference
  - moved class strings to inference base class
  - fixed silly segfault in ONNX inference
  - prevent writing results if class if exceeds valid values

Issue: https://denyspopov.atlassian.net/browse/AZ-38
Type: Improvement
2024-08-19 12:15:42 +03:00
Tuomas Järvinen 022e4a1200 Add compile option to use YOLOv8 ONNX models for testing.
- added qmake option yolo_onnx to use normal YOLOv8 ONNX models. This makes possible to test
  gimbals camera inside without real model.
- reduced confidence threshold requirement in AiEngineInferencevOnnxRuntime from 0.5 to 0.2
- make printing prettier with ONNX Runtime
- removed unnecessary cv::Mat::clone()

Type: Improvement
Issue: https://denyspopov.atlassian.net/browse/AZ-39
2024-08-18 17:17:40 +03:00
Tuomas Järvinen 86c0a7d5c4 Improvements to OPI5 inference
- fixed probability showing 0.50 all the time
- removed commented out code
- fixed bug which prevented used of OPI5 inference in the case of early failure

Type: Bugfix
Issue: https://denyspopov.atlassian.net/browse/AZ-37
2024-08-17 15:28:26 +03:00
Tuomas Järvinen ba810592b5 Added new qmake config option which enables real gimbal camera
Gimbal camera can be enabled and used for example with command:
qmake6 CONFIG+=gimbal && make && ./rtsp_ai_player ~/azaion/models/onnx/yolov8m.onnx
2024-07-27 11:54:37 +03:00
Tuomas Järvinen 7052a05d55 Enables use of multiple TPUs in OPI5 2024-07-27 11:29:41 +03:00
Nffj84 147213cec6 Added server side code. 2024-07-25 17:49:30 +03:00
Tuomas Järvinen 8e88cb6fe1 Initial version of combining rtsp_ai_player and camera modules.
Functionality has been written to rtsp_ai_player.

TODO!!
- move functionality of camera module misc/rtsp_ai_player/aienginegimbalserver.cpp
- implement all signals in AiEngineGimbalClient
- get drone position from autopilot and send it to AiEngineGimbalServer
2024-07-18 22:04:09 +02:00
Tuomas Järvinen 7c802106c7 Improve taking off in Autopilot
MAVSDK/ArduPilot never reached take-off altitude. Added simple logic to
start the mission when 90% of set take-off altitude has been reached.

Type: Improvement
Issue: https://denyspopov.atlassian.net/browse/AZ-22
2024-07-17 19:19:02 +02:00
Nffj84 2b9bda1ff0 Added new target location algorithm.
Fixed issue with target altitude calculation.
2024-07-16 18:15:10 +03:00
Tuomas Järvinen 46ad1f0ff7 Added Qt API suggestion for AI and camera interaction. 2024-07-15 21:58:38 +02:00
Oleksandr Bezdieniezhnykh e75da8f826 fix drone type checking 2024-07-15 19:41:27 +03:00
Tuomas Järvinen c708e40cff Minor fixes to README.md file in rtsp_ai_player. Part 2 2024-07-14 20:20:36 +02:00
Tuomas Järvinen ce2b31a388 Minor fixes to README.md file in rtsp_ai_player 2024-07-14 20:16:30 +02:00
Tuomas Järvinen 2ed17c3953 Fixed README.md file in rtsp_ai_player 2024-07-14 20:11:56 +02:00
Tuomas Järvinen 43344365e3 Minor fixed to README.md file in rtsp_ai_player 2024-07-14 19:54:46 +02:00
Tuomas Järvinen 8a7d681e5b Renamed opi_player as rtsp_ai_player 2024-07-14 19:52:45 +02:00
Tuomas Järvinen 813251b170 Fully working YOLOv8 detection with ONNX runtime. 2024-07-14 18:08:05 +02:00
Tuomas Järvinen 78cfe484b1 Added get_yolo_mode.sh scripts which gets the model and converts it to onnx 2024-07-10 20:23:39 +02:00
Tuomas Järvinen 683f2d538b Chaneges to opi_rtsp test application
- refactoring
  - can use normal YOLOv8 files converted to ONNX format
  - does not work with azaion ONNX files!
2024-07-10 19:53:19 +02:00
Tuomas Järvinen 3d39d8fd99 Fully working opi_rtsp on PC with YOLOv8 ONNX models 2024-07-10 18:37:33 +02:00
Tuomas Järvinen 896307d296 Resize input image to 640x640 for ONNX inference in RTSP demo app. 2024-07-09 21:11:23 +02:00
Tuomas Järvinen 607ac22b46 Fixed PC build to work with ONNX Yolov10 files 2024-07-09 20:34:21 +02:00
Tuomas Järvinen c4af0cc461 Print Telemetry::Health all the time 2024-07-04 16:56:06 +03:00
Tuomas Järvinen 7e4c43dec9 Fixes for A8 remote control. Added logging messages 2024-07-04 16:40:00 +03:00
Tuomas Järvinen 989fd314f2 Fixed opi_rtsp to use network module 2024-07-04 15:51:04 +03:00
Tuomas Järvinen 0bec8369e3 Minor fixes to A8 to keep GCC happy 2024-07-04 15:27:31 +03:00
Nffj84 89c68aeb67 Changed FIFO pipes to UDP. 2024-07-04 15:20:48 +03:00
Tuomas Järvinen 5af90ac918 Fixed segfault if system was not found Autopilot 2024-07-04 14:27:50 +03:00
Tuomas Järvinen aae3e87116 Added minimal UDP client and server examples 2024-07-04 13:51:29 +03:00
Tuomas Järvinen f4027094f1 Compile opi_rtsp as only command line app 2024-07-04 13:51:29 +03:00
Nffj84 67c2b41986 Removed debug printing. 2024-07-04 13:33:07 +03:00