Shop our Airplanes Products Drone Products Sales
Thread Tools
This thread is privately moderated by midelic, who may elect to delete unwanted replies.
Jan 15, 2015, 12:05 PM
Registered User
midelic's Avatar
Thread OP
Mini-HowTo

DIY FlySky RX ATTINY85/45


Lately I saw interest from some users regarding Flysky rx on Attiny85/45.
It looks like the old thread for rx is dead and large most of the info there was lost inside.
So I decided to make new diagram and post the code here on my blog.
Attached are 2 hex files one for Attiny85 and one for Attiny45.
See below.
Hardware:
XL7105-SY orCL
Attiny85/45(not tested on 45 yet) SMD
1K resistor(SMD 805)
LED-SMD size and color(603 or 805)
CAP-0.1uF(100nf)(SMD 603 or 805)
DIODE-1n4148 or other SI diode(or optional LDO)
Lipo-4.2V(if using 5V power supply need ldo voltage regulator or 2 diodes 1N4148 in series with LIpo positive wire)
If using ldo voltage regulator, there are very small ldo(same size like a SMD transistor for example MCP1700(CS(3.3V)))
The consumption is very low around 20mA.

Pinout:
SDIO-PB0
SCK-PB1
SCS-PB2
GIO1-PB4
PPM(BIND)-PB3


Note:
DON'T EXCEED MAX 3.6V on XL7105

Added some info for how to make this setup dead bug style to keep the weight down.See some pics from old thread.
https://www.rcgroups.com/forums/show...01&postcount=3
Added also my pics with setup used.,,weight around 2.9g with wires,connectors,shrink tubing,and all.If using CL version the weight drops considerably.Between SY and CL version there is a weight difference of 0.7 grams.
Added also pics showing a SOIC8-DIP adaptor for flashing Attiny chip.
29.06.2015
Added a version for 16Mhz.
Fuses for 16mhz
ATtiny85 16Mhz BOD 2.7V.

low_fuses=0xF1
high_fuses=0xD6
extended_fuses=0xFE


31.08.2015
Added some pics for a RX with CLversion weight 1.5 grams.
I uploaded it with 16Mhz code.


Shopping:
http://www.banggood.com/A7105-XL7105...-p-922597.html
http://www.ebay.com/itm/2-4G-Wireles...item2c81b6bf3c
http://www.suntekstore.com/goods-100...xl7105-cl.html
http://www.ebay.com/sch/i.html?_from...p1700&_sacat=0
http://www.ebay.com/sch/i.html?_saca...y85+smd&_frs=1
http://www.ebay.com/sch/i.html?_saca...c8+dip8&_frs=1

IMPORTANT:
I use for flashing TSB bootloader via PPM pin(PB3) one wire.This is easy and fast,
http://jtxp.org/tech/tinysafeboot_en.htm
Last edited by midelic; Mar 25, 2017 at 10:47 PM.
Sign up now
to remove ads between posts
Feb 03, 2015, 12:18 PM
Registered User
midelic's Avatar
Thread OP
bump
Last edited by midelic; Mar 21, 2017 at 12:06 AM.
Feb 06, 2015, 12:51 PM
MrSupreme Overlord of Universe
joefarmer's Avatar
Probably a dumb question, but why is SCS on the XL7105 left floating? Shouldn't it be tied to ground?
Feb 06, 2015, 01:10 PM
Registered User
midelic's Avatar
Thread OP
SCS is not floating is CS pin to attiny.Sorry if was not clear.You can read on first post also SCS -PB2
Feb 06, 2015, 01:46 PM
MrSupreme Overlord of Universe
joefarmer's Avatar
Quote:
Originally Posted by midelic
SCS is not floating is CS pin to attiny.Sorry if was not clear.You can read on first post also SCS -PB2
Ah, ok. I was following the schematic image and didn't see the connection. Thanks!
Feb 22, 2015, 01:43 AM
MrSupreme Overlord of Universe
joefarmer's Avatar
I made a PCB from Oshpark for this code and the XL7105-CL. I hope it's okay to post it.

https://www.oshpark.com/projects/BFvdiQfO
Feb 22, 2015, 03:08 AM
Registered User
midelic's Avatar
Thread OP
No problem .OShHpark produce 1.6mm thick board is a litle bit heavy.But if is ok for you no problem.It looks nice.Did you tested it?
Feb 22, 2015, 03:13 AM
Registered User
midelic's Avatar
Thread OP
I find out that the Attiny85 can be programmed via USB using a hacked version of arduino. So next version of pcb may be simplified.

http://www.banggood.com/Digispark-Ki...-p-953375.html

I bought one board and can glue one XL7105 or CC2500 on the back...and can test rx very fast.
Feb 23, 2015, 10:25 AM
MrSupreme Overlord of Universe
joefarmer's Avatar
I have 0.6mm boards coming from Elecrow now that I've successfully tested it with the ATTINY85. I haven't done a full range check but it seemed to be okay walking up and down the sidewalk with the transmitter in my house.

I also built one with the Adafruit 3V Trinket that I use as a wireless module with the simulator. I used Avrdude to flash your code on it and I can only USB flash with pin 3 on the Trinket disconnected from the XL7105. The Trinket uses pin 3 and pin 4 to communicate with USB, so I think that should be expected.
Feb 23, 2015, 12:12 PM
Registered User
midelic's Avatar
Thread OP
Good news..it will be very light with 0.6 mm.If you do a full range test please post here..I'm curious didn't have time for one.Which Tx did you use ..Turnigy 9x?
Feb 24, 2015, 03:40 PM
MrSupreme Overlord of Universe
joefarmer's Avatar
Yes, Turnigy 9x flashed with opentx 2.0.13. It seems to be centered on 1507 instead of 1500 exactly, but that's easy enough to trim out.
Apr 11, 2015, 08:47 AM
Registered User
midelic's Avatar
Thread OP
I have an untested version of Frskyrx with Attiny on 16Mhz internal clock.In theory the channel data resolution is improved from 8us to 4us...and less channels fluttering.
The hardware remain the same, only changed, fuses.
ATtiny85 16Mhz BOD 2.7V.

low_fuses=0xF1
high_fuses=0xD5
extended_fuses=0xFE


edit:
removed ,not good version
the correct one is on first post
Last edited by midelic; Jul 04, 2015 at 07:58 AM.
Apr 13, 2015, 11:59 AM
MrSupreme Overlord of Universe
joefarmer's Avatar
I plan on scoping the old hex in the next few days. Then switch to the new code and compare the graphs. I'll let you know what I see. Thanks for the new code!

I forgot to post the new lightweight boards showed up!
Last edited by joefarmer; Apr 13, 2015 at 12:10 PM.
Apr 13, 2015, 12:19 PM
Registered User
midelic's Avatar
Thread OP
It looks excellent.Id you add a small dipole antenna you can increase range a lot.That small pcb antenna not give you much range.
Apr 20, 2015, 04:04 AM
Registered User
Quote:
Originally Posted by midelic
Please test this one.I think I fixed the problem.
Hy! This 16Mhz version can work with Attiny45? Sorry for my bad english! Thx


Quick Reply
Message:
Thread Tools