This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Getting started debugging
#11
(2019-07-30, 02:00 AM)rastam4n Wrote: Are you running tiny pilot or openplotter?
I am running openplotter  with the Moitessier hat and I have experienced some of the same, when it works it works great but the system often does not react to input, and the whole thing needs to be restarted, other times I need to log back into to Remote Desktop and restart Pypilot.
Other times it works great for hours on end...
I am going to try tinypilot, the fact that it runs entirely in ram is appealing to me and I suspect it’s more stable as it is a dedicated device which openplotter is not.

Hi, i´m running tinypilot latest image on a Zero w with an Arduino Clone, IBT-2 H Bridge as driver.
So hardware does not seem to be the first matter in this case...


Ahoy
Reply
#12
(2019-07-29, 10:29 PM)sideluxe Wrote: Sometimes it works like a charm as seen in the little video, but it is not stable. 

 - Sometimes the pilot starts to leave course and does nothing or much to less correction to go back to desired heading

You can increase the P or PR gains for this case, but increasing the D gain is needed to avoid overshooting the correction.

Quote: - Course keeping is not tight enough,  correction starts mainly after after ten deg off 
Increasing the gains will change this. Also decreasing servo.period to 0.3 or 0.2 can help. You also might try reducing servo.min_speed to less than 1.0 so it can move sooner at slower speeds.

You also might try running the autopilot at 25hz instead of 10hz which should improve reaction speed.

Quote: - The compass direction is not always correct, cali seems to be fine, but after setting the offset the course differs about 20 - 30 deg when moving to another direction. 
Only after setting the offset? Is the compass near anything magnetic ? 20-30 degree error is a lot. Normal calibration is within 10 degrees, usually better.

This can affect autopilot performance if the compass is not well calibrated. Can you run the pypilot_calibration script? pypilot/ui/autopilot_calibration.py It should fit the sphere to the points well, and it's easy to see if the calibration is good or not.

Also, maybe you need to calibrate the accelerometers.

Quote: - Making changes in the desired heading when the AP is engaged does nothing. No reaction at all, even if I change 50 deg port p or stb

This is handled by the FF (feed forward) gain. Is it non zero? Can you increase it?

Quote: - When engaging the AP does move the control arm about 5cm and does not compensate this back
Every time? Does it always move in the same direction? I have not heard of this, maybe the motor controller you are using somehow?
Quote:I tried to play with gains a lot, mainly D, P and DD , but a total satisfaction is not reached yet.

There are a few other gains as well, but I would try tuning other parameters.
Reply
#13
this helped me understand the gains settings.
https://pypilot.org/wiki/doku.php?id=tuning_gains
mare liberum
Reply
#14
Thanks Sean,


There is no magnetic source around the compass, only thing which could affect the imu might be the power cable, but heading is also incorrect when ap is not running without significant current flow.
The display cal/info tab says "good" by the way.
I will try to recalibrate the system and try your other suggestions when at sea the next time.
One thing before fiddling through all code, which file contains the Hz Setting?


Thanks Jim, i read it before and it indeed gave me some clues to adjust the gains, but togehter with Seans latetest comments it even makes more sense.

Ahoi!
Reply
#15
The hz should be changeable parameter as "imu.rate" you can change it from the client from 10 to 25.
Reply
#16
(2019-08-02, 04:52 PM)seandepagnier Wrote: The hz should be changeable parameter as "imu.rate" you can change it from the client from 10 to 25.

some news...

I Installed the latest version and did a recalibration, for now on my desk heading is correct in all directions after setting the offset to the in my case needed 92°
Display shows cal info excellent now.

Further i adjusted the gains on the desk, now that i have a better understanding how they work. after setting FF course change requests have an impact and the servo is moving.
I also dont have any "Saturated" messages from servo anymore  
Sea trial pending, but i looks prromising.

Thanks so far...Keep you updated
Reply
#17
Hi folks,

yesterday I finally was able to test the latest pypilot image after a long time to wait getting back on the water again.

After changing the motor polarity it worked very well l.
It steered for about 1.5h till I reached my port again.
Still trying to fiddle out the best gain settings, but for now
I am very satisfied with the latest setup.

Still. It would be very nice to have an upgrade process for the tiny pilot image, to have all the changes since December online.

Perhabs I have some time to spare within my holiday next month to understand how Tc and pypilot install scripts work.

Any hints would be nice, Sean. Hopefully I can support a little bit with the upgrade procedure...

Best Christian
Reply
#18
I've updated the pypilot within TinyPilot image with this script in the past. I don't know if it still works this way but it might be worth a try. See this link.

https://forum.openmarine.net/showthread....4#pid10734
Reply
#19
There are a lot of changes to pypilot now but they are in an experimental branch... You should probably stick with december code for now for reliability. I hope to have a beta image soon, but it won't be considered stable for some time.
Reply
#20
(2020-06-22, 03:24 PM)ironman Wrote: I've updated the pypilot within TinyPilot image with this script in the past. I don't know if it still works this way but it might be worth a try. See this link.

https://forum.openmarine.net/showthread....4#pid10734

Hi, 

thanks for sharing. 
This way dies not work anymore, because of some major changes within pypilot code.

Cheers

Christian

(2020-06-24, 03:09 PM)seandepagnier Wrote: There are a lot of changes to pypilot now but they are in an experimental branch...   You should probably stick with december code for now for reliability.   I hope to have a beta image soon, but it won't be considered stable for some time.

Hi Sean, 

i will stick on it. 
Reading the forum threre were some nice code changes after december.

In the meantime it would be nice to tune die wiki a little bit, to make it easier doing a nice calibration on pypilot.

you already explained sone of the gains inside wiki but i think having all in one place would be nice

lets start here, ill put ist to a new topic then 

Servo Parameters:

servo-max_slew_slow - 

servo.max_slew_speed - 

servo.gain - 

servo.speed.max -  

servo.speed.min - 

servo.speed.gain - 

servo.period -
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)