loading

Back in October 2013, I made an Arduino based adapter that allows unidirectional aeroplane ESCs to work with surface/pistol radios for RC cars and boats. I've already detailed on what the adapter is and how it works or even why it is needed, check out the Ver.1 instructables.

I used a ATmega8 microcontroller in that adapter and honestly, that by itself was the size of an average ESC, I couldn't really put it anywhere conveniently on my car due to space constraints and weight concerns (If I can cut down on 5g, believe me, I will).

Last week I fried that adapter that was using the ATmega8 and so I decided optimize it by replacing the Mega8 with an ATtiny45. It's a pretty straight forward switch from the Mega to Tiny, the only difference is in the code, It uses the Servo8Bit library for the Tiny45.

I ran my car on more than 12 packs over the course of two weeks and I haven’t noticed any problems, no run-away car, nothing. The new adapter works like it should, hassle-free! However, if someone builds one and experiences problems, I’d be happy to help you guys out.

NOTE: The only electronic component used in the adapter is an ATtiny microcontroller, it’s not supposed to heat up even after hours or continuous usage. If you do feel the adapter dissipating heat, there has to be something wrong with it; please stop using it immediately and double-check all connections. The ATtiny45/85 set to 8MHz clock frequency is rated to run on an optimum 5V (Typical BEC voltage of most ESCs), anything significantly less or more may affect the performance of the microcontroller.

Step 1: Schematic

Step 2: Etch-free PCB for SoIC Package

I used an 8-pin SoIC package, so I needed a PCB. DIPs should be easier to solder and not need a PCB.

This article on how to soldering SoIC devices by hand should get you started.

Step 3: Programming the ATtiny45

Temporarily tack on wires to the SPI pins (MOSI, MISO, SCL, RST, GND, VCC) so you can program it.

I used a USBasp programmer to upload the code to the Tiny45. You can also use an Uno or Mega to program it, here's how.

Before you burn the code, select ATtiny45 (Internal 8MHz clock) from Tools > Boards

It's important that you select the 8MHz clock, because the Serv8Bit library is limited work at to 8MHz.

Download Arduino code.

Step 4: Soldering the Servo Connectors

Be very careful while soldering the servo connectors, make sure you don’t have any accidental solder bridges between pins, run a sharp blade in between pins just in case. Looks a bit ugly, but it works!

Double check connections after you're done, test it and wrap it in heat shrink insulation tube.

Visit my blog for the extra bit of story behind this DIY!

Good luck, DIYers!

<p>After doing a lot of tinkering, I was finally able to get it to work, the missing step was to burn the bootloader @ 8MHz internal clock. Used an 8 pin dip socket to make the Tiny45 easily removable for programming and soldered the socket to a perf board which I then cut to size. </p><p><strong>If anyone in the US or Canada needs one made or if you'd like a more in depth guide made let me know!</strong></p>
Yup, I was stuck at it for half a day. Looks nice, you should wrap it with some heat shrink tubing. I'm working on a new version of it with an LED to indicate signal status and a switch for an optional ESC failsafe redundancy which could be useful with Rradios/ESCs that don't come with a fail-safe feature.
<p>Hello I've tried to verify the code and it's giving an error.... oddly it's not including the servo8bit.h file and instead it's running the code (servo8bit.h) in another tab???? Please help.</p>
<p>Did you ever get that sorted?</p>
<p>No I gave up on this project cause I was planning to modify it for some other use (which i realised it is a futile attempt at doing it). I believe the code is for a different IDE (not arduino).</p>
<p>I'm also going to use this for something else; electric longboard. I'm almost positive this is for the Arduino IDE, you can even see the Arduino environment running in the second image of step 3.</p><p>I've managed to program the ATTiny45 using an Arduino as an ISP with the code he provided. However, when I plug the programmed Tiny45 to my receiver &amp; ESC, it does nothing. I noticed that there is a folder named Rx_signal_values_CODE, so I uploaded that code to my Arduino which I believe is intended to help debug any issues and print the values that the Tiny45 is generating to the serial monitor. The Tiny45 is spitting out random numbers even when my RC transmitter is not connected. </p><p>This is as far as I've gotten but have only been working on this for a couple of days now. I'm still looking into how the 8bit library works etc. So any and all input would be great!</p>
I recently made a couple more for a friend.
<p>Those look very good! I just bought some of those small PCB's too! Thank you for making this and sharing!</p>
You will need to set the tiny 45/85's fuse bits to 8MHz. Refer: http://highlowtech.org/?p=1695
Code was originally written using 1.0.3. Although, I was able to compile and upload using the latest 1.0.6 using Arduino ISP.
<p>I've ensured the Arduino IDE is setup for Tiny45 8MHz Internal. I was initially using Arduino V 1.6.4 but I have downgraded to 1.0.6 and succesfully reprogrammed the Tiny45 But I still have no luck in getting it to work with my ESC.</p><p>I plugged my RC receiver into the Arduino and used the RX_signal_values.ino that you included, and I am able to get a reading on my Transmitter's signal via serial monitor. The values are as follow:</p><p><strong>999</strong> when applying full brake (trigger is pushed forward all the way) </p><p><strong>1500</strong> when in middle position (trigger is in resting position) </p><p><strong>2000</strong> when full throttle (trigger is pulled all the way back)</p><p>Now that I have a reading on the input side of the Tiny45, how can I get a reading on the output side on Pin 6?</p>
If I remember correctly, the Arduino code folder will contain the .ino file and two other hex files along with it, without which the sketch will not compile.
<p>I believe the Step 1 Schematic image is incorrect; it shows the positive and negative leads of the ESC both going to the same power rail, essentially shorting out.</p>
Yup, sorry about that. I will edit it ASAP.

About This Instructable

3,588views

27favorites

License:

Bio: 22 . Mechatronics Engineer . Hopeless Realist
More by Aj Creations:Love Spark Adding Auto-Reset Pin to PL2303 based Serial-USB Modules DIY- xESC Adapter [ATtiny version] 
Add instructable to: