Knowledgebase Contact Us
How Can We Help?
< Knowledgebase

Driving the Porter by Raspberry Pi

Our Porter range can be used as an interface between a Raspberry Pi or Arduino and a motor.

The Pi can provide a PWM output via its GPIO pins and this can be fed into the input of the Porter. However the Pi has a 0 – 3.3V output and the Porter needs a 0-4V input so to be able to achieve full power so we need to do a little jiggery pokery to shift the levels a bit. We also need to add some capacitance to the input to average out the PWM from the Pi.

A configuration that we have used is here:

We haven’t finalised the values yet but it shows the general idea.

We have tested the Porter satisfactorily between 10Hz and 10kHz.

There are many programs / scripts available that give control of the frequency and duty cycle of the PWM output from the Pi. We have written a sample program in Python which you can download.

Note: One customer found that when using an Arduino, setting the output pin to an analogue zero was not sufficient to completely stop the output from the Porter, this is due to the Atmel processor on the Arduino not being able to give a true zero PWM output. The solution was to use “digital write – low” to completely turn off the output pin.

We’ll be testing our other controllers and putting details of those in the knowledge base as soon as we can.