Finally made some progress on the project, after a frustrating period of not being able to work on it. I also now have access to a large testing lake.
I installed the same basic hardware as had been debugged on the electric boat. The important sensor on a yacht is the wind direction sensor. I had made an analogue wind vane using an AS5600 magnetic rotary encoder. I was using OpenPilot revolution flight controller and to add the wind vane, I had to further customise the hardware dat file for the Ardupilot Chibios HAL . Since there are only 2 rc channels on the boat, I found it convenient to use one of the RC servo output pins as an analog input. This also provided 5v and ground on the Servo pins. I use a BEC which provides around 5.5V . I used a MIC5205 LDO voltage regulator to get a stable 5V from the raw 5.5V input.
I provided an Ac termination for the analog voltage both ends to give a dynamic impedance of 100 ohms looking in to the sensor and the flight controller input, to counter effects of rf noise.
TODO Provide the circuit for the AS5600 sensor.
The customised Ardupilot firmware loaned and found the wind vane without issues. The details of setting up Ardupilot sailboat can be found on the Ardupilot website, so I wo'nt repeat them here.
I managed to get a video of the boat on a mission. As you can see ( though tis wasnt the first run), it worked well right out of the box.
The main issue currently is that the boat isnt totally waterproof. I found some water in the boat after a couple of hours sailing. I don't know if this is coming in through one of the holes in the deck or through a hole somewhere below the waterline.
One thing that has worked well is the balanced Rig. This allows use of a normal servo( though I used a powerfull servo) which sheets the sail in and out much faster than a winch and so tracks a varying wind much better. I plan now to have a go at tuning the PID controller that controls sheeting out the sail as the boat heels to try to make the action somewhat smoother. I suspect I may be able to raise the D term due to the repsonsivness of the sail servo.
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.
Just started on an ardupilot sailboat project and trying to use AS5600 encoder with a windvane. I'm not clear how to get what ArduPilot calls analog out of the AS5600. Based on your notes and also what I read about ArduRover wheel encoders, once I have serial output and can input via a PWM connection on my FC (Matek H743-SLIM). I'm wondering if I need the AS5600L?
Are you sure? yes | no