RCU Forums - View Single Post - MonoBot: Aerial Robotics Project
View Single Post
Old 11-15-2016, 04:46 PM
  #17  
UN.RCONT.OL
 
UN.RCONT.OL's Avatar
 
Join Date: Feb 2014
Posts: 415
Likes: 0
Received 4 Likes on 4 Posts
Default

I tweaked the code to overcome the PWM anomaly that caused the servo jitter. The anomaly was causing the throttle to really bounce around and I wasn’t going to be able to fly it that way.

In the current state, the code is performing two separate reads on each channel and comparing those two readings to each other. If one reading is more than X different than the previous reading, then it is allowing it to move up or down only as much as X. And it is performing the reading Y times a second.

X and Y are the variables. In the current state of the variables, the response to stick input has slowed down significantly but I believe I will be able to fix that with playing with the values of X and Y.

This video is the first attempt to see the throttle response to the new code and the sensors. It was encouraging. You can see throttle adjust with input from top and bottom sensors.

https://www.youtube.com/watch?v=CPxF...c&spfreload=10

https://www.youtube.com/watch?v=CPxF4UFmEhc&spfreload=10