Forum rules
Talk about Adafruit Raspberry Pi® accessories! Please do not ask for Linux support, this is for Adafruit products only! For Raspberry Pi help please visit: http://www.raspberrypi.org/phpBB3/

Amplify PWM for Adafruit 16-Channel 12-bit PWM/Servo Driver

by yulrich on Wed Oct 09, 2013 11:25 am

Hi,
I hope this question is not already here, but I've got a questions concerning the Adafruit 16-Channel 12-bit PWM/Servo Driver for the Raspberry Pi: I want to use the Servo Driver with an ESC which requires a signal voltage of at least 4.5V. Since the driver only supplies the 3.5V from RPi I figured out that I need to do something about it. I experimented a little with a transistor but I didn't get it working.
This is the ESC: http://www.lrp.cc/en/products/electronic-speed-controls/brushed-forwardbrakereverse/produkt/aiautomatic-super-reverse-digital/details/.
I want to add that I'm not an expert on electronics..
Cheers,
Yannick
yulrich
 
Posts: 2
Joined: Wed Oct 09, 2013 11:10 am

Re: Amplify PWM for Adafruit 16-Channel 12-bit PWM/Servo Dri

by adafruit_support_bill on Wed Oct 09, 2013 11:41 am

You could do it with a small transistor. http://www.adafruit.com/products/756
If you are not comfortable working at that level, we have some logic-level converters on convenient breakout boards:
http://www.adafruit.com/index.php?main_ ... ogic+level
User avatar
adafruit_support_bill
 
Posts: 25354
Joined: Sat Feb 07, 2009 9:11 am

Re: Amplify PWM for Adafruit 16-Channel 12-bit PWM/Servo Dri

by yulrich on Fri Oct 11, 2013 1:55 pm

adafruit_support_bill wrote:You could do it with a small transistor. http://www.adafruit.com/products/756
If you are not comfortable working at that level, we have some logic-level converters on convenient breakout boards:
http://www.adafruit.com/index.php?main_ ... ogic+level

Thanks for the fast answer! I would like to that with the transistor and I experimented a little with that but I could not get it working… Would you mind providing a little schematic?
Thanks a lot!
Yannick
yulrich
 
Posts: 2
Joined: Wed Oct 09, 2013 11:10 am

Re: Amplify PWM for Adafruit 16-Channel 12-bit PWM/Servo Dri

by adafruit_support_mike on Fri Oct 11, 2013 9:32 pm

It would look something like this:

inverter.jpg
inverter.jpg (12.21 KiB) Viewed 95 times

You need a resistor between the servo-controller signal and the transistor's input terminal (the 'base') because that's basically a diode. Its voltage never wants to go much higher than 0.6v or 0.7v, and trying to put 3v or 5v across it Would Be Bad.

The 10k resistor connected to the transistor's 'collector' produces the signal. When the servo-driver signal has the logic value 'LOW', its voltage will be close to 0v. When you have 0v between a transistor's base and emitter, we say the transistor is 'off' or 'closed' because almost no current can flow through it (a few nanoamps of leakage current maybe). When the servo-driver's output has the logic value HIGH, its voltage will be close to VCC. That allows enough current to flow through the 10k input resistor to the transistor's base, turning it 'on', or 'opening' it. Then lots of current can flow through the transistor.

From the perspective of the 10k output resistor, almost no current flows through it when the transistor is closed, so the voltage across it will be nearly zero. That puts the signal going to the ESC close to VCC. When the transistor is open, current does flow through the transistor and the output resistor. That puts a large voltage drop across the output resistor, so the signal going to the ESC goes close to GND.

Note that the input and output voltages get reversed: HIGH from the servo-driver produces LOW going to the ESC, and LOW coming form the servo-driver produces HIGH going to the ESC. That's equivalent to the logical operation of inversion, so this circuit is called an 'inverter'.
When you void a product warranty, you give up your right to sue the manufacturer if something goes wrong and accept full responsibility for whatever happens next. And then you truly own the product.
User avatar
adafruit_support_mike
 
Posts: 6983
Joined: Thu Feb 11, 2010 1:51 pm