Re: [Emc-users] Resolver to Quadrature Convertor

2010-06-18 Thread Andy Pugh
On 25 April 2010 18:28, RogerN re...@wildblue.net wrote:

 In your opinion, do you think the Arduino would work to use as an amplifier
 by using 1 resolver and adding 3 phases of PWM to drive 3 half H-Bridges?

Yes. The answer is now a definite yes.

In fact since the question was asked about 2 months ago (it seems
longer) I have found several ways to do it, but the one that I got
going today was a purely Arduino + Power semi system.

The Arduino produces a sinusoidal excitation for the Resolver,
amplified and low-pass filtered by a power op-amp, the return voltages
are measured and decoded into an angle, which is then converted into a
Psuedo-Hall sensor pattern and used as the lookup into a commutation
table to choose 2 of 6 pins to drive. The 6 pins are taken to a buffer
IC which has the enable pin connected to a 20kHz PWM from one of the
Arduino PWM generators with a duty cycle based on a third analogue
input voltage (I have a speed-pot connected at the moment).

The drive PWM is taken to a separate power board consisting of a
bridge rectifier and a big capacitor as the DC 300V source, and an
IRAMS10UP60A (600V, 10A, £15) driver IC (and a set of opto-isolators).
http://docs-europe.origin.electrocomponents.com/webdocs/0dca/0900766b80dca34e.pdf

That is basically all there is to it, and it runs the 500W servos like
a champ. Very fast and very powerfully.

I don't expect to keep it in this configuration, I anticipate keeping
the resolver-to-quadrature parts of the Arduino code, taking the
quadrature signals into EMC2 and then using one of the Hostmot2
3pwmgens and one of the BLDC motor drivers that have been written for
EMC2 HAL in the intervening months.

I will keep the power driver and anticipate experimenting with a
minimalist setup of just the power driver, quadrature conversion and
Parallel port in order to see what the minimum-cost option is and just
how poorly it works. On the actual machine I am not sure how I will do
it, there is almost an embarassment of options now.

-- 
atp

--
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-26 Thread Andy Pugh
On 26 April 2010 00:58, RogerN re...@wildblue.net wrote:

 I see brushless servo amps on ebay for reasonable but I think most require
 hall signals.

 http://cgi.ebay.com/AMC-brushless-servo-amplifier-BE25A20E-/310165227459?cmd=ViewItempt=BI_Control_Systems_PLCshash=item483749c7c3

I could put the Resolver to Hall signal code up on the Wiki, but I a
lot less confident that it is right. Specifically I am not sure
which of the zeros of the resolver is considered zero degrees and how
the Hall signals typically correspond to that angle.  It also  needs
adjusting for different numbers of motor poles.

If you are happy to fiddle with the table that correlates Hall signals
to resolver angle then I can publish the Arduino code somewhere. It is
something that seems fairly risk-free to tinker with, as the
worst-case is that the motor just stalls and vibrates.

-- 
atp

--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-26 Thread RogerN

- Original Message - 
From: Andy Pugh a...@andypugh.fsnet.co.uk
To: Enhanced Machine Controller (EMC) emc-users@lists.sourceforge.net
Sent: Monday, April 26, 2010 3:56 AM
Subject: Re: [Emc-users] Resolver to Quadrature Convertor


 On 26 April 2010 00:58, RogerN re...@wildblue.net wrote:

 I see brushless servo amps on ebay for reasonable but I think most 
 require
 hall signals.

 http://cgi.ebay.com/AMC-brushless-servo-amplifier-BE25A20E-/310165227459?cmd=ViewItempt=BI_Control_Systems_PLCshash=item483749c7c3

 I could put the Resolver to Hall signal code up on the Wiki, but I a
 lot less confident that it is right. Specifically I am not sure
 which of the zeros of the resolver is considered zero degrees and how
 the Hall signals typically correspond to that angle.  It also  needs
 adjusting for different numbers of motor poles.

 If you are happy to fiddle with the table that correlates Hall signals
 to resolver angle then I can publish the Arduino code somewhere. It is
 something that seems fairly risk-free to tinker with, as the
 worst-case is that the motor just stalls and vibrates.

 -- 
 atp

 --

We have a couple different types of setup at work.  One we have to loosen 
the resolver coupler and align to the field, I'm guessing that it puts some 
holding torque on the field, perhaps rotating a few degrees to make sure 
it's locked in.  The other type you run a setup routine on and it learns the 
angle and stores in the controller.  Taking an educated guess, I would 
rotate the field like a stepper motor, watch for rotation of the resolver, 
then rotate the field the other direction monitoring for movement.  If the 
motor isn't under load, perhaps the armature will align up the field good 
enough for hall signals.

When I first got these motors, I wrote a PIC program that output 3 phase PWM 
SIN wave and ran it like a stepper motor mini-stepping.  I made up a 32 byte 
lookup table and put SIN values (Integer (sin(angle)+1) X 127) so 0 
represented -1, 255 represented 1, etc.  This value would be output PWM to a 
Half H-bridge, not a good one but good enough to experiment with.  I was 
only using maybe 20V to the motor, it ran slow but it ran pretty good.

Anyway, I think some setup procedure could be implemented to have the amp 
move and hold the armature, then either learn the angle or align the 
resolver.

Roger Neal


--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-26 Thread Andy Pugh
On 26 April 2010 00:58, RogerN re...@wildblue.net wrote:

 I see brushless servo amps on ebay for reasonable but I think most require
 hall signals.

I have put my Hall-sensor emulation code on the Wiki (as a link on the
same page). It is happily running my servo upstairs at this moment.
There is something odd that unless the speed is set just right it
keeps stopping. If I check the Hall signals with it stopped there is a
perfectly good Hall code, but there is +30V on all of the motor
terminals. I think this is either a peculiar drive fault, or possibly
the rather oversized motor for the drive (30V drive, 300V motor)
might be latching-up one of the drivers with back-emf (Is this
possible? It is purest speculation)

http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?ResolverToQuadratureConverter

-- 
atp

--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-25 Thread Dave
On 4/25/2010 9:57 AM, Andy Pugh wrote:
 Firstly let me make it clear that functional, competent, accurate and
 reliable Resolver to Quadrature convertors are available from Pico
 Systems and Mesa Electronics:
 http://pico-systems.com/resolver.html
 (I can only find a mention of the Mesa 7i49 on the price list, but I
 understand it does exist)

 Furthermore there are commercial chips to do the conversion too:
 http://www.analog.com/en/analog-to-digital-converters/synchroresolver-to-digital-converters/ad2s1200/products/product.html

 For reasons that I am not clear of myself, I eschewed all such
 approaches, and decided on a DIY approach, using an Arduino board. I
 have written it up on the Wiki.

 http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?ResolverToQuadratureConverter

 It handles 3 resolver channels and has been tested to 1600 rpm (the
 max speed of my cordless drill). Bench testing indicates that the
 quadrature pulses should keep up up to 3750rpm. For higher speeds it
 would be necessary to run fewer resolver channels.


Very nice Andy...

Thanks,

Dave

--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-25 Thread RogerN

- Original Message - 
From: Andy Pugh a...@andypugh.fsnet.co.uk
To: Enhanced Machine Controller (EMC) emc-users@lists.sourceforge.net
Sent: Sunday, April 25, 2010 8:57 AM
Subject: [Emc-users] Resolver to Quadrature Convertor


 Firstly let me make it clear that functional, competent, accurate and
 reliable Resolver to Quadrature convertors are available from Pico
 Systems and Mesa Electronics:
 http://pico-systems.com/resolver.html
 (I can only find a mention of the Mesa 7i49 on the price list, but I
 understand it does exist)

 Furthermore there are commercial chips to do the conversion too:
 http://www.analog.com/en/analog-to-digital-converters/synchroresolver-to-digital-converters/ad2s1200/products/product.html

 For reasons that I am not clear of myself, I eschewed all such
 approaches, and decided on a DIY approach, using an Arduino board. I
 have written it up on the Wiki.

 http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?ResolverToQuadratureConverter

 It handles 3 resolver channels and has been tested to 1600 rpm (the
 max speed of my cordless drill). Bench testing indicates that the
 quadrature pulses should keep up up to 3750rpm. For higher speeds it
 would be necessary to run fewer resolver channels.

 -- 
 atp

 --

I have a couple of servo motors I bought surplus, haven't used them mainly 
because the have resolvers and uses the resolver for commutation.  Some day 
when/if I need to use them the plan was to buy an amp that would work with 
them.

From your project I gather that a home made amp might be do-able reading 1 
resolver and driving 3 half H-bridges to control a motor.  I'm guessing to 
figure the timing between the resolver and fields it could be ran open loop 
like a stepper and record the resolver following angle between forward and 
reverse.  From there perhaps calculate the optimum angle for the field 
phases to the resolver position.  And after all that, give quadrature output 
for EMC2 to know the position.

In your opinion, do you think the Arduino would work to use as an amplifier 
by using 1 resolver and adding 3 phases of PWM to drive 3 half H-Bridges?

Thanks
Roger Neal


--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-25 Thread Andy Pugh
On 25 April 2010 18:28, RogerN re...@wildblue.net wrote:

 In your opinion, do you think the Arduino would work to use as an amplifier
 by using 1 resolver and adding 3 phases of PWM to drive 3 half H-Bridges?

Possibly, and it is something I have been thinking of looking in to. I
am not sure if it is possible to persuade the Arduino PWM drivers to
do the complementary low-side driver signals that I think are needed.
It might be easier to write a 3-phase PWM comp module for EMC2 to
create the driver signals. There is already one in the Hostmot2
software, but it is not currently supported in the EMC2 has drivers.
(That might change)

What is possible (and I have a version of the Resolver code that
already does it) is to synthesise Hall sensor signals to pass to a
generic BLDC motor driver. However most BLDC drivers don't handle the
voltages that servos are designed to run at.
I have made my servos rotate with a generic BLDC driver, but only
slowly (lack of voltage / high rotor inductance I think) and only
briefly (something odd about the drives, they trip out on overload
even with small BLDC motors well within their stated parameters)

I am thinking of buying one of these for further experimentation:
http://uk.rs-online.com/web/search/searchBrowseAction.html?method=getProductR=6880732
Mainly as the package includes shoot-through protection and I don't
trust my coding skills.

-- 
atp

--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-25 Thread Andy Pugh
On 25 April 2010 19:50, Andy Pugh a...@andypugh.fsnet.co.uk wrote:


 I am thinking of buying one of these for further experimentation:
 http://uk.rs-online.com/web/search/searchBrowseAction.html?method=getProductR=6880732
 Mainly as the package includes shoot-through protection

Thinking some more about this, the shoot-through protection means that
you can just drive the low-side inputs permanently low and apply PWM
to the high-sides. I have no idea if that will work.
There are 4 PWMs on the Arduino, though two share a timer.
The Mega has 14 PWM pins though, so presumably has rather more timers
and possibly more options (I have not looked)

I think that means that it could be done, but you might run out of CPU
calculating the phase angles and duty cycles.

-- 
atp

--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Resolver to Quadrature Convertor

2010-04-25 Thread RogerN

- Original Message - 
From: Andy Pugh a...@andypugh.fsnet.co.uk
To: Enhanced Machine Controller (EMC) emc-users@lists.sourceforge.net
Sent: Sunday, April 25, 2010 1:50 PM
Subject: Re: [Emc-users] Resolver to Quadrature Convertor


 On 25 April 2010 18:28, RogerN re...@wildblue.net wrote:

 In your opinion, do you think the Arduino would work to use as an 
 amplifier
 by using 1 resolver and adding 3 phases of PWM to drive 3 half H-Bridges?

 Possibly, and it is something I have been thinking of looking in to. I
 am not sure if it is possible to persuade the Arduino PWM drivers to
 do the complementary low-side driver signals that I think are needed.
 It might be easier to write a 3-phase PWM comp module for EMC2 to
 create the driver signals. There is already one in the Hostmot2
 software, but it is not currently supported in the EMC2 has drivers.
 (That might change)

 What is possible (and I have a version of the Resolver code that
 already does it) is to synthesise Hall sensor signals to pass to a
 generic BLDC motor driver. However most BLDC drivers don't handle the
 voltages that servos are designed to run at.
 I have made my servos rotate with a generic BLDC driver, but only
 slowly (lack of voltage / high rotor inductance I think) and only
 briefly (something odd about the drives, they trip out on overload
 even with small BLDC motors well within their stated parameters)

 I am thinking of buying one of these for further experimentation:
 http://uk.rs-online.com/web/search/searchBrowseAction.html?method=getProductR=6880732
 Mainly as the package includes shoot-through protection and I don't
 trust my coding skills.

 -- 
 atp

 --

I see brushless servo amps on ebay for reasonable but I think most require 
hall signals.

http://cgi.ebay.com/AMC-brushless-servo-amplifier-BE25A20E-/310165227459?cmd=ViewItempt=BI_Control_Systems_PLCshash=item483749c7c3

I believe the above is 25A (peak, 12.5A continuous) at 200 (maybe 240) Volt, 
should be good for about 3HP of servo.

Also I have seen some amps from Pacific Scientific that work with encoders 
or resolvers and will give a quadrature encoder out to the controller, I 
guess that would be a nice all in one solution.

RogerN



--
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users