Comments (15)
Just to make sure, what platform are you using? Is it APM or you changed the code to work with PX4?
What happens if you change RC channel values via MAVROS directly (i.e. rosservice call
)?
from redtail.
APM. What I see in QGC is the mode keeps switching between manual and unknown. I will try the rosservice call and let you know. Do you start up px4_controller the same way as for the iris? Unless I change the mode under the drone definition in px4_controller.h it tries to use offboard which won't work with APM. So do I need to specify its apm rover somewhere in the command line that starts it?
from redtail.
There is no mavros/rc/override that shows up with rosservice list -n. However if I run rqt its there.
from redtail.
px4_controller
currently supports 2 vehicle types: drone
and apmrover
via vehicle_type
argument. The default is drone
so it likely explains why you haven't seen any movements in your rover. Also, sorry for confusion re: the service - RC override plugin (rc_io
) is not a service, it is topic (I pasted the command from param
plugin which is a service). So the command line should look something like that:
rosrun px4_controller px4_controller_node _vehicle_type:=apmrover
with other necessary parameters.
Before running the controller, you can verify that everything else (MAVROS, connections etc) are working as expected. First, check what PWM is at servo outputs:
rostopic echo /mavros/rc/out
Move the stick(s) - the values should change.
Second, try controlling the motors with MAVROS:
rostopic pub /mavros/rc/override mavros_msgs/OverrideRCIn '{channels: [65535, 1300, 65535, 65535, 65535, 65535, 65535, 65535, 65535]}'
Note that you may need to set SYSID_MYGCS
parameter first to allow RC override from the code.
from redtail.
Thanks that part is working now but getting a fatal error in the takeoff part.
[FATAL] [1509649000.673626672]: ASSERTION FAILED
file = /home/nvidia/ws/src/px4_controller/src/px4_controller.cpp
line = 95
cond = is_initialized_
Joystick is hooked up and working via rostopic. FC is armed and in the right mode. This is how I'm starting it. rosrun px4_controller px4_controller_node _linear_speed=1 _obj_det_limit:=0.3 _vehicle_type:=apmrover
from redtail.
Looks like a merge issue. Can you please try alexeyk/rover
branch and see if it works?
from redtail.
Reflashed and installed the rover git. Same results. If I set the mode and disarm in QGC. Then run px4_controller I see it arm and change to the proper mode. However the tone from buzzer indicating its armed happens just after it throws that error. Wondering if its not waiting long enough and missing the message from mavros that its armed so initialized.
from redtail.
rostopic pub /mavros/rc/override mavros_msgs/OverrideRCIn '{channels: [65535, 1300, 65535, 65535, 65535, 65535, 65535, 65535, 65535]}'
ERROR: Field [channels] has incorrect number of elements: 9 != 8
from redtail.
Re: number of elements: remove the last number from the list.
Just to make sure, you are getting the same assert error message? You don't need to re-flash, just rebuild controller code from my branch. Something like this:
- SSH to Jetson.
cd ~/redtail
git pull
git checkout alexeyk/rover
cd ~/ws
catkin_make px4_controller px4_controller_node
from redtail.
Managed to get past that error by building mavros from source. I've seen this before trying to use ROS with APM. Still no motion of the wheels using dnn or rostopic. I'll have to look into that tomorrow.
from redtail.
Should I be seeing messages to /mavros/setpoint_position/local published? Also what version of apm firmware did you test with?
from redtail.
No, apmrover
mode uses simple RC override so it does not use/publish pose. First need to understand why /mavros/rc/override
is not working via rostopic pub
. Unfortunately, without access to the vehicle it's hard to tell what's going on but try looking at other RC topics like rc/in
and rc/out
.
As for the version - we use whatever APM comes pre-installed with Erle Brain 3 (2.6?)
Maybe this will help somehow...
from redtail.
I'm using 3.2 Don't think 2.6 will even run on a pixhawk 2.1. I see mavros/rc/override topic published with numbers. Rc out stays at 1500 for the two channels no matter what. If you move the rover around you see the dnn trying to correct in the output but nothing changes.
from redtail.
rosparam set /mavros/system_id 1 fixed it. Thanks for all the help. The mavros checkid script comes in very handy.
from redtail.
Not sure if this is still relevant but FYI anyway: I've just merged a few changes/samples which make the work with rovers a bit easier. We tested it with a couple of rovers and DNNs that we have here. Note that this is still RC-override based control.
I'm closing the issue now, feel free to re-open or create new one.
from redtail.
Related Issues (20)
- camera image not received for gscam kind camera in trailnet_debug_gscam.launch/trailnet_debug_zed_gscam.launch
- stereoDNN resnet18 test fails HOT 2
- gscam problem with no video shown, even not shown in rqt-image window, not even gst-launch on host machine HOT 1
- tx2 onboard connection with px4 flushed by apm not connected even with mavros HOT 11
- gscam donot stream on nano,but do stream on tx2
- lateral offset dataset
- Failed with error code 1 in /tmp/pip-build-U_9LbZ/numpy/
- Extended Redtail implementation for Arducopter HOT 7
- Training Resnet18_2D
- Error Loading TensorRT plan for ResNet-18_2D HOT 1
- Testing in Simulator
- Regarding tensorRT of TrailNet_SResNet-18 HOT 1
- Takeoff Mode Initiated Mid-air when starting px4_controller node in Navigate Mode HOT 2
- Unable to complete build_redtail_image.sh script HOT 3
- clarification on difference between visionworks and redtail? HOT 1
- Dataset used for training HOT 2
- The segmentation effect in your video HOT 1
- Jetpack 4.4 caffe_ros node Assertion failed HOT 3
- 2.4 GHz range cut due to Jetson RF noise HOT 6
- Could not find a configuration file for package "OpenCV"
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from redtail.