Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[mavros_extras] Using image bridge when UDP link to GCS already active #103

Closed
TSC21 opened this issue Aug 11, 2014 · 19 comments
Closed

[mavros_extras] Using image bridge when UDP link to GCS already active #103

TSC21 opened this issue Aug 11, 2014 · 19 comments

Comments

@TSC21
Copy link
Member

TSC21 commented Aug 11, 2014

(suggested by @mhkabir)

If I have a proxy link from mavros to QGC using UDP (sending data from PX4), is it possible to send image data using the same link?

Also, please can you add launch files for image_bridge.

@vooon
Copy link
Member

vooon commented Aug 11, 2014

Please add chain what you want (don't understand what node provide UDP bridge).

@TSC21
Copy link
Member Author

TSC21 commented Aug 11, 2014

This is a @mhkabir issue so it's probably better that he answers. Don't know if I'll be using this plugin either (can use it to px4flow or to any other camera though).

@vooon
Copy link
Member

vooon commented Aug 11, 2014

Oh, i forgot add @mhkabir first :).

@mhkabir
Copy link
Member

mhkabir commented Aug 14, 2014

Sorry, I must have overlooked this.

Basically, say we have UDP link to GCS active , streaming data from connected PX4. Can, we stream video using the same link to GCS, instead of separate link?

@vooon
Copy link
Member

vooon commented Aug 14, 2014

UDP link opened by mavros or external node (gcs_bridge)?

If by mavros - not, you must disable internal bridge by setting _gcs_url:='' and use gcs_image_bridge for GCS link.

E.g.

roslaunch mavros px4.launch fcu_url:='...' gcs_url:=''
rosrun mavros_extras gcs_image_bridge _gcs_url:='...'

@mhkabir
Copy link
Member

mhkabir commented Aug 14, 2014

I mean opened by mavros. It would be good if we could use same link for
image and mavlink stream (IMU,position, etc.) to GCS.

:(

On Thu, Aug 14, 2014 at 5:34 PM, Vladimir Ermakov notifications@github.com
wrote:

UDP link opened by mavros or external node (gcs_bridge)?

If by mavros - not, you must disable internal bridge by setting
_gcs_url:='' and use gcs_image_bridge for GCS link.

E.g.

roslaunch mavros px4.launch fcu_url:='...' gcs_url:=''
rosrun mavros_extras gcs_image_bridge _gcs_url:='...'


Reply to this email directly or view it on GitHub
#103 (comment).

@vooon
Copy link
Member

vooon commented Aug 14, 2014

But gcs_bridge provide all streams from mavros (IMU, position etc.).

It works similar way as internal, except it adds communication via ros topics to/from.

@mhkabir
Copy link
Member

mhkabir commented Aug 14, 2014

So how do we stream all data from mavros + images to same GCS?

Example please :)

On Thu, Aug 14, 2014 at 6:03 PM, Vladimir Ermakov notifications@github.com
wrote:

But gcs_bridge provide all streams from mavros (IMU, position etc.).


Reply to this email directly or view it on GitHub
#103 (comment).

@vooon
Copy link
Member

vooon commented Aug 14, 2014

I write launch for that.

vooon added a commit that referenced this issue Aug 14, 2014
vooon added a commit that referenced this issue Aug 14, 2014
* master:
  launch: APM2 blacklist mocap plugin.
  Updated mavros_plugins.xml
  Fixed dual sources error warning.
  Fixed styles.
  Minor changes.
  added time stamp to received msgs
  Removed un-needed times.
  Added mocap_pose_estimate plugin.
  Code style update
  setpoint attitude change - warning message
  Update on setpoint_attitude plugin
  Add gedit backup to ignore.
  launch: Add example launch for #103.
@mhkabir
Copy link
Member

mhkabir commented Aug 27, 2014

Working fine now. Some issues with freezing, and I think this is on mavros side. I'll see what I can do.

@vooon I need to know ASAP, how do I set the pose_with_covariance parameter to true from a launchfile? I have tried many combinations, but for some silly reason, it refuses to set.
Please let me know roslaunch syntax for this :)

@vooon
Copy link
Member

vooon commented Aug 27, 2014

Add to <node>:

<param name="position/vision/pose_with_covariance" value="true" />

@mhkabir
Copy link
Member

mhkabir commented Aug 27, 2014

@vooon Not working :(

rosparam list gives this :

/gcs_image_bridge/gcs_url
/gcs_image_bridge/position/vision/pose_with_covariance
/mavros/conn_heartbeat
/mavros/conn_timeout
/mavros/fcu_url
/mavros/gcs_url
/mavros/plugin_blacklist
/mavros/startup_px4_usb_quirk
/mavros/target_component_id
/mavros/target_system_id

Node has this :

    <node pkg="mavros_extras" type="gcs_image_bridge" name="gcs_image_bridge" clear_params="true" output="screen">
        <remap from="/mavlink/gcs_image" to="/svo/image" />
        <param name="gcs_url" value="$(arg gcs_url)" />
        <param name="position/vision/pose_with_covariance" value="true" />
    </node>

@TSC21
Copy link
Member Author

TSC21 commented Aug 27, 2014

<param name="position/vision/pose_with_covariance" value="true" /> it's a parameter from mavros and not mavros_extras.
So try: <param name="mavros/position/vision/pose_with_covariance" value="true" />
or add this parameter to mavros_node instead:

<node pkg="mavros" type="mavros_node" name="mavros" required="true" clear_params="true" output="screen">
    ....
    ....
    ....
    <param name="position/vision/pose_with_covariance" value="true" />
    ....
</node>

@vooon
Copy link
Member

vooon commented Aug 27, 2014

@TSC21 right!

Note: you can use rosparam get / to view all parameters with it's values.

@mhkabir
Copy link
Member

mhkabir commented Aug 27, 2014

Cool thanks guys :D Working now :D

@mhkabir
Copy link
Member

mhkabir commented Aug 28, 2014

@vooon The image sending system still has some problems, as I can see. Sometimes, QGC freezes up with the stream. Any idea why. There are debug messages in QGC relating to JPEG errors, can you please check up on this a bit?

Kabir

@vooon
Copy link
Member

vooon commented Aug 28, 2014

As i mentioned before QGC sometimes drop images (with errors in terminal).

I don't know why, and think bug in QGC, because my image_pub plugin works fine.

You can construct this chain:

image node -ros-> gcs_image_bridge -udp-> mavros -ros-> rqt_image_view
                                                 -udp-> QGC

Or can you check px4flow camera launch?

roslaunch mavros_extras px4flow.launch gcs_url:=udp://@localhost
rqt_image_view

Then connect QGC to UDP and check video stream in both QGC and RQT.

@vooon
Copy link
Member

vooon commented Dec 30, 2014

I think we can close this issue?

@mhkabir
Copy link
Member

mhkabir commented Dec 31, 2014

Yep.

@mhkabir mhkabir closed this as completed Dec 31, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants