Does opto22 Snap Pac S1 supports Pulse Width Modulation?


#1

Hi,
I would like to control model kit brushless motors with a Snap-Pac-S1/Snap-B3000-ENET system. These motors are controlled with by Pulse Width Modulation signal (http://en.wikipedia.org/wiki/Pulse-width_modulation). Is it possible to output such signals?

best regards,

Pierre


#2

hi pgaurillere
as i understand it, the SNAP-B3000-ENET brain coupled with a SNAP-OAC5/ODC5 module will handle TPO (Time Proportional Output) signals. This can be equated to PWM where the ‘Time’ the output is on is like the duty cycle of a PWM. The frequency that this happens with can be set via a command SetTPpoPeriod. The maximum frequency for a SetTpoPeriod is 10Hz (0.1Sec is the lowest TPO that can be set and 1/t = freq). Therefore the theoretical shortest time the output would be on would be 1% of 0.1Sec which = 0.01Sec (10mSec). If a fundamental frequency of <= 10Hz satisfies your application then YES the Snap-Pac-S1/Snap-B3000-ENET/SNAP-OAC5/ODC5 will work (if you are using OAC5’s the operating frequency for these modules is 25–65 Hz, ODC5-i modules should have no problem with 10Hz as their turn on/off time max is 750uSec).

I hope this helps
Nick


#3

Hi Pierre,

Nick is pretty much on the money for our standard modules, but as announced in our OptoNews letter (via email-you are signed up to get this right?) a month or so back, we now have a new module.
The SNAP-SCM-ST2. It is a two channel module that provides pulse and direction outputs.
The duty cycle will always be 50%, but you can change the frequency over a wide range, including what you require.

But as Nick said, make sure you always check your module switching speed, some are surprisingly quicker than others…

Ben.


#4

thanks for your detailed answers. I will check this new module, and see if it is necessary to control my ESCs. My ROV testbench seems to be pretty close to see the water.

regards,

Pierre


#5

Hi Pierre
Just a heads up, i believe the SNAP-SCM-ST2 requires a new SNAP-PAC brain. Legacy brains such as the B3000-ENET do not support this module.

I hope this helps
Nick


#6

Hi Ben, I have purchased two SNAP-SCM-ST2 modules for pulse width modulation. However, I can’t work out how to change the duty cycle to anything other than 50 percent. If you can shed some light on how I can achieve pulse width modulation with these modules, it would be greatly appreciated.
Thanks,
Paul

[B]Edit: [/B]I enquired with opto22’s product support department and they emailed to say that the SNAP-SCM-ST2’s duty cycle is fixed at 50%. So this module is [I]not[/I] suitable for pulse width modulation! I am editing this post so that other people do not make the same mistake.

[B]Edit2: [/B]Thanks Ben for modifying your post to make it clear that the duty cycle is set at 50%.


#7

The data sheet for the SNAP-SCM-ST2 module (doc 1944) states:

“Pulse Width is equal to one-half the period.”

I do not think you will be able to vary the duty cycle from 50% with it, but maybe there is a clever way to phase control multiple channels and achieve something like PWM. Keep in mind that the pulses are at 5 V with 200 mA max current.

I don’t really understand how the technique on page 134 of doc 1701 gets you to 500 Hz. With an R1 brain, the minimum period (composed of 1 [I]on time[/I] and 1 [I]off time[/I]) is 0.006 s, or 166.7 Hz. The doc states that attempting to create a pair of on and off times that total less that this minimum period will cause the values to be scaled up to the minimum, but maintain the requested duty cycle.

Another thing to keep in mind with the digital output modules is that with a rise time of 100 µs and a fall time of 750 µs, a period much below 10 ms (100 Hz) will create a waveform that is starting to lose its squareness at lower duty cycles, and may not give you the results you are expecting. However, the digital modules provide many voltage options and a higher current limit (3 A), so PWM at slower frequencies looks solid.

I had looked into this because I was interested in using PWM to control the position of a proportional valve. I had concluded a separate PWM drive would be necessary for my application, and found a couple of inexpensive options that could be easily controlled by Opto’s standard analog outputs. You may find what you need by checking out the sites below.

http://www.criticalvelocity.com/

http://www.axiomatic.com


#8

Hi Sensij,
Thanks for the information and the links. I am currently working through our options to achieve a PWM signal from our PAC. I will update this post with my results once it is up and running.
Paul


#9

Good news PWM fans.

We have a new module, and this one is a true PWM module!

I have not had a chance, but I will be hooking this guy up to some RC servos to drive them as soon as I can.
The engineers have assured me that this module will drive RC gear just fine.

http://www.opto22.com/site/pr_details.aspx?cid=1&item=SNAP-AOD-29-HFi

Its going to be interesting to see how this module opens up new doors for Opto gear.

I’m looking forward to providing some simple sample code to drive a servo as soon as I can.

Cheers,

Ben.