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
Solenoid mode for engine driven hydraulic pump
#1
I am trying to install pypilot on a 49'' wooden troller. It will replace Onwa autopilot (kap-866) that has solenoid mode.

I made an hydraulic power steering working with an hydraulic pump that is engine driven.
The auto pilot command a directional cetop valve (with 2 solenoids). In parallel.
The current (about 2 amps) and tension (12v) to the valve solenoid is irrelevant.
The valve is not proportional and sending PMW is not a good idea as it can support only 3 or 4 Hz  cycles.
I use (solid state) relays for the solenoid so I don't need a motor driver.
There is a rudder feedback.
Temperature sensor is for oil tank temperature
.
Anyone with similar setup?
This type of system is common on workboats.
Any tough on how to disable current reading and go from PWM to a binary on/off starboard/port command?
Is there a way to limit the number of valve opening/closing per second?
I have very limited programmation skills (sysadmin using VBS) and I don't understand the code in motor.ino
Should I make a feature request?


Thanks in advance for your advices
Reply
#2
by default the setting of the pypilot motor controller has both min and max speed set to 100% which means it will only be either on or off. Most lead screws have a lot of friction and therefore are very inefficient at partial speeds so it's better to make small corrections at full speed anyway. People with more efficient drives like ball screws can use variable speeds efficiently, or if they want to reduce noise at the expense of power consumption.

The thing you will have to look for are the slew speed settings which ramp up and down the power even with min speed set to 100% to greatly reduce current spikes. Maybe you just want to set them to the maximum value, or at least increase them.


If you can drive your solidstate relays from an arduino pin (40mA max, recommend only 20mA) then you could use an arduino and drive it that way. Otherwise, the regular controller could either drive the relays or just the solenoids direct, probably I would not use the solid state relays in this case because they aren't needed.

To drive a solenoid typically the voltage needed to hold it on would be less than to turn it on, so special code could be added to make it reduce power consumption for this case... but certainly not a priority for me to implement at this time.


I realize motor.ino is not the most readable, but the function is important. A few have modified it to make it more readable but it changed the functionality for the worse so I have not adopted the changes.


As for disabling current... you could just ground the current sense pin, or if you have the regular controller just set a high max current that will not normally trigger (unless the wiring to the solenoid gets shorted or something)

It would be interesting to hear the results, you may need to tweak other pypilot settings and use different gains to get the best performance. Is there a particular reason for a continuous pump rather than a reversible one? Just because it's already installed? It's pretty clear that reversible pumps are significantly more energy efficient...
Reply
#3
H Sean,
Thank you for your answer.
for now I have it working (not yet installed) with a more readable motor. Ino from a fork.
I have played with the slew and min max and I drive regular relays correctly (unfortunately the relay  board is pull down so I will need to tweak it).
I started to play around with a raspberry 1 revb and arduino uno that I had aboard but moved to rapbpi zero and a nano clone that has solved some problems
I have a troller without mast and huge rudder.
So engine is always on when cruising. Before I added compensation o the rudder the force was huge so I designed the hydraulic accordingly and went for a "power steering", same type of valve than clark elevator.
This allow very easy maneuvering with a small wheel and fewer turns (great for the admirall
I added solenoid as it is simpler and reliable than a wheel motor for autopilot
The Isuzu engine has a embedded gear port for hydraulic pump so it is neat and reliable.
As the engine is always running I am not too anal about energy (also have 800w of solar).
Will update after I have some miles under the keel with pypilot.
BTW to solve the alternator problem charging lithium I did use a specialized chip TLE8881-2 that is cheap and has quite a lot of fearure. It use Lin communication.  There was an arduino project (vsr regulator) but the developer went commercial and it is no noore maintained.
I tough the future is on alternators with communication port. So far I did not manage to communicate with it but the default settings give good result.  So if one day you struggle with alternator battery charging you can remember there is cheap and elegant solution and an alternator control/display via Lin could be a good feature in openplotter even if it is not really navigation.
https://www.infineon.com/cms/en/product/...e8881-2tn/

Hi Sean,
Thank you for your answer.
for now I have it working (not yet installed) with a more readable motor. Ino from a fork.
I have played with the slew and min max and I drive regular relays correctly (unfortunately the relay  board is pull down so I will need to tweak it).
I also started to play with a raspberry 1 revb and arduino uno that I had aboard but moved to rapbpi zero and a nano clone
I have a troller without mast and huge rudder.
So engine is always on when cruising. Before I added compensation o the rudder the force was huge so I designed the hydraulic accordingly and went for a "power steering", same type of valve than clark elevator.
This allow very easy maneuvering with a small wheel and fewer turns (great for the admirall
I added solenoid as it is simpler and reliable than a wheel motor for autopilot
The Isuzu engine has a embedded gear port for hydraulic pump so it is neat and reliable.
As the engine is always running I am not too anal about energy (also have 800w of solar).
BTW to solve the alternator problem charging lithium I did use a specialized chip TLE8881-2 that is cheap and has quite a lot of fearure. It use Lin communication.  There was an arduino project (vsr regulator) but the developer went commercial and it is no noore maintained.
I tough the future is on alternators with communication port. So far I did not manage to communicate with it but the default settings give good result.  So if one day you struggle with alternator battery charging you can remember there is cheap and elegant solution and an alternator control/display via Lin could be a good feature in openplotter even if it is not really navigation.
https://www.infineon.com/cms/en/product/...e8881-2tn/
Reply
#4
which fork of motor.ino?

The one from mcnugget although I applaud forks and experiments, this version added floating point computations (to simplify the code) but this is actually just not needed at all and this significantly degrades the performance of the motor controller. So I would be aware of this. This and a few other changes I do not agree with is why I cannot merge this code.

I'm not saying it won't work, and I have not tried it, but I suggest that the readings such as current, voltage etc, will be measurably less precise and the response time may also be worse. It's also possible maybe it resets if the watchdog triggers (unlikely) but if this is true, it would significantly degrade autopilot performance and you might just think pypilot is not as good as it really should be.

I am not really able to test/verify such forks but I don't recommend using floating point on the motor controller just to simplify a dozen lines of code or so, and I vaguely recall a few other changes which were not good either.

I am unsure of the other changes if they are stable or not. probably fine, but who knows: use at your own risk.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)