2018-08-07 11:13 PM
Hello everyone.
I'm working on a project. I must use a resolver for our servo motor. But I could not find any sample code for resolver.
Can anyone help me?
Thank you.
2018-08-08 06:47 AM
Sorry do you have a different word for "resolver"
You want to drive a servo with a 50Hz (20ms) PWM?
OR you want to read a pulse width, PWM Input?
2018-08-08 07:21 AM
Hello Clive
Thank your for your answer.
First, I explain the resolver; A resolver is a type of rotary electrical transformer used for measuring degrees of rotation.
It's like an encoder.
I want to measure the position with using a Resolver in STM32F4 Discovery. But I could not find any example for this.
Any sample codes or another, I want.
Thank you.
2018-08-08 07:39 AM
I'd imagine you'd need to drive it with a sine-wave (opamp via DAC), and then use two ADC to pull the signal wave forms, and then make a determination about the phase or whatever.
Sorry, I'd probably use an encoder. Perhaps there are simple IC available for interfacing with a resolver and providing an reading.
Analog Devices, TI and Freescale seem to have chip level solutions, perhaps review datasheets and block diagrams to see if you could implement equivalent functionality using STM32 resources.
2018-08-08 11:50 AM
You are unlikely to find a ready-made code sample. But its principle very simple. 90 degree resolver represent amplitudes as sin and cos of the rotation angle. You can read more detail in Wikipedia:
2018-08-08 01:06 PM
has the resolver been resolved yet?
2018-08-09 05:28 AM
"But its principle very simple. "
yes, but only in principle.
if the two signals are orthogonal, the math is simple.
otherwise (due to parasitic capacitance or resistance for example), it becomes tricky, particularly if you want to calculation to iterative, to minimize memory footprint.
2018-08-09 09:16 AM
Yes, at frequencies near the resonance frequencies of coils, their parasitic capacitances and resistances must be taken into account, in order to obtain the best results. However, it seems to me that the shafts of motors do not rotate so fast.