SMALL - Telemetry SMALL - Radio
Thread Tools
Old Aug 26, 2015, 11:11 AM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Discussion
Voltage to PWM converter

Hi,
I am in need of a DC voltage to PWM converter that will output the correct 1000 -2000 microsecond pulse width.
First let me say I am no EE type person so be gentle with me. What I am trying to build is a module I can connect to the trainer port if my 9XR Pro so I can add a few potentiometers and use the PPM1-PPM8 sources. Basically adding some channels to work cameras, etc.
I am using a RMILEC PWM to PPM converter that will take the PWM for several sources and combine to a PPM signal which goes to the trainer port. That seems to be working. However my DC to PWM converter does not give me the pulse width required for RC. It's frequency is 1 Khz. I think I need one in the range of 500 Hz to work properly. Anyone know where I can get one that will work for me?
Thanks for your help
farmertom is offline Find More Posts by farmertom
Reply With Quote
Sign up now
to remove ads between posts
Old Aug 26, 2015, 11:40 AM
Odisej is offline
Find More Posts by Odisej
Registered User
Slovenia
Joined Sep 2006
134 Posts
Well... Do you wish to buy a module, make it from analog circuits or would an more advanced solution work?

So what you want is convert an potentiometer value to pwm @ 500Hz? Thought on using arduino?
Odisej is offline Find More Posts by Odisej
Reply With Quote
Old Aug 26, 2015, 11:51 AM
learningarduino is online now
Find More Posts by learningarduino
Registered User
Germany, NRW, Mettingen
Joined Oct 2014
101 Posts
Why not use a cheap Servo Tester?
learningarduino is online now Find More Posts by learningarduino
Reply With Quote
Old Aug 26, 2015, 01:33 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by Odisej View Post
Well... Do you wish to buy a module, make it from analog circuits or would an more advanced solution work?

So what you want is convert an potentiometer value to pwm @ 500Hz? Thought on using arduino?
I was hoping to purchase a small circuit board, similar to the one in the photo. I did not want to get into programming and the arduino area. You are correct in what I am looking for "convert an potentiometer value to pwm @ 500Hz"

Quote:
Originally Posted by learningarduino View Post
Why not use a cheap Servo Tester?
A good idea. However I have never torn one apart. Can I use another potentiometer with it? I was also looking to put a 6 position switch in the mix. Could I use a servo tester for that?
farmertom is offline Find More Posts by farmertom
Reply With Quote
Old Aug 26, 2015, 01:45 PM
learningarduino is online now
Find More Posts by learningarduino
Registered User
Germany, NRW, Mettingen
Joined Oct 2014
101 Posts
Usually there is a microcontroller inside that just samples a voltage divider between supply and ground.
As long as the resistance is not too far up almost any pot should do.
Also, you should never let that input open. But a rotary switch with 6 positions and so selecting only the higher part of a divider would also go.
learningarduino is online now Find More Posts by learningarduino
Reply With Quote
Old Aug 26, 2015, 03:11 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by Odisej View Post
Well... Do you wish to buy a module, make it from analog circuits or would an more advanced solution work?

So what you want is convert an potentiometer value to pwm @ 500Hz? Thought on using arduino?
Well I did a little testing. I connected my servo tester to my pwm to ppm converter and tested that with my radios trainer port. I worked exactly as I wanted it to. I then connected it to my scope and it said that the frequency is 50 Hz not the 500 Hz i though earlier . So I am looking for something that will convert a potentiometer value to pwm at 50 Hz.. Like I said before I am not a EE person. So I need something like the guts of a servo tester...
farmertom is offline Find More Posts by farmertom
Reply With Quote
Old Aug 26, 2015, 04:39 PM
Ole Joe is offline
Find More Posts by Ole Joe
Registered User
Joined Oct 2007
94 Posts
Quote:
Originally Posted by farmertom View Post
Well I did a little testing. I connected my servo tester to my pwm to ppm converter and tested that with my radios trainer port. I worked exactly as I wanted it to. I then connected it to my scope and it said that the frequency is 50 Hz not the 500 Hz i though earlier . So I am looking for something that will convert a potentiometer value to pwm at 50 Hz.. Like I said before I am not a EE person. So I need something like the guts of a servo tester...
http://www.hobbyking.com/hobbyking/s...vo_Tester.html
Ole Joe is offline Find More Posts by Ole Joe
Reply With Quote
Old Aug 26, 2015, 04:48 PM
phil_g is offline
Find More Posts by phil_g
Who let the dogs out?
phil_g's Avatar
Pontefract, Yorkshire, UK
Joined Jul 2007
1,267 Posts
It sounds like you're taking a very convoluted route to make a standard RC encoder, which will read as many pots as you have channels (1 to say 8) and output PPM suitable for directly feeding your trainer port. If you want to avoid programming microcontrollers then have a look at the NE5044 chip, its obsolete but its fairly easy to find one via the net. The datasheet is here

However reading your OP again I'm not sure of your logic - are you expecting these additional pots to be 'extra' channels over & above the standard channels? If so, that is a far more complex process which will almost certainly need to be done with a microcontroller. A simple encoder such as the NE5044 will create its own independent PPM stream based only on your new pot settings, the existing transmitter channels will be gone.

Cheers
Phil

EDIT: I just read the 9XR manual and I see what you mean now, it can replace user-selected channels in its own PPM stream with channels from an external stream coming into the trainer port. So yes, a simple, standard RC encoder will read your pots, output PPM to the trainer port, and via the 9XR setup you can select which standard channels you wish to replace with one of your 'pot' channels.
phil_g is offline Find More Posts by phil_g
Last edited by phil_g; Aug 26, 2015 at 05:01 PM.
Reply With Quote
Old Aug 26, 2015, 05:21 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by phil_g View Post
EDIT: I just read the 9XR manual and I see what you mean now, it can replace user-selected channels in its own PPM stream with channels from an external stream coming into the trainer port. So yes, a simple, standard RC encoder will read your pots, output PPM to the trainer port, and via the 9XR setup you can select which standard channels you wish to replace with one of your 'pot' channels.
You understand I see. Using a FrSky XJT tx module and a X8R rx. I could have 16 channels, 8 of which could be input through the trainer port. I am looking for standard RC encoder (DC to PWM) will read my pots without the extra you get with servo tester. I was looking for a chip solution already put together. I wanted to avoid building my own solution as I really on need 2 or 3 extra channels. I am using Dragon Link and that will only accept 12 channels. Any ideas? Thanks.

EDIT: You mention a 9XR radio. I am using a 9XR Pro radio that could output 16 channels with no replacements or substitutions.
farmertom is offline Find More Posts by farmertom
Last edited by farmertom; Aug 26, 2015 at 05:32 PM.
Reply With Quote
Old Aug 26, 2015, 06:47 PM
Mike Blandford is offline
Find More Posts by Mike Blandford
Registered User
Poole, England
Joined Mar 2008
1,813 Posts
The 9XR will also output 16 channels.
I asked on openRcForums, what are you using the existing 3 pots for?
There a various mixes already worked out that also let you temporarily assign one, or more, of the sticks to other channels, leaving the normal channel they control unchanged. Some of these mixes also work in a 'progressive' manner, that is the channel holds its position while the stick is in the centre, and move in the direction of the stick movement, moving faster the further the stick is moved.

So, assuming you fly mode 2 (ail and ele on right stick), you could change a switch, use the stick to adjust the pan and tilt of the camera, then put the switch back to resume control.

Mike.
Mike Blandford is offline Find More Posts by Mike Blandford
Reply With Quote
Old Aug 26, 2015, 07:09 PM
phil_g is offline
Find More Posts by phil_g
Who let the dogs out?
phil_g's Avatar
Pontefract, Yorkshire, UK
Joined Jul 2007
1,267 Posts
...preferably a spring-return switch!
phil_g is offline Find More Posts by phil_g
Reply With Quote
Old Aug 26, 2015, 07:14 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by Mike Blandford View Post
The 9XR will also output 16 channels.
I asked on openRcForums, what are you using the existing 3 pots for?
There a various mixes already worked out that also let you temporarily assign one, or more, of the sticks to other channels, leaving the normal channel they control unchanged. Some of these mixes also work in a 'progressive' manner, that is the channel holds its position while the stick is in the centre, and move in the direction of the stick movement, moving faster the further the stick is moved.

So, assuming you fly mode 2 (ail and ele on right stick), you could change a switch, use the stick to adjust the pan and tilt of the camera, then put the switch back to resume control.

Mike.
Mike,
I have replied to you on the other forum. It is not that I have used all of the functionality of the 9XR PRO radio, I am just trying to build something that will let me use more channels.
farmertom is offline Find More Posts by farmertom
Reply With Quote
Old Aug 26, 2015, 07:18 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by phil_g View Post
...preferably a spring-return switch!
Yes, as an older guy that may not be a sharp as I use to be, I see a problem using a stick as a "dual" controller. I would be safer for me to use a different dedicated channel.
farmertom is offline Find More Posts by farmertom
Reply With Quote
Old Sep 01, 2015, 06:09 PM
James_S is offline
Find More Posts by James_S
Registered User
United States, WA, Woodinville
Joined May 2014
2,339 Posts
Converting DC voltage to a PWM value is fairly easy using standard analog ICs. You make a ramp oscillator and feed that into one input of a comparator and connect your voltage source through a divider as needed to the other input. The voltage on the input determines the point in the ramp where the comparator flips and thus the duty cycle.

Here's an example of a ramp generator based on a 555 but you can use discrete transistors or other methods.

http://www.electronicsteacher.com/ex...-generator.php
James_S is offline Find More Posts by James_S
Reply With Quote
Old Sep 01, 2015, 07:36 PM
farmertom is offline
Find More Posts by farmertom
My planes plow into the field
farmertom's Avatar
United States, TN, Taft
Joined Oct 2012
832 Posts
Quote:
Originally Posted by James_S View Post
Converting DC voltage to a PWM value is fairly easy using standard analog ICs. You make a ramp oscillator and feed that into one input of a comparator and connect your voltage source through a divider as needed to the other input. The voltage on the input determines the point in the ramp where the comparator flips and thus the duty cycle.

Here's an example of a ramp generator based on a 555 but you can use discrete transistors or other methods.

http://www.electronicsteacher.com/ex...-generator.php
Thanks, I will have to study that link. I have been playing with a 555 timer. Where can I get a circuit already assembled?
farmertom is offline Find More Posts by farmertom
Reply With Quote


Thread Tools

Similar Threads
Category Thread Thread Starter Forum Replies Last Post
Help! Any Diy Arduino based PWM to Frsky CPPM converter out there? rank DIY Electronics 1 Jun 19, 2015 03:55 AM
Sold 6ch spektrum/lemon/orange rx, sats, ar8000, Pwm to ppm converters unitedheavy Aircraft - General - Radio Equipment (FS/W) 6 May 31, 2015 07:50 PM
For Sale RSSI PWM to Analog Voltage Converter DAX Aries321 FPV Equipment (FS/W) 0 Jan 03, 2015 07:34 PM
For Sale PWM to analog voltage converter for RSSI Aries321 FPV Equipment (FS/W) 8 Dec 30, 2014 06:11 PM
Discussion how to convert PWM servo signal to DC voltage sahilkit DIY Electronics 15 Oct 05, 2008 09:23 PM