์ด๊ฒ์ ๋ฒ๊ทธ ๋ฐ ๊ธฐ๋ฅ ์ถ์ ๊ธฐ ์ผ ๋ฟ์ด๋ฏ๋ก ์ฌ์ฉํ์ญ์์ค
๋ฒ๊ทธ๋ฅผ๋ณด๊ณ ํ๊ฑฐ๋ ๊ธฐ๋ฅ์ ์์ฒญํฉ๋๋ค.
mavftp๋ฅผ ํตํด .px4log๋ฅผ ๋ค์ด๋ก๋ํ๋ ค๊ณ ํ๋ฉด ๋ค์ ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค.
ubuntu<strong i="10">@ubuntu</strong>:~$ rosrun mavros mavftp download /fs/microsd/log/2016-11-01/21_43_29.px4log
Prigressbar disabled. install python-progressbar
Traceback (most recent call last):
File "/opt/ros/indigo/lib/mavros/mavftp", line 296, in <module>
main()
File "/opt/ros/indigo/lib/mavros/mavftp", line 292, in main
args.func(args)
File "/opt/ros/indigo/lib/mavros/mavftp", line 152, in do_download
buf = from_fd.read(FTP_PAGE_SIZE)
File "/opt/ros/indigo/lib/python2.7/dist-packages/mavros/ftp.py", line 107, in read
_check_raise_errno(ret)
File "/opt/ros/indigo/lib/python2.7/dist-packages/mavros/ftp.py", line 39, in _check_raise_errno
raise IOError(ret.r_errno, os.strerror(ret.r_errno))
IOError: [Errno 110] Connection timed out
๋ฐ๋ผ์ ์ฃผ roslaunch mavros ์ฐฝ์ด ํ์๋๋ฉด ํ์ผ์ ์ด ์ ์์ต๋๋ค.
[ INFO] [1491328759.740312395]: FTP:Open /fs/microsd/log/2016-11-01/21_43_29.px4log: success, session 0, size 263247
ํ์ง๋ง ํ์ผ์ ์ฝ์ ๋ [Errno 110] Connection timed out ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค.
๋ง ๋ธ๋ก์ค : 0.17.4
ROS : ์ธ๋๊ณ
Ubuntu : 14.04
[] ArduPilot
[X] PX4
๋ฒ์ : 1.1
ubuntu<strong i="26">@ubuntu</strong>:~$ roslaunch mavros px4.launch fcu_url:="/dev/ttyUSB0:921600"
... logging to /home/ubuntu/.ros/log/4bfe2358-1960-11e7-a396-54ee75c35d17/roslaunch-ubuntu-10479.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://ubuntu:40096/
SUMMARY
========
CLEAR PARAMETERS
* /mavros/
PARAMETERS
* /mavros/cmd/use_comp_id_system_control: False
* /mavros/conn/heartbeat_rate: 1.0
* /mavros/conn/system_time_rate: 1.0
* /mavros/conn/timeout: 10.0
* /mavros/conn/timesync_rate: 10.0
* /mavros/distance_sensor/hrlv_ez4_pub/field_of_view: 0.0
* /mavros/distance_sensor/hrlv_ez4_pub/frame_id: hrlv_ez4_sonar
* /mavros/distance_sensor/hrlv_ez4_pub/id: 0
* /mavros/distance_sensor/hrlv_ez4_pub/orientation: ROLL_180
* /mavros/distance_sensor/hrlv_ez4_pub/send_tf: True
* /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/x: 0.0
* /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/y: 0.0
* /mavros/distance_sensor/hrlv_ez4_pub/sensor_position/z: -0.1
* /mavros/distance_sensor/laser_1_sub/id: 3
* /mavros/distance_sensor/laser_1_sub/orientation: ROLL_180
* /mavros/distance_sensor/laser_1_sub/subscriber: True
* /mavros/distance_sensor/lidarlite_pub/field_of_view: 0.0
* /mavros/distance_sensor/lidarlite_pub/frame_id: lidarlite_laser
* /mavros/distance_sensor/lidarlite_pub/id: 1
* /mavros/distance_sensor/lidarlite_pub/orientation: ROLL_180
* /mavros/distance_sensor/lidarlite_pub/send_tf: True
* /mavros/distance_sensor/lidarlite_pub/sensor_position/x: 0.0
* /mavros/distance_sensor/lidarlite_pub/sensor_position/y: 0.0
* /mavros/distance_sensor/lidarlite_pub/sensor_position/z: -0.1
* /mavros/distance_sensor/sonar_1_sub/id: 2
* /mavros/distance_sensor/sonar_1_sub/orientation: ROLL_180
* /mavros/distance_sensor/sonar_1_sub/subscriber: True
* /mavros/fcu_url: /dev/ttyUSB0:921600
* /mavros/gcs_url:
* /mavros/global_position/frame_id: fcu
* /mavros/global_position/rot_covariance: 99999.0
* /mavros/global_position/tf/child_frame_id: fcu_utm
* /mavros/global_position/tf/frame_id: local_origin
* /mavros/global_position/tf/send: False
* /mavros/image/frame_id: px4flow
* /mavros/imu/angular_velocity_stdev: 0.000349065850399
* /mavros/imu/frame_id: fcu
* /mavros/imu/linear_acceleration_stdev: 0.0003
* /mavros/imu/magnetic_stdev: 0.0
* /mavros/imu/orientation_stdev: 1.0
* /mavros/local_position/frame_id: fcu
* /mavros/local_position/tf/child_frame_id: fcu
* /mavros/local_position/tf/frame_id: local_origin
* /mavros/local_position/tf/send: False
* /mavros/local_position/tf/send_fcu: False
* /mavros/mission/pull_after_gcs: True
* /mavros/mocap/use_pose: True
* /mavros/mocap/use_tf: False
* /mavros/plugin_blacklist: ['safety_area', '...
* /mavros/plugin_whitelist: []
* /mavros/px4flow/frame_id: px4flow
* /mavros/px4flow/ranger_fov: 0.0
* /mavros/px4flow/ranger_max_range: 5.0
* /mavros/px4flow/ranger_min_range: 0.3
* /mavros/safety_area/p1/x: 1.0
* /mavros/safety_area/p1/y: 1.0
* /mavros/safety_area/p1/z: 1.0
* /mavros/safety_area/p2/x: -1.0
* /mavros/safety_area/p2/y: -1.0
* /mavros/safety_area/p2/z: -1.0
* /mavros/setpoint_accel/send_force: False
* /mavros/setpoint_attitude/reverse_throttle: False
* /mavros/setpoint_attitude/tf/child_frame_id: attitude
* /mavros/setpoint_attitude/tf/frame_id: local_origin
* /mavros/setpoint_attitude/tf/listen: False
* /mavros/setpoint_attitude/tf/rate_limit: 10.0
* /mavros/setpoint_position/tf/child_frame_id: setpoint
* /mavros/setpoint_position/tf/frame_id: local_origin
* /mavros/setpoint_position/tf/listen: False
* /mavros/setpoint_position/tf/rate_limit: 50.0
* /mavros/startup_px4_usb_quirk: True
* /mavros/sys/disable_diag: False
* /mavros/sys/min_voltage: 10.0
* /mavros/target_component_id: 1
* /mavros/target_system_id: 1
* /mavros/tdr_radio/low_rssi: 40
* /mavros/time/time_ref_source: fcu
* /mavros/time/timesync_avg_alpha: 0.6
* /mavros/vibration/frame_id: vibration
* /mavros/vision_pose/tf/child_frame_id: vision
* /mavros/vision_pose/tf/frame_id: local_origin
* /mavros/vision_pose/tf/listen: False
* /mavros/vision_pose/tf/rate_limit: 10.0
* /mavros/vision_speed/listen_twist: False
* /rosdistro: indigo
* /rosversion: 1.11.20
NODES
/
mavros (mavros/mavros_node)
auto-starting new master
process[master]: started with pid [10491]
ROS_MASTER_URI=http://localhost:11311/
setting /run_id to 4bfe2358-1960-11e7-a396-54ee75c35d17
process[rosout-1]: started with pid [10504]
started core service [/rosout]
process[mavros-2]: started with pid [10522]
[ INFO] [1491328704.639977423]: FCU URL: /dev/ttyUSB0:921600
[ INFO] [1491328704.640148669]: serial0: device: /dev/ttyUSB0 @ 921600 bps
[ INFO] [1491328704.640857865]: GCS bridge disabled
[ INFO] [1491328704.678791638]: Plugin 3dr_radio loaded and initialized
[ INFO] [1491328704.681584591]: Plugin actuator_control loaded and initialized
[ INFO] [1491328704.682806790]: Plugin altitude loaded and initialized
[ INFO] [1491328704.734773858]: Plugin cam_imu_sync loaded and initialized
[ INFO] [1491328704.741470118]: Plugin command loaded and initialized
[ INFO] [1491328704.741573052]: Plugin distance_sensor blacklisted
[ INFO] [1491328704.755546619]: Plugin ftp loaded and initialized
[ INFO] [1491328704.766173170]: Plugin global_position loaded and initialized
[ INFO] [1491328704.767192333]: Plugin hil_controls loaded and initialized
[ INFO] [1491328704.767303516]: Plugin image_pub blacklisted
[ INFO] [1491328704.778053521]: Plugin imu_pub loaded and initialized
[ INFO] [1491328704.784409686]: Plugin local_position loaded and initialized
[ INFO] [1491328704.785040013]: Plugin manual_control loaded and initialized
[ INFO] [1491328704.789160066]: IMU: High resolution IMU detected!
[ INFO] [1491328704.793286286]: Plugin mocap_pose_estimate loaded and initialized
[ INFO] [1491328704.795783133]: Plugin param loaded and initialized
[ INFO] [1491328704.803470692]: Plugin px4flow loaded and initialized
[ INFO] [1491328704.810457093]: Plugin rc_io loaded and initialized
[ INFO] [1491328704.810504287]: Plugin safety_area blacklisted
[ INFO] [1491328704.814195357]: Plugin setpoint_accel loaded and initialized
[ INFO] [1491328704.833646784]: Plugin setpoint_attitude loaded and initialized
[ INFO] [1491328704.843787243]: Plugin setpoint_position loaded and initialized
[ INFO] [1491328704.854228533]: Plugin setpoint_raw loaded and initialized
[ INFO] [1491328704.857035208]: Plugin setpoint_velocity loaded and initialized
[ INFO] [1491328704.868906236]: Plugin sys_status loaded and initialized
[ INFO] [1491328704.872289296]: Plugin sys_time loaded and initialized
[ INFO] [1491328704.873499821]: Plugin vfr_hud loaded and initialized
[ INFO] [1491328704.873528131]: Plugin vibration blacklisted
[ INFO] [1491328704.886149274]: Plugin vision_pose_estimate loaded and initialized
[ INFO] [1491328704.892185325]: Plugin vision_speed_estimate loaded and initialized
[ INFO] [1491328704.898632965]: Plugin waypoint loaded and initialized
[ INFO] [1491328704.899156813]: Autostarting mavlink via USB on PX4
[ INFO] [1491328704.899568244]: Built-in SIMD instructions: SSE, SSE2
[ INFO] [1491328704.899737606]: Built-in MAVLink package version: 2016.5.20
[ INFO] [1491328704.899814667]: Built-in MAVLink dialect: ardupilotmega
[ INFO] [1491328704.899913235]: MAVROS started. MY ID 1.240, TARGET ID 1.1
[ WARN] [1491328704.977042906]: TM: Clock skew detected (-1491328273.724662542 s). Hard syncing clocks.
[ INFO] [1491328705.728264902]: CON: Got HEARTBEAT, connected. FCU: PX4
[ INFO] [1491328705.730098822]: IMU: High resolution IMU detected!
[ INFO] [1491328706.741017002]: VER: 1.1: Capabilities 0x00000000000004eb
[ INFO] [1491328706.741277778]: VER: 1.1: Flight software: 00000000 (328018937301dc7e)
[ INFO] [1491328706.741430544]: VER: 1.1: Middleware software: 00000000 (328018937301dc7e)
[ INFO] [1491328706.741573285]: VER: 1.1: OS software: 00000000 (0000000000000000)
[ INFO] [1491328706.741672549]: VER: 1.1: Board hardware: 00000000
[ INFO] [1491328706.741741415]: VER: 1.1: VID/PID: 26ac:0011
[ INFO] [1491328706.741793858]: VER: 1.1: UID: 3135511735333436
[ WARN] [1491328716.730309039]: PR: request list timeout, retries left 2
[ WARN] [1491328717.730709455]: PR: request list timeout, retries left 1
[ WARN] [1491328718.731847404]: PR: request list timeout, retries left 0
[ INFO] [1491328720.737982744]: WP: mission received
[ WARN] [1491328740.830436979]: TM: Clock skew detected (0.024262897 s). Hard syncing clocks.
[ INFO] [1491328759.740312395]: FTP:Open /fs/microsd/log/2016-11-01/21_43_29.px4log: success, session 0, size 263247
header:
seq: 27
stamp:
secs: 1491329484
nsecs: 383406366
frame_id: ''
status:
-
level: 0
name: mavros: FCU connection
message: connected
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Received packets:
value: 8489
-
key: Dropped packets:
value: 0
-
key: Buffer overruns:
value: 0
-
key: Parse errors:
value: 0
-
key: Rx sequence number:
value: 177
-
key: Tx sequence number:
value: 138
-
key: Rx total bytes:
value: 346726
-
key: Tx total bytes:
value: 22004
-
key: Rx speed:
value: 17138.000000
-
key: Tx speed:
value: 709.000000
-
level: 2
name: mavros: GPS
message: No satellites
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Satellites visible
value: 0
-
key: Fix type
value: 0
-
key: EPH (m)
value: Unknown
-
key: EPV (m)
value: Unknown
-
level: 0
name: mavros: Heartbeat
message: Normal
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Heartbeats since startup
value: 29
-
key: Frequency (Hz)
value: 0.962921
-
key: Vehicle type
value: VTOL-Quadrotor
-
key: Autopilot type
value: PX4
-
key: Mode
value: MANUAL
-
key: System status
value: Uninit
-
level: 0
name: mavros: System
message: Normal
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Sensor present
value: 0x00000000
-
key: Sensor enabled
value: 0x00000000
-
key: Sensor helth
value: 0x00000000
-
key: CPU Load (%)
value: 74.6
-
key: Drop rate (%)
value: 0.0
-
key: Errors comm
value: 0
-
key: Errors count #1
value: 0
-
key: Errors count #2
value: 0
-
key: Errors count #3
value: 0
-
key: Errors count #4
value: 0
-
level: 1
name: mavros: Battery
message: Low voltage
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Voltage
value: 0.00
-
key: Current
value: 0.0
-
key: Remaining
value: -1.0
-
level: 0
name: mavros: Time Sync
message: Normal
hardware_id: /dev/ttyUSB0:921600
values:
-
key: Timesyncs since startup
value: 155
-
key: Frequency (Hz)
value: 9.999546
-
key: Last dt (ms)
value: -1.344876
-
key: Mean dt (ms)
value: 0.008980
-
key: Last system time (s)
value: 1210.658179000
-
key: Time offset (s)
value: 1491328273.698000193
---
OK. I got messages from 1:1.
---
Received 4327 messages, from 1 addresses
sys:comp list of messages
1:1 32, 1, 2, 36, 147, 105, 74, 140, 141, 111, 76, 241, 83, 245, 251, 44, 30, 0
๋นํ ๋ก๊ทธ๋ ์ข
์ข
FTP์ ๋นํด ๋๋ฌด ํฌ๋ฉฐ, ์ด๋ค ์ด์ ๋ก ๋ USB ์ฐ๊ฒฐ์์๋ง ์์ ์ ์
๋๋ค (pihxawk์ usb-ttyACM % d).
UART์์๋ extras rc ๋๋ mixer ํ์ผ์ ์์ ํด์ผํ๋ ๊ฒฝ์ฐ์๋ง ์ ํฉํฉ๋๋ค.
๋ํ ํ์ผ ๋ค์ด๋ก๋ ์คํฌ๋ฆฝํธ ํ FCU์ ์ ์ฒด ํ์ผ์ CRC32๋ฅผ ๊ณ์ฐํ๋๋ก ์ง์ํ๊ณ ์ฌ๊ธฐ์์๋ ์๊ฐ ์ด๊ณผ๊ฐ ๋ฐ์ํ ์ ์์ต๋๋ค.
์ฐธ๊ณ : FTP๋ ๋๋ฆฌ์ง ๋ง QGC ๋ค์ด๋ก๋ ๊ตฌํ์ mavros๋ณด๋ค ๋ ๋ฐฐ ๋น ๋ฆ ๋๋ค.
์ฐธ๊ณ : FTP๋ ๋๋ฆฌ์ง ๋ง QGC ๋ค์ด๋ก๋ ๊ตฌํ์ mavros๋ณด๋ค ๋ ๋ฐฐ ๋น ๋ฆ ๋๋ค.
@vooon์ ์ฐจ์ด์ ์ ์ด๋์ ์์ต๋๊น?
QGC๋ ์คํธ๋ฆฌ๋ฐ ๋ค์ด๋ก๋๋ฅผ ์ง์ํ๋ฉฐ ์ ์ฒด ํ์ผ์ ์ ์กํ๋ ค๋ฉด ํ๋์ ์์ฒญ ๋ฉ์์ง ๋ง ํ์ํฉ๋๋ค.
๊ด์ฐ์ ์ค๋๋ ์์ฒญ ๋ฒํผ๋ฅผ ์ฌ์ฉํ๋ฏ๋ก ํ์ผ์ ์ ์กํ๋ ค๋ฉด 239 ๋ฐ์ดํธ ์๋ต์ ์์ฒญํด์ผํฉ๋๋ค.
์ด ๋ชจ๋๋ฅผ ๊ตฌํํ์ง ์๊ณ QGC ๋ง ์ฌ์ฉํฉ๋๋ค.
์ด ๋ชจ๋๋ฅผ ๊ตฌํํ์ง ์๊ณ QGC ๋ง ์ฌ์ฉํฉ๋๋ค.
MAVROS์์ FTP ๊ฐ๋ฅ์ฑ์ ์ ๊ณตํ๊ธฐ ๋๋ฌธ์ ์ด๊ฒ์ด ํ์ํ๋ค๊ณ ์๊ฐํฉ๋๋ค. ๋๋ ๊ทธ๊ฒ์ ์กฐ์ฌํ๊ณ ๋ด์ค (๋ฐ PR)๋ก ๋์๊ฐ ๊ฒ์ ๋๋ค.
@ TSC21 ์ USB๋ฅผ ํตํด์๋ง FTP๊ฐ ์์ ์ ์ด๋ฉฐ TELEMx๋ฅผ ํตํ mavros์ ์ฃผ์ ์ฌ์ฉ์๋ ํด๋น ๋ชจ๋๋ฅผ ๊ตฌํํ ์ด์ ๊ฐ ์์ผ๋ฉฐ ํ์ฌ ํจ์ฆ์ ๊ฐ์ ์ธํฐํ์ด์ค์ ํธํ๋์ง ์๊ธฐ ๋๋ฌธ์ ๋๋ค.
๊ทธ๋์:
์ํ๋ ๋๋ก
์ฌ์ฉ์ฑ ๋ฌธ์ ์ ๋๋ค. ํ์ผ ์ ์ก์ ์๊ฒฉ ๋ถ์์ ํตํด ์์ฒญ๋๊ฒ ๋๋ฆฌ๊ณ ์ ์ ํ ํฌ๊ธฐ (10-15MB)์ ๋ก๊ทธ๋ฅผ ๊ฐ์ ธ ์ค๋ ๊ฒ์ ์ต์ ํ ๋ ๊ตฌํ์ผ๋ก๋ ๋๋ฌด ์ค๋ ๊ฑธ๋ฆฝ๋๋ค.
ULog ์คํธ๋ฆฌ๋ฐ๊ณผ ๊ด๋ จํ์ฌ-์, ๊ฐ์ง๊ณ ์์ผ๋ฉด ์ข์ง๋ง mavlink-router
์ฌ์ฉํ ์ ์์ต๋๋ค. (https://github.com/01org/mavlink-router).
ULog ์คํธ๋ฆฌ๋ฐ๊ณผ ๊ด๋ จํ์ฌ-์, ๊ฐ์ง๊ณ ์์ผ๋ฉด ์ข์ง๋ง mavlink-router๋ฅผ ์ฌ์ฉํ ์ ์์ต๋๋ค. (https://github.com/01org/mavlink-router).
์ง์ค. ๊ทธ๋๋ MAVROS ๊ฐ๋ฐ์์ ์ ์ง ๊ด๋ฆฌ์๊ฐ ๋ชจ๋ ๊ธฐ๋ฅ์ ๊ฐ์ถ๊ธฐ๋ฅผ ๋ฐ๋ผ๋ ๊ฒ ๊ฐ์ต๋๋ค.
์ค์ ๋ก ์ต์ ๋๋ก ์ ๊ฒฝ์ฐ tty์ mavros ์ฌ์ด์ ๋ผ์ฐํฐ๋ฅผ ์ค์ ํฉ๋๋ค.
TELEM1์ RFD ๋ฐ TELEM2์ ์ํด ์ ์ ๋๊ธฐ ๋๋ฌธ์
๋๋ค. ๊ทธ๋์ FCU ๋ด๋ถ์ ๋ผ์ฐํฐ๊ฐ ํ์ํฉ๋๋ค.
๊ทธ๋ฆฌ๊ณ mavros๊ฐ GCS๋ฅผ ๋์ฒดํ๋ค๊ณ ์๊ฐํ์ง ์์ต๋๋ค. ๊ทธ๊ฒ์ ์์จ ์ ์ด ์ํํธ์จ์ด๋ฅผ ์์ฑํ๊ธฐ์ํ API ์ธํธ์
๋๋ค.
์ด์จ๋ ํ์จ์ด๋ฅผ ์กฐ์ ํ๋ ค๋ฉด GCS๊ฐ ํ์ํฉ๋๋ค.
๊ฐ์ฅ ์ ์ฉํ ๋๊ธ
@ TSC21 ์ USB๋ฅผ ํตํด์๋ง FTP๊ฐ ์์ ์ ์ด๋ฉฐ TELEMx๋ฅผ ํตํ mavros์ ์ฃผ์ ์ฌ์ฉ์๋ ํด๋น ๋ชจ๋๋ฅผ ๊ตฌํํ ์ด์ ๊ฐ ์์ผ๋ฉฐ ํ์ฌ ํจ์ฆ์ ๊ฐ์ ์ธํฐํ์ด์ค์ ํธํ๋์ง ์๊ธฐ ๋๋ฌธ์ ๋๋ค.
๊ทธ๋์: