I have configured the gripper functionality using a servo motor and have been able to both release and grab with it successfully. However, there are two strange issues I have come across (that may be related):
Whenever the flight controller is restarted or first powering on, the gripper releases. It does so on its own, with no radio connected and the copter in a disarmed state. I would prefer not to have to reattach and re-grab the package if I attach it before powering on the controller or if I have to restart for whatever reason.
The flight controller sometimes restarts when the gripper enters the “grabbed” state. First, I noticed that the servo motor pin does not push far enough to completely and securely lock the package when grabbed, with GRIP_GRAB set to 800 (the listed PWM minimum). So, I tried lowering it to 600 and this indeed made it grab more securely but with the added effect of suddenly restarting the flight controller!
I am wondering if I am missing something in configuration or if this is a known issue perhaps caused by the flight controller I/O hardware, and if there is any workaround.
Flight controller: mRo Pixracer Pro
1): If I’m not mistaken all output channels are set to high state when FC is powered on. - More info about this in the docs.
2) Sounds to me the servo is using to much current which causes a drop of voltage forcing a FC reboot. → need to have only the signal wire connected to the FC. Power the servo directly from a BEC. If you are doing this already then it may not be powerful enough or you may have to add a capacitor in the powerline of the servo in order to deal with the sudden increase of current.
I moved the servo signal wire to a different PWM output on the flight controller and it seems to have resolved the first issue. Perhaps it was crosswired somehow to one of the motor outputs, so it was receiving signal from those on startup. Not sure. Otherwise, if all the output channels are set to high state when the FC is powered on, I guess I will just have to deal with it if the problem recurs.
The second problem was indeed the servo drawing too much current. It is now powered with a separate BEC and behaves normally.
Must have been entirely a power board issue (not able to supply enough current when the servo needed it). I am now using a different power board that is able to supply and have no issue.
The servo now behaves as it should and the correct parameters have actually changed to be much higher:
Setting the servo_trim and grip_neutral appears to have properly caused the servo to close or remain closed on startup.