stackable I2C motor shields/brushed DC servo driver

Do you have an idea for a device that you think Freetronics should create? Discuss your ideas here! Sometimes we may even give you a sneak peek at secret projects we have in the pipeline, or ask for feedback on designs before they go into production.
Post Reply
effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

stackable I2C motor shields/brushed DC servo driver

Post by effgee » Sun Nov 11, 2012 12:39 pm

kind of like this one:
http://blog.notdot.net/2011/08/Building ... or-Arduino

but preferably with a higher spec micro and H-bridge.

Done right, it could act as a standalone arduino, and simply stack more on to drive more motors. Or if you need more IO or comms, stack them on another arduino or Mega.

csconsulting
Posts: 71
Joined: Fri Sep 21, 2012 7:22 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by csconsulting » Sun Nov 11, 2012 2:56 pm

There is already some motor shield product on the way, jaycar will have them in fairly soon.

effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by effgee » Sun Nov 11, 2012 9:20 pm

csconsulting wrote:There is already some motor shield product on the way, jaycar will have them in fairly soon.
Any specs ? Apart from http://www.pololu.com/catalog/product/2502, all the 'me too' motor shields don't suit me because they only drive lame-sized motors, and are 'pin hogs', i.e they use up too much IO so you can't run any other shields (which the Pololu one also does).

I suspect I'm going to have to develop this myself, to suit my own needs, but no harm in asking to see if someone else wants to do it for a wider market.

csconsulting
Posts: 71
Joined: Fri Sep 21, 2012 7:22 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by csconsulting » Mon Nov 12, 2012 12:31 am

Ah yea, i get what you mean, you want a kind of I2C set and forget controller.
Stackable like the freetronic RGB modules, or the temperature modules.

effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by effgee » Mon Nov 12, 2012 12:58 pm

csconsulting wrote: Stackable like the freetronic RGB modules
More specifically, I want them physically stackable, with side-access motor, power, encoder & limit switch connectors. So I can run 3 or 4 decent sized motors from the one physical controller, instead of having a nightmare of fasteners, connectors, enclosures.
csconsulting wrote: I2C set and forget controller
Yes! so you don't run out of interrupts or time to process them, or at least you can get the functionality without lots of effort/compromise profiling code.

Open source code already exists https://github.com/makerbot/DC-Servo-Controller, but I can't find any existing product that has the arduino format and stacks without pin-hogging. Not sure if I2C or SPI is the way to go, either would work fine I assume.

There is http://wiki.makerbot.com/dc1 (non arduino foot print) and http://www.robotpower.com/products/MegaMoto_info.html (pin hog, max 3 motors). I'm currently using the Pololu shield, but it doesn't leave enough IO for the rest of the job, and doesn't 'play nice' with the (Ether)Mega.

I acknowledge there are risks due to noise issues with stacked motor drivers, especially if trying to read high speed encoder pulses, but my requirements aren't that high, and presumably any design could be refined to address noise and thermal issues (within limits).

csconsulting
Posts: 71
Joined: Fri Sep 21, 2012 7:22 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by csconsulting » Mon Nov 12, 2012 1:13 pm

Like you mentioned your most serious problem is noise. Electric motors, especially brushed ones, can cause serious noise in circuits. The other problem is random currents floating around your earth and power.

I do know what you mean though, be able to physically stack them, and address them by specific addresses, and then set and forget, perhaps with an ISR servicing feedback control, or errors/overcurrent etc.

I would imagine if you designed such a shield, it would be fairly popular.

The question is though, which would be more popular, brushed DC with feedback or stepper motor control.

I think the issue with servo feedback is that you actually need something smart to recieve the feedback signal and use it to help control the motor.

effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by effgee » Tue Nov 13, 2012 3:01 am

csconsulting wrote:The other problem is random currents floating around your earth and power.
The idea is to supply motor power (typically 24V, maybe higher) completely separate from the micro power, with jumper selection of the 5V rail to come from either the onboard switchmode voltage regulator or the 5V pin on the arduino header (just like on the ethermega).
csconsulting wrote: The question is though, which would be more popular, brushed DC with feedback or stepper motor control.
For pure grunt, brushed DC is the only practical option right now. Mind you, I've already thought a stepper version would be great too, but one thing at a time. My experiences with the current range small stepper drives have been kind disappointing. They appear to be optimised for minimum size instead of maximum thermal performance, are quirky with low-impedence steppers (thanks to Allegro's fixed off-time pwm), and 2A is about their limit on paper, more like 1A in practice. This low current, plus the dramatic torque dropoff beyond 300-600rpm, means you can only get very limited power from a stepper.

All the bigger stepper drives (i.e. Gecko, Leadshine) use discrete FETS, and I understand there's a lot more engineering gone into making them work well. There is no available high-current, single-chip stepper equivalent of a big H-bridge, more smarts are needed for current limiting, and from what little I've read its far from trivial.

Considering other options, BLDC (brushless) motor drive shield would be a great idea too. I searched and could only find one shield that would drive a BLDC motor http://scolton.blogspot.com.au/2010/06/ ... d-v20.html. But I couldn't source any BLDC (gear)motors suitable for my application, so a drive to suit is 3rd priority for me right now (even though higher efficiency and lower noise is appealing, the higher complexity, higher cost and lower availability is a bigger disincentive. Not to mention a question mark over their stalled torque characteristic).
csconsulting wrote: I think the issue with servo feedback is that you actually need something smart to recieve the feedback signal and use it to help control the motor.
That's what this board would address - dedicated inputs for quadrature encoder, software option to use analog feedback instead (yes, I know 10bits is dicey, but I'm currently getting decent results with massive oversampling), or even a serial protocol encoder i.e. SPI, SSI or SEI, or graycode (depending how much IO is available on the chosen micro).

No apologies for the long post - its a bit of a "what I wish I'd known about DC motors 12 months ago" - hope it helps others.

effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by effgee » Wed Nov 14, 2012 1:07 pm

csconsulting wrote: brushed DC with feedback or stepper motor control.
Stumbled across this dual-full bridge chip from Ti, which could do both
http://www.ti.com/lit/ds/symlink/drv8412.pdf
since it includes current limiting.

3A & 7A versions, up to 52V supply. Looks promising.

LukeW
Posts: 91
Joined: Tue Nov 01, 2011 10:14 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by LukeW » Thu May 23, 2013 3:43 pm

This is immature, incomplete and untested, but you might find it of interest.
It's a work in progress.

https://github.com/lukeweston/OpenServoDrive

Depending on the voltage and current your motor is running at, it's probably entirely unrealistic to get something that fits into an "Arduino Shield" form factor.

You might have a series of boards each driving one motor, with a microcontroller on board each board, and network them together via a "stackable" multi-drop digital bus such as CAN or RS-485 wired between each board, along with the power supply.

(My above example has two motors on a single board, but it could just as easily be one.)

For precise servo control of a brushed motor, I think it's a good idea to decode the encoder feedback signal using a dedicated chip (I used a HCTL-2032, for example) rather than have the microcontroller keep track of that critical timing-sensitive stuff while it's also keeping track of all the other stuff that the on board microcontroller needs to do.

effgee
Posts: 64
Joined: Tue Aug 07, 2012 2:41 am

Re: stackable I2C motor shields/brushed DC servo driver

Post by effgee » Fri May 24, 2013 1:36 am

thanks - I'll follow your progress for sure.

I assumed I'd use relatively 'slow' encoders, nowhere near the MHz range the HCTL chip is capable of, so my default would be to use hardware interrupts to read quadrature encoders on GPIO pins. But please don't take my comments as criticism or let me slow you down.

good work.

Post Reply