Beta v2 image with ROS support for Navio boards

Did you try waiting a bit? Or it just hangs and outputs nothing? I noticed it’d taken some time to pick up topics from ROS (might even take a minute or more).

I will try again but if echo takes that long how can it be useful. Do you have any examples of ROS nodes running on the navio2 ?

Thanks! May I mention that you guys should check out this thread while implementing, I’m sure you guys know about it but doesn’t hurt to make sure.

It seems they have included several patches for mavlink, joystick, and I believe they were working on patches to allow you to change the power output and bitrate of the wireless card.

Thanks!

Has anyone got the mavros topics to work ? Any simple ROS node to test ? Is is possible to send the mavros topis via ROSserial to host computer running ROS ? Excited about getting the ROS topics in navio2 beta but so far no success in getting anything useful.

@vinorobo
You can try the following command before launch rostopic:
rosservice call /mavros/set_stream_rate 0 10 1
It sends stream rate request to FCU.

No. Did not help. Exactly as before. I verify that ardupilot is running. GCS is getting data. roscore running. rosrn command in another terminal running - got [INFO] lines all seem to be good. Can get rostopic list in another tmux window but then rostopic echo just hangs until crtl-C

I do not think the ros node works correctly. As a workaround I am going to mavlink the ethernet port to a companion computer and run mavros there. Then do all the ROS work in the companion and send commands back over mavlink to the navio2. Should work ?

This topic seems to have died. No responses. What gives - does the ROS node in navio2 betav2 work ? Anybody ?

I’m extremely sorry I haven’t answered! Could you please share your /etc/default/ardupilot and /lib/systemd/system/ardupilot.service and could you please try connecting to Autopilot using UDP rather than using just a radio link?

I have not been succesful in getting the ardupilot services to work on boot so I use the old method of putting the command line in etc/rc.local. I also find TCP works better with MP for me. I use in rc.local:

sudo /home/pi/APMrover2.elf -A tcp:/0.0.0.0:5678 -C /dev/ttyUSB0 -E /dev/ttyAMA0 &

I have an external GPS in the uart. This works ok. I have never been able send telemetry out the D port so I gave up on that. Perhaps a new image will fix it as per some of the forum conversations. I feel the RP3 cannot handle much ROS but it would be nice to have it run as a node and use ROSserial to connect to a more power ROS companion. Your competition (E) can sort of do this but overall their product is very poor and support even poorer and snobbish. So I have thrown it out.

This is exactly the reason it might not work. Please, try the newer method. We have published the new docs.

This is also fixed and will be updated in the new beta. Sorry for that.

I suggest walking you through every step to launch ardupilot with systemd. This way we can make it as easy as possible for all of users.

As a first step I reckon you might wanna try follow the steps the are shown on SSH login.

OK.I managed to set up the systemd method, It boots but I get message:

Traceback (most recent call last):
File “/opt/ros/indigo/_setup_util.py”, line 282, in
sys.stdout.flush()
IOError: [Errno 28] No space left on device
Failed to run '"/opt/ros/indigo/_setup_util.py" ': return code 1
pi@navio:~ $

When I try tmux new -s ros I get error - no space left on device

So I think I need to reflash a new image and start again. I am away for the next 2 weeks so I will try again when I get back. Do you think the new beta will be available then.

This is not an issue of our image per se. You need to use raspi-config to expand partition. I suggest using an SD card that is more than 4Gb.

So, the procedure is as follows:

  1. sudo raspi-config
  2. Select Expand filesystem
  3. Reboot

Just installed latest Beta on Navio2 w/ Rpi3. Used Beta docs. Only issue I have found is Compass #1 and Compass #3 were enabled by default in latest MP compass setup screen. I unchecked #3 and checked to use #2. Also set #2 as default. Calibration went OK for both #1 and #2 compass. No complaints in MP about high offsets. Heading seems reasonable. Just hover checks so far so not enough flight data to say much more.

It’s kind of intended. We decided to turn off AK8963 by default.

If you don’t have an external compass, this tick doesn’t really change anything at all.

Anyways, thanks for the feedback. Eager to hear more.

Thanks. Suggest making the beta docs more clear. I know the compass setup and cal creates a bunch of posts on this forum. The docs start talking about second compass configuration but then you switch to IMU/MPU part numbers.

Suggested info to include…

Navio2 contains two 9DOF IMU - MPU9250 and LSM9DS1. MPU9250 uses an AK8963 compass which can indicate high offsets after calibration. It is disabled by default. It can be enabled by selecting Compass#???

I thought the AK8963 was Compass#2?

Also, picture still shows both compasses being used.

Just trying to help get this sorted once and for all.

Thanks!

You’re being very helpful. Thanks again. We’re on it!

OK. Finally got back to working on the navio 2 and ROS.

  1. I fixed the partition and now I do not get any error on boot. 32GB SD. Thanks.
  2. APM boots up with systemd. Good.
  3. Tried your beta doc procedure. tmux works fine.
  4. Started roscore in one window. No problem.
  5. Started mavros exactly as specfied in your docs in second window. No errors.
  6. Started rosservice in 3rd window as per docs. No errors. Got prompt back.
  7. In 4th window ran rostopics list - got list of mavros topics
  8. Now just as before no good - Tried:

pi@navio:~ $ rostopic info /mavros/state
Type: mavros_msgs/State

Publishers:

Subscribers: None

pi@navio:~ $ rostopic hz /mavros/state
subscribed to [/mavros/state]

… Ok to topic exists but no update rate ? If I try echo rostopic /mavros/state I get get just one update then nothing

Next I tried to look at the imu data …

^Cpi@navio:~ $ rostopic info /mavros/imu/data
Type: sensor_msgs/Imu

Publishers:

Subscribers: None

pi@navio:~ $ rostopic hz /mavros/imu/data
subscribed to [/mavros/imu/data]
… just hangs here until ctrl-C

What do you think is going on ? We seem to get real close to getting this to work but no updates ! I could write a ROS node to listen to the mavros mode but the echo and hz should work,

Could you please elaborate on this step. please? How did you make it work?

Did you connect to a GCS? Or called rosservice call?

No real progress.I used rosservice call.
I can get ROS topics from your competitors product. So I do not not think it is an issue on my side. I have decided that having ROS running on the navio2 (or similar RP3) is not really of much use. It makes more sense to use mavlink and then mavros on the companion computer to run ROS. This works good.So as far as I am concerned you can consider this thread closed.