OpenMarine

Full Version: PyPilot with Raspberry Pi Motor Controller
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello, I managed to get PyPilot running from my Raspberry alone without the need for an arduino, there are still some features missing of course, but I plan on adding them later, to make it a fully compatible replacement for the arduino driver.

I would like to commit the changes to the pypilot github repository, but there are some things I had to alter to make it work within pypilot, since it is currently hardcoded for the arduino.

For Sean:
What do you think would be the best procedure, if you're at all willing to merge the changes into pypilot, since from what I read you're against using the raspberry as the driver for the motor controller.

I was thinking about implementing a settings file option for configured which driver the user would like to use in the ~/.pypilot home directory. Or would you rather it was a commandline argument (which the program has none of atm.)

Let me hear your thoughts about this :-)
Could you elaborate on how you managed to get the motor controller to work without an arduino? The raspberry has no adc to detect if the motor stalls.

I suggest:

1) you have eeprom on i2c which defines the motor controller and which gpio pins it uses.
2) you have a config file which is the same as #1 but doesn't require eeprom
Why you are against using raspberry for control of motor controller?
I preparing to make autopilot with pypilot (already have RP4 and Moitessier Hat) next winter, and any information is welcome.
Only difference is that I will use hidraulic pump & controller for this... ( https://pypilot.org/store/index.php?rt=p...uct_id=131 )
The reasons I'm against using the raspberry for a motor controller:

1) difficulty generating pwm signals from raspberry
2) no adc for measuring stall voltage and other inputs needed
3) less flexible in reusing different hardware components.
4) limited pins on raspberry already used for display, keypad, other sensors..
5) prevent damage to raspberry pi from motor controller problems
6) allow locating motor controller in a different location from sensors and raspberry. If currents in the motor controller are high enough it can throw compass sensor and software doesn't compensate this yet.

A micro controller to run the motor controller is only a few added components.
So, you would like to say that:

NOT USE: raspberry with moitessier hat - hydraulic pump controller - hydraulic pump

TO USE: raspberry with moitessier hat - tiny pilot computer - hydraulic pump controller - hydraulic pump

Is that correct or I miss something?
all of the controllers I am building have a an arduino so can be used with moitessier hat or tinypilot.

I believe the OP is suggesting driving the motor controller directly using the raspberry pi.