VOXL의 이미지를 업데이트하다가 Brick이 된 경우자체적으로 해결할 수 없다.
디버그 보드라는 별도의 Extension보드가 필요하다.
디버그 보드를 장착하고 Fastboot 스위치를 On 한 상태에서 부팅을 하면 장비가 Fastboot모드로 부팅이 된다.
아래와 같이 디바이스의 고유번호와 함께 fastboot 모드라고 인식이 되면 Fastboot 스위치를 바로 Off 해야 한다. 그렇지 않으면 잠시후 Fastboot 모드에서 풀려져 버린다. 마치 윈도우에서 부트 매니저가 잠시 떴다가 이후 First 부트모드로 부팅이 들어가는 것과 비슷하다.
swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.2.0$ sudo fastboot devices 534625ca fastboot |
fastboot모드에서 디바이스를 인식했으니 이제 디바이스에 새로운 이미지를 쓰면 된다.
이미지는 호스트PC에 다운받아서 압축을 푼 상태로 준비해두고, 압축풀린 파일중 install.sh 를 실행하면 이미지를 플래쉬가 시작된다. Fastboot스위치를 Off 하지 않으면 디바이스 인식이 안되고 풀려버리므로 플래쉬 도중 Fail이 발생한다. Fastboot모드 인식후 바로 스위치는 Off 해야 한다.
swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.3.4-b$ sudo ./install.sh [sudo] password for swift: [INFO] adb installed [INFO] fastboot installed This process will completely wipe your VOXL Would you like to preserve the /data/ partition which contains things like calibration, wifi config, and docker images To preserve files in /data/ answer Y To wipe /data/ for a full factory flash answer N Enter Y or N: Y [INFO] Rebooting into fastboot... [INFO] Waiting for fastboot... target reported max download size of 536870912 bytes sending 'aboot' (494 KB)... OKAY [ 0.067s] writing 'aboot'... OKAY [ 0.030s] finished. total time: 0.097s target reported max download size of 536870912 bytes sending 'boot' (56066 KB)... OKAY [ 1.469s] writing 'boot'... OKAY [ 0.586s] finished. total time: 2.055s target reported max download size of 536870912 bytes erasing 'system'... OKAY [ 0.006s] sending sparse 'system' 1/4 (523027 KB)... OKAY [ 14.336s] writing 'system' 1/4... OKAY [ 11.602s] sending sparse 'system' 2/4 (522223 KB)... OKAY [ 14.005s] writing 'system' 2/4... OKAY [ 9.452s] sending sparse 'system' 3/4 (524029 KB)... OKAY [ 14.604s] writing 'system' 3/4... OKAY [ 11.660s] sending sparse 'system' 4/4 (5696 KB)... OKAY [ 0.196s] writing 'system' 4/4... OKAY [ 0.165s] finished. total time: 76.028s target reported max download size of 536870912 bytes sending 'persist' (4292 KB)... OKAY [ 0.167s] writing 'persist'... OKAY [ 0.090s] finished. total time: 0.257s target reported max download size of 536870912 bytes erasing 'cache'... OKAY [ 0.019s] sending 'cache' (5152 KB)... OKAY [ 0.178s] writing 'cache'... OKAY [ 0.085s] finished. total time: 0.282s target reported max download size of 536870912 bytes sending 'recoveryfs' (126585 KB)... OKAY [ 3.312s] writing 'recoveryfs'... OKAY [ 3.899s] finished. total time: 7.211s [INFO] Done flashing all images. Rebooting device in 2 seconds rebooting... finished. total time: 0.071s [INFO] Waiting for device... ModalAI 3.2.0 BUILDER: ekatzfey BUILD_TIME: 2021-02-05_19:54 [INFO] Finished! The next step is to follow the VOXL Quickstart guides to connect to a network and install supporting software. https://docs.modalai.com/voxl-quickstarts/ [INFO] Finished installing the base System Image ================================================================= We highly recommend installing the voxl-suite software package which provides ModalAI Algorithms and supporting software. This platform installer includes voxl-suite for offline install. Note, if your VOXL is currently connected to the internet this installer will pull the latest voxl-suite, otherwise it will install only the packages bundled with this offline installer. If your VOXL is online right now and you wish to only install the the bundled packages without upgrading, you can adb into voxl in another terminal, unconfigure wifi, and reboot before continuing with the installer in this terminal. Do you want to install voxl-suite now? (y/n) ================================================================= y [INFO] adb installed [INFO] Waiting for device [INFO] updating /etc/opkg/opkg.conf on target [INFO] Pushing package manifest to target Packages.gz: 1 file pushed. 0.5 MB/s (3323 bytes in 0.006s) Packages.stamps: 1 file pushed. 0.5 MB/s (2179 bytes in 0.004s) docker_1.9.0+git76d6bc9a9f1690e16f3721...d. 2.5 MB/s (10813204 bytes in 4.149s) libmodal_json_0.3.4.ipk: 1 file pushed. 1.1 MB/s (57698 bytes in 0.052s) libmodal_pipe_1.7.9.ipk: 1 file pushed. 2.5 MB/s (82312 bytes in 0.031s) librc_math_1.1.4.ipk: 1 file pushed. 2.6 MB/s (133732 bytes in 0.048s) libvoxl_io_0.5.4.ipk: 1 file pushed. 2.8 MB/s (109262 bytes in 0.037s) mavlink-camera-manager_0.0.1.ipk: 1 fi...shed. 2.2 MB/s (29268 bytes in 0.013s) opencv_4.5.1.ipk: 1 file pushed. 2.7 MB/s (18115366 bytes in 6.290s) openmp_10.0.1_202102091950.ipk: 1 file...hed. 2.2 MB/s (402468 bytes in 0.174s) voxl-camera-server_0.5.7.ipk: 1 file p...hed. 2.6 MB/s (606614 bytes in 0.219s) voxl-dfs-server_0.0.7.ipk: 1 file pushed. 0.7 MB/s (30536 bytes in 0.041s) voxl-docker-support_1.1.1.ipk: 1 file pushed. 1.6 MB/s (6392 bytes in 0.004s) voxl-gphoto2_0.0.5.ipk: 1 file pushed. 2.2 MB/s (33240 bytes in 0.015s) voxl-hal3-tof-cam-ros_0.0.5.ipk: 1 fil...hed. 2.8 MB/s (563554 bytes in 0.193s) voxl-imu-server_0.7.8.ipk: 1 file pushed. 2.5 MB/s (59792 bytes in 0.023s) voxl-modem_0.11.0.ipk: 1 file pushed. 2.7 MB/s (1238720 bytes in 0.432s) voxl-mpa-tflite-server_0.0.2.ipk: 1 fi...d. 2.8 MB/s (25555962 bytes in 8.776s) voxl-mpa-tools_0.1.6.ipk: 1 file pushed. 1.4 MB/s (85424 bytes in 0.058s) voxl-nodes_0.1.3.ipk: 1 file pushed. 2.8 MB/s (1122746 bytes in 0.386s) voxl-qvio-server_0.2.1.ipk: 1 file pushed. 1.7 MB/s (160472 bytes in 0.090s) voxl-rtsp_1.0.3.ipk: 1 file pushed. 2.9 MB/s (173760 bytes in 0.058s) voxl-streamer_0.2.1.ipk: 1 file pushed. 2.3 MB/s (47002 bytes in 0.020s) voxl-suite_0.3.4.ipk: 1 file pushed. 0.5 MB/s (1818 bytes in 0.003s) voxl-utils_0.6.0.ipk: 1 file pushed. 2.3 MB/s (41092 bytes in 0.017s) voxl-vision-px4_0.8.1.ipk: 1 file pushed. 2.5 MB/s (58980 bytes in 0.023s) voxl-vpn_0.0.3.ipk: 1 file pushed. 1.9 MB/s (14528 bytes in 0.007s) [INFO] Installing voxl-suite on target Downloading http://voxl-packages.modalai.com/stable/Packages.gz. wget: bad address 'voxl-packages.modalai.com' Downloading file:///home/root/voxl-suite-ipk/Packages.gz. Updated source 'local'. Collected errors: * opkg_download_backend: Failed to download http://voxl-packages.modalai.com/stable/Packages.gz, wget returned 1. Installing voxl-suite (0.3.4) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-suite_0.3.4.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Upgrading voxl-utils from 0.5.1 to 0.6.0 on root. Downloading file:///home/root/voxl-suite-ipk/voxl-utils_0.6.0.ipk. Installing libmodal_json (0.3.4) on root. Downloading file:///home/root/voxl-suite-ipk/libmodal_json_0.3.4.ipk. Installing libmodal_pipe (1.7.9) on root. Downloading file:///home/root/voxl-suite-ipk/libmodal_pipe_1.7.9.ipk. Installing librc_math (1.1.4) on root. Downloading file:///home/root/voxl-suite-ipk/librc_math_1.1.4.ipk. Installing libvoxl_io (0.5.4) on root. Downloading file:///home/root/voxl-suite-ipk/libvoxl_io_0.5.4.ipk. Installing mavlink-camera-manager (0.0.1) on root. Downloading file:///home/root/voxl-suite-ipk/mavlink-camera-manager_0.0.1.ipk. Installing opencv (4.5.1) on root. Downloading file:///home/root/voxl-suite-ipk/opencv_4.5.1.ipk. Installing openmp (10.0.1) on root. Downloading file:///home/root/voxl-suite-ipk/openmp_10.0.1_202102091950.ipk. Installing voxl-camera-server (0.5.7) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-camera-server_0.5.7.ipk. Installing voxl-dfs-server (0.0.7) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-dfs-server_0.0.7.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Installing voxl-gphoto2 (0.0.5) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-gphoto2_0.0.5.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Installing voxl-hal3-tof-cam-ros (0.0.5) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-hal3-tof-cam-ros_0.0.5.ipk. Installing voxl-imu-server (0.7.8) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-imu-server_0.7.8.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Installing voxl-modem (0.11.0) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-modem_0.11.0.ipk. Installing voxl-mpa-tflite-server (0.0.2) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-mpa-tflite-server_0.0.2.ipk. Installing voxl-mpa-tools (0.1.6) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-mpa-tools_0.1.6.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Installing voxl-nodes (0.1.3) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-nodes_0.1.3.ipk. Installing voxl-qvio-server (0.2.1) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-qvio-server_0.2.1.ipk. Installing voxl-rtsp (1.0.3) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-rtsp_1.0.3.ipk. Installing voxl-streamer (0.2.1) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-streamer_0.2.1.ipk. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Installing voxl-vision-px4 (0.8.1) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-vision-px4_0.8.1.ipk. Not selecting librc_math 1.1.2 as installing it would break existing dependencies. Not selecting libmodal_pipe 1.2.2 as installing it would break existing dependencies. Installing voxl-vpn (0.0.3) on root. Downloading file:///home/root/voxl-suite-ipk/voxl-vpn_0.0.3.ipk. voxl-suite installer detected system image 3.2.0 Configuring libmodal_pipe. Done installing libmodal_pipe Configuring libmodal_json. Done installing libmodal_json Configuring openmp. done installing openmp Configuring opencv. done installing opencv Configuring voxl-dfs-server. Done installing voxl-dfs-server Configuring voxl-gphoto2. Done installing voxl-gphoto2 Configuring voxl-hal3-tof-cam-ros. Done installing voxl-hal3-tof-cam Configuring mavlink-camera-manager. Done installing mavlink-camera-manager Configuring librc_math. done installing librc_math Configuring voxl-mpa-tools. Done installing voxl-mpa-tools Configuring voxl-qvio-server. Done installing voxl-qvio-server Configuring voxl-vpn. done installing voxl-vpn Configuring libvoxl_io. Done installing libvoxl_io Configuring voxl-vision-px4. Done installing voxl-vision-px4 Configuring voxl-mpa-tflite-server. Done installing voxl-mpa-tflite-server Configuring voxl-streamer. INFO: making new /etc/modalai/voxl-streamer.conf Done installing voxl-streamer Configuring voxl-imu-server. enabling voxl-imu-server service Created symlink from /etc/systemd/system/multi-user.target.wants/voxl-imu-server.service to /etc/systemd/system/voxl-imu-server.service. Done installing voxl-imu-server Configuring voxl-camera-server. making default config file: /etc/modalai/voxl-camera-server.conf Done installing voxl-camera-server Configuring voxl-modem. Disabling and removing any old modem scripts. done installing voxl-modem Configuring voxl-utils. done installing voxl-utils Configuring voxl-nodes. Done installing voxl-nodes Configuring voxl-rtsp. done installing rtsp Configuring voxl-suite. ===================================================== | Done installing voxl-suite | | | | Please visit our online quickstart guides at | | https://docs.modalai.com/quickstarts/ | | | | To configure Modal Pipe Architecture (MPA) | | services, please run voxl-configure-mpa | | | | To see what MPA services are enabled and running, | | please run voxl-inspect-services | | | | To see a list of MPA utilities available, adb | | or ssh into VOXL and type voxl{TAB}{TAB} | ===================================================== [INFO] Done installing voxl-suite swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.3.4-b$ |
성공적으로 인스톨이 되고 나면 VOXL을 재부팅후 버전을 확인한다.
swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.2.0$ adb shell / # bash yocto:/# voxl-version cat: /etc/modalai/voxl-software-bundle-version.txt: No such file or directory -------------------------------------------------------------------------------- system-image: ModalAI 3.2.0 BUILDER: ekatzfey BUILD_TIME: 2021-02-05_19:54 kernel: #1 SMP PREEMPT Fri Feb 5 20:03:22 UTC 2021 3.18.71-perf factory-bundle: 1.0.1 (Yocto installation) -------------------------------------------------------------------------------- architecture: aarch64 processor: apq8096 os: GNU/Linux -------------------------------------------------------------------------------- voxl-suite: Package: voxl-suite Version: 0.3.4 Depends: voxl-utils (>= 0.6.0), libmodal_json (>= 0.3.4), libmodal_pipe (>= 1.7.8), librc_math (>= 1.1.4), libvoxl_io (>= 0.5.4), mavlink-camera-manager (>= 0.0.1), opencv (>= 4.5.1), openmp (>= 10.0.1), voxl-camera-server (>= 0.5.6), voxl-dfs-server (>= 0.0.7), voxl-docker-support (>= 1.1.1), voxl-gphoto2 (>= 0.0.5), voxl-hal3-tof-cam-ros (>= 0.0.5), voxl-imu-server (>= 0.7.8), voxl-modem (>= 0.11.0), voxl-mpa-tflite-server (>= 0.0.2), voxl-mpa-tools (>= 0.1.6), voxl-nodes (>= 0.1.3), voxl-qvio-server (>= 0.2.1), voxl-rtsp (>= 1.0.3), voxl-streamer (>= 0.2.1), voxl-vision-px4 (>= 0.8.1), voxl-vpn (>= 0.0.3) Status: install user installed Section: base Architecture: all Maintainer: james@modalai.com MD5Sum: e1e5bf1a125affe5036099f6ce895bed Size: 1818 Filename: voxl-suite_0.3.4.ipk Description: meta-package for voxl-suite stable release Installed-Time: 411 Package: voxl-suite Version: 0.2.0 Depends: docker, imu_app (= 0.0.6), libvoxl_io (= 0.5.2), voxl-cam-manager (= 0.2.2), voxl-docker-support (= 1.1.1), voxl-hal3-tof-cam-ros (= 0.0.2), voxl-modem (= 0.10.0), voxl-nodes (= 0.0.8), voxl-rtsp (= 1.0.2), voxl-utils (= 0.5.2), voxl-vision-px4 (= 0.6.8), voxl_imu (= 0.0.4), voxl-time-sync (= 0.0.1), voxl-vpn (= 0.0.2), librc_math (= 1.1.2), libmodal_pipe (= 1.2.2), modalai-vl (= 0.1.3) Status: unknown ok not-installed Section: base Architecture: armv7a Maintainer: james@modalai.com MD5Sum: af706cd3c1ea59f274f2ed9b93141f1d Size: 870 Filename: voxl-suite_0.2.0.ipk Description: meta-package to install all of the voxl-suite -------------------------------------------------------------------------------- yocto:/# |
와이파이를 스테이션 모드로 세팅한다.
yocto:/# voxl-wifi --help Description: Configure the Wi-Fi mode. NOTE: a reboot is required to complete the setup. Usage: voxl-wifi getmode Print the current mode (softap of station) voxl-wifi softap <ssid> [country code] Set Wi-Fi to Access Point mode. Optional country code defaults to 'us' Password defaults to '1234567890' voxl-wifi station <ssid> [password] [country code] Set the Wi-Fi to station mode and connect to the AP with provided SSID and (optional) password. Note: if your password has special characters surround it with quotes. Optional country code defaults to 'us' voxl-wifi -f Set the Wi-Fi to Access Point mode and SSID to VOXL-MACADDRESS Password defaults to '1234567890' yocto:/# voxl-wifi station U+Net659B 6000234350 backing up wpa_supplicant.conf creating new wpa_supplicant.conf for station mode Reboot for changes to take effect yocto:/# reboot yocto:/# swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.2.0$ swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.2.0$ adb shell / # bash yocto:/# ifconfig lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:16 errors:0 dropped:0 overruns:0 frame:0 TX packets:16 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:1168 (1.1 KiB) TX bytes:1168 (1.1 KiB) wlan0 Link encap:Ethernet HWaddr EC:5C:68:CD:25:A1 inet addr:192.168.219.101 Bcast:192.168.219.255 Mask:255.255.255.0 inet6 addr: fe80::ee5c:68ff:fecd:25a1/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:36 errors:0 dropped:0 overruns:0 frame:0 TX packets:42 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:3000 RX bytes:3787 (3.6 KiB) TX bytes:3962 (3.8 KiB) yocto:/# |
호스트의 IP도 확인한다.
swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.3.4-b$ ifconfig eno1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 14.7.31.89 netmask 255.255.255.0 broadcast 14.7.31.255 inet6 fe80::723b:e82a:210c:d5f prefixlen 64 scopeid 0x20<link> ether a0:b3:cc:52:14:b8 txqueuelen 1000 (Ethernet) RX packets 152335 bytes 118577865 (118.5 MB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 34443 bytes 3062775 (3.0 MB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 1000 (Local Loopback) RX packets 11368 bytes 76082527 (76.0 MB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 11368 bytes 76082527 (76.0 MB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 wlo1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.219.182 netmask 255.255.255.0 broadcast 192.168.219.255 inet6 fe80::6fd6:734f:3553:baf4 prefixlen 64 scopeid 0x20<link> ether 60:6c:66:81:e7:19 txqueuelen 1000 (Ethernet) RX packets 1345 bytes 214166 (214.1 KB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 677 bytes 73220 (73.2 KB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 swift@swift-HP-Pavilion-dv6-Notebook-PC:~/workspace/modalai-3-2-0-0.3.4-b$ |
voxl-rtsp 테스트
이유는 아직 알수 없지만 QGroundControl에서는 RTSP 영상을 볼 수 없었고, VLC에서 스트림으로 볼 수 확인할 수 있었다.
yocto:/# ls WEBSERVER cache etc lib64 mnt run srv tmp bin data firmware linuxrc opt sbin sys usr boot dev home lost+found persist sdcard system var build.prop dsp lib media proc share target vendor yocto:/# voxl-rtsp voxl-rtsp version 1.0.3 Connected Started camera 0 Created session Video track created Updated camera parameters AE Mode: 1, Exposure: 0us, Gain: 0us, AWB Mode: 1 rtsp://192.168.219.101:8900/live Camera Control FIFO starting: /dev/camera0_control Started session Ctrl-c or 'kill 3220' to end ^C[1307.312840] fps 30.07, size 33922 Stopped session fps 30.07, size 3248 Video track deleted Session deleted Stopped Camera Disconnected voxl-rtsp exiting Summary: Camera # : 0 Resolution : 640x480 Format : h264 FPS Desired : 30.00 FPS Actual : 30.07 Duration (s) : 853.655 Frame Count : 25658 Total Size (MB) : 101.74 Bandwidth (Mbps) : 0.95 Bytes per Frame : 4157 yocto:/# |
voxl-streamer 테스트
테스트패턴
yocto:/# voxl-streamer -c video-test Using configuration video-test Using configuration file /etc/modalai/voxl-streamer.conf Stream available at rtsp://127.0.0.1:8900/live A new client has connected to the RTSP server |
voxl-streamer를 사용하기 위해서는 mpa 모듈이 설정되어야 한다. 아래는 mpa를 설정하는 과정이다.
yocto:/# voxl-configure-mpa Configuring Extrinsics configuring /etc/modalai/extrinsics.conf Would you like to leave this extrinsics config file alone, reset to factory defaults, or use a preset config? 1) leave_alone 2) defaults 3) preset #? 2 resetting extrinsics config file to factory defaults note, you can do this in the future with voxl-configure-extrinsics -f Configuring Cameras Which camera configuration are you using? 0 None 1 Tracking + Stereo 2 Tracking Only 3 Hires + Stereo + Tracking (default) 4 Hires + Tracking 5 TOF + Tracking 6 Hires + TOF + Tracking 7 TOF + Stereo + Tracking 8 Hires Only 9 TOF Only 3 attempting to use camera configuration 3 Writing new configuration to /etc/modalai/voxl-camera-server.conf: { "version": 0.2, "port_J2": { "name": "hires", "enabled": true, "type": "hires", "api": "hal3", "rotation": 180, "frame_rate": 30, "override_id": -1, "auto_exposure_mode": "isp", "preview": { "enabled": true, "width": 640, "height": 480, "format": "nv21" }, "video": { "enabled": false, "width": 1024, "height": 768, "format": "h264" }, "snapshot": { "enabled": false, "width": 1024, "height": 768, "format": "jpg" } }, "port_J3": { "name": "stereo", "enabled": true, "type": "stereo", "api": "hal3", "rotation": 0, "frame_rate": 30, "override_id": -1, "auto_exposure_mode": "mvcpa", "mv_cpa_filter_size": 2, "mv_cpa_exposure_cost": 0.75, "mv_cpa_gain_cost": 0.25, "mv_cpa_en_histogram": true, "preview": { "enabled": true, "width": 1280, "height": 480, "format": "nv21" } }, "port_J4": { "name": "tracking", "enabled": true, "type": "tracking", "api": "hal3", "rotation": 0, "frame_rate": 30, "override_id": -1, "auto_exposure_mode": "mvcpa", "manual_gain": 1000, "mv_cpa_filter_size": 2, "mv_cpa_exposure_cost": 0.75, "mv_cpa_gain_cost": 0.25, "mv_cpa_en_histogram": true, "preview": { "enabled": true, "width": 640, "height": 480, "format": "raw8" } } } would you like to enable voxl-camera-server? This is necessary for VIO and DFS 1) enable 2) disable #? 1) enable 2) disable #? 11 invalid option #? 1 Created symlink from /etc/systemd/system/multi-user.target.wants/voxl-camera-server.service to /etc/systemd/system/voxl-camera-server.service. Configuring QVIO loading and updating config file with voxl-qvio-server -c loading qvio config file Creating new config file: /etc/modalai/voxl-qvio-server.conf The config file was modified during parsing, saving the changes to disk Do you want to enable voxl-qvio-server for Visual Inertial Odometry? 1) yes 2) no #? 1 Which IMU should voxl-qvio-server use? We recommend IMU1 for VOXL and IMU0 for VOXL Flight all-in-one board. 1) imu0 2) imu1 #? 1 enabling voxl-qvio-server systemd service Created symlink from /etc/systemd/system/multi-user.target.wants/voxl-qvio-server.service to /etc/systemd/system/voxl-qvio-server.service. starting voxl-qvio-server systemd service Done configuring voxl-qvio-server Configuring VOXL Vision PX4 loading and updating config file with voxl-vision-px4 -c Do you want to enable the voxl-vision-px4 service to allow communication with a PX4 flight controller? 1) yes 2) no #? 1 Now we are going to do a preliminary configuration of /etc/modalai/voxl-vision-px4.conf Which IP address is your QGroundControl station at? If you do not wish to hard-code the QGC IP address into VOXL then you will need to configure VOXL's IP address in QGC's Comm Links settings page. Just press enter to leave this option as-is. 192.168.219.182 setting qgc_ip to 192.168.219.182 Do you want to enable voxl-vision-px4 to command PX4 to fly a figure eight path when flipped into offboard mode? Don't enable this if you intend to do your own offboard control via MAVROS or similar. 1) yes 2) no #? 1 enabling voxl-vision-px4 systemd service starting voxl-vision-px4 systemd service DONE configuring voxl-vision-px4 Done enabling services, reboot to complete setup would you like to reboot now or later? 1) reboot_now 2) reboot_later #? 1 rebooting now Finished running voxl-configure-mpa |
재부팅후 voxl-streamer를 실행한다.
yocto:/# voxl-streamer -c hires-mpa Using configuration hires-mpa Using configuration file /etc/modalai/voxl-streamer.conf requesting name voxl-streamer0 with complete path /run/mpa/hires_preview/voxl-streamer0 connected after 1 attempt(s) Stream available at rtsp://127.0.0.1:8900/live A new client has connected to the RTSP server % 클라언트가 연결되면 메시지 나타남 |
어
voxl-streamer에서는 hires-camera 영상이 반전되어 나온다.
스테레오 카메라 확인
yocto:/# voxl-streamer -c stereo-mpa Using configuration stereo-mpa Using configuration file /etc/modalai/voxl-streamer.conf requesting name voxl-streamer0 with complete path /run/mpa/stereo/voxl-streamer0 connected after 1 attempt(s) Stream available at rtsp://127.0.0.1:8900/live A new client has connected to the RTSP server |
tracking 카메라 확인
yocto:/# voxl-streamer -c tracking-mpa Using configuration tracking-mpa Using configuration file /etc/modalai/voxl-streamer.conf requesting name voxl-streamer0 with complete path /run/mpa/tracking/voxl-streamer0 connected after 1 attempt(s) Stream available at rtsp://127.0.0.1:8900/live |
ROS 연결설정
VOXL은 ROS 마스터가 된다. VOXL에서 ROS_IP는 자신의 IP를 입력한다.
yocto:/# voxl-env show ROS_MASTER_URI=http:192.168.219.101 ROS_IP=192.168.219.101 CAM_CONFIG_ID=3 HIRES_CAM_ID=0 TRACKING_CAM_ID=1 STEREO_CAM_ID=2 TOF_CAM_ID=-1 yocto:/# ifconfig lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:65536 Metric:1 RX packets:77206 errors:0 dropped:0 overruns:0 frame:0 TX packets:77206 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:8224356 (7.8 MiB) TX bytes:8224356 (7.8 MiB) wlan0 Link encap:Ethernet HWaddr EC:5C:68:CD:25:A1 inet addr:192.168.219.101 Bcast:192.168.219.255 Mask:255.255.255.0 inet6 addr: fe80::ee5c:68ff:fecd:25a1/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:188 errors:0 dropped:0 overruns:0 frame:0 TX packets:36414 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:3000 RX bytes:21293 (20.7 KiB) TX bytes:3877738 (3.6 MiB) yocto:/# roscore invalid master URI: http:192.168.219.101 The traceback for the exception was written to the log file yocto:/# vi /home/root/my_ros_env.sh yocto:/# roscore invalid master URI: http:192.168.219.101 The traceback for the exception was written to the log file yocto:/# reboot swift@swift-HP-Pavilion-dv6-Notebook-PC:~$ adb shell / # bash yocto:/# yocto:/# yocto:/# yocto:/# yocto:/# roscore ... logging to /home/root/.ros/log/2a9340cc-1dd2-11b2-a611-ec5c68cd25a1/roslaunch-apq8096-3358.log Checking log directory for disk usage. This may take awhile. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB. started roslaunch server http://192.168.219.101:37117/ ros_comm version 1.11.21 SUMMARY ======== PARAMETERS * /rosdistro: indigo * /rosversion: 1.11.21 NODES auto-starting new master process[master]: started with pid [3377] ROS_MASTER_URI=http://192.168.219.101:11311/ setting /run_id to 2a9340cc-1dd2-11b2-a611-ec5c68cd25a1 process[rosout-1]: started with pid [3390] started core service [/rosout] |
호스트는 클라이언트가 되고 MATER의 IP는 VOXL의 IP를 입력하고 ROS_IP는 자신의 IP를 입력한다.
roscore를 VOXL에서 실행하고 호스트에서 토픽을 확인한다. 정상적으로 연결이 되었을 경우 아래와 같이 두개의 노드가 호스트에서 보이게 된다.
swift@swift-HP-Pavilion-dv6-Notebook-PC:~$ rostopic list /rosout /rosout_agg |
'엔지니어링 > 드론' 카테고리의 다른 글
[ VOXL ] VIsual Odometry (0) | 2021.04.18 |
---|---|
[ VOXL ] Camera Calibration (0) | 2021.04.18 |
[ VOXL ] VOXL Development Kit 확인 (0) | 2021.04.09 |
[ VOXL ] VOA(Visual Obstacle Avoidance) 의 stereo camera calibration (2) | 2021.04.04 |
[ VOXL ] Vision Odometery (0) | 2021.03.26 |
댓글