Thread Tools
This thread is privately moderated by gabapentin, who may elect to delete unwanted replies.
Sep 18, 2017, 06:20 PM
Registered User
gabapentin's Avatar
Thread OP
Discussion

Arduino radio for HK-T6A or Flysky FS-CT6B (ArduTX rebirth)


Hi everyone!

I've tried to modify Arduino sketch code from this thread


https://www.rcgroups.com/forums/show...omputer-update

Patolin project seems to be left to its destiny....

A great Patolin idea to upgrade cheap HK-T6A or FS-CT6B transmitters or any other old RC TX
These transmitters offer a configuration through a serial port with an external PC software program
and no space to store more than one model.

The code has been modified to work with SH1106 SPI 1.3" or SSD1306 SPI 0.96" OLED display through U8g2 library
Have been used all possible pins of ATmega328 (Nano, Pro Mini)
Every text strings has been stored in flash memory to mantain a lot of free RAM memory

Main Features:
  • Low power consumption (2S LiOn/LiPo battery)
  • 3 buttons for settings
  • Stable 6 Channel PPM generation
  • 5 memory for storing model data
  • 2 gimbal stick + 2 pots support
  • Throttle Cut switch
  • Dual Rates switch
  • Normal Reverse channels settings
  • Dual Rates settings (Low, High)
  • Battery monitor

Added features to original Patolin code:
  • SPI OLED display 128x64 support
  • Analog input ports with possible high ADC sampling used
  • All possible digital input/output pins used
  • 3 digital buttons input for menu (original code are analog input)
  • Switch checking status with sound alert at power ON and display which is not in default position
  • Throttle warning with display status of switches and sound alert
  • Hidden data default restoring by pressing and hold Down/Next button on power on
  • Hidden calibration procedure by pressing and hold Enter/Select button on power on
  • Real time battery control whith alarm sound (buzzer with stand alone sound generator)
  • N2 supplementary switch, they can be configured instead of VRA or VRB pots (SWA, SWB)(Servo Direction Menu)
  • Basic two channel mixer with switch activation V-Mix (Ch1/ch2)
  • Basic four channels Sub Trim setting (ch1, ch2, ch3, ch4) with real time PPM monitor

The code seems to be stable

If anyone have an interest/try this project or want optimize the code

This is Github repository link of sketch code -> https://github.com/Gabapentin/Arduin...-Radio-control


For Wiki instructions -> https://github.com/Gabapentin/Arduin...o-control/wiki


For any question or support please post reply on this thread

I will try to answer asap



Name: Screen_0.jpg
Views: 38
Size: 494.7 KB
Description: Name: Menu.jpg
Views: 37
Size: 491.8 KB
Description: Name: Servo_Direction.jpg
Views: 36
Size: 478.8 KB
Description: Name: Dual_Rates.jpg
Views: 33
Size: 495.2 KB
Description:

Name: Model.jpg
Views: 36
Size: 453.4 KB
Description: Name: Sub_Trim.jpg
Views: 33
Size: 491.8 KB
Description: Name: Switch_Warning.jpg
Views: 34
Size: 490.6 KB
Description: Name: Calibration.jpg
Views: 35
Size: 514.9 KB
Description:


Pay attention!

The voltage power supply for original radio Turnigy/Flysky TX module is 5V

PPM output from Arduino must be reduced with a voltage divider because TX module is not 5V tolerant



************************************************** ************************************************** ****************************

17/01/2018 Arduino Nano general schematic update

- Incorrect label of Arduino TX RX pins
- Added debounce resistors on push buttons
- Modified piezo buzzer driving (transistor powered from battery and buzzer connected on emitter)

************************************************** ************************************************** ****************************

21/01/2018 Arduino Nano PCB Eagle files on github

- Uploaded Eagle CAD PCB files on my github (Please rember It's only prototype will be modified) >>

- Modified schematic image for buzzer cabling on Wiki page with transistor powered from battery and buzzer on emitter >>

************************************************** ************************************************** ****************************

28/01/2018 Sketch file for battery and alarm calibration values

- Added sketch file on github for battery and alarm calibration values >>

.
Last edited by gabapentin; Jan 28, 2018 at 09:24 AM. Reason: Added sketch file link on github for calibrating battery and alarm
Sign up now
to remove ads between posts
Sep 22, 2017, 05:12 PM
Registered User
Hi gab,
I sure would like to get the code, I have a transmitter or 2 that I would like to modify.
Thanks man.
Sep 23, 2017, 04:08 AM
Registered User
gabapentin's Avatar
Thread OP
Quote:
Originally Posted by gdenton3
Hi gab,
I sure would like to get the code, I have a transmitter or 2 that I would like to modify.
Thanks man.
Hi gdenton,

Thank you for your interest

See the initial post

I've updated with github links

At this time the wiki is not complete

If you have any question leave a post on this thread

I will try to answer asap

Have a nice day
Sep 24, 2017, 11:25 AM
Registered User
pierpiero83's Avatar
Hi gab,

thank you for sharing this nice project, I am very interested as I am planning to reuse an old 80s radio transmitter that was going on 72 MHz, it's a pity leaving it on the shelf!

I follow this thread !

Regards
Sep 24, 2017, 02:01 PM
Registered User
gabapentin's Avatar
Thread OP
Hi Pier ,

you are also welcome!

this is my first converted radio (some years ago)

I've used PhilG modified code and Flysky 2.4 home made transmitter

It was a hard to maintain fully functional analog battery indicator through Arduino

but seems working fine

thank you for give me credit

BR's
Sep 24, 2017, 06:18 PM
Registered User
gabapentin's Avatar
Thread OP
Sorry Pier

I don't know why!?!?!

but your post has been marked like a spam! banned from forum site and not published

below is a copy of your message:

----------------------------------------------------------------------------------------

Last edited by pierpiero83; Today at 09:51 PM wrote

General questions
So...

I would like to give you some random questions that come in mind:

1) Is there any chance to include TRIM pots somehow, maybe implementing another Arduino nano? In my 80s model, as many,
I have configuration as shown in the attachment photos;

2) Do you recomend specific couple of PPM transmitter - receiver (example: FlySky, Futaba, whatever brand)?

3) Any plan about drawing a custom PCB or simple drawing which represent the needed wiring?

Thanks man

Piero

EDIT - Found this on the web, what you think?

--------------------------------------------------------------------------------

1) I have already seen your gimbal stick configuration

we only think how to connect correctly main pot and subtrim pot with only 3 wire

Using another Arduino is useless and wasteful

----------------------------------------------------------------------------------------------------------------------------------------------------------

2) Flysky PPM Transmitter module it's very cheap and it works - Flysky compatible receiver have a low cost

Flysky Transmitter https://www.banggood.com/Wholesale-F...r-p-66598.html

Flysky compatible Receiver https://hobbyking.com/en_us/hobby-ki...er-6ch-v2.html

----------------------------------------------------------------------------------------------------------------------------------------

FRSKY is a good compromise between price and quality

https://hobbyking.com/en_us/frsky-df...module-rx.html

https://hobbyking.com/en_us/frsky-dh...er-module.html

----------------------------------------------------------------------------------------------------------------------------------------

3) Plannig custom PCB at this time I think not necessary because is in beta testing

If you need a schematic is attached in my first post (I think you have download it!?!?)

If you need more informations about hardware and wiring

see my github wiki https://github.com/Gabapentin/Arduin...o-control/wiki

(please be patient work in progress)

-----------------------------------------------------------------------------------------------------

About Mega2560 Pro Mini

If you planned to build a new Radio Transmitter is a good idea (too much work to do )

Seems to be working with OLED display but is in beta testing

see this link http://rcaerolab.eklablog.com/radio-...teprc-p1234216

or this discussion thread https://www.rcgroups.com/forums/show...560-and-OpenTx

BR's

Last edited by gabapentin; Sep 24, 2017 at 06:39 PM.
Oct 10, 2017, 12:53 AM
Registered User
Hi gabapentin

About Trim button , can supported it ? use one pin ADC and devide resitor?

You can modify Project to use with Mini kit stm32f103c8t6.?
Oct 10, 2017, 06:10 AM
Registered User
gabapentin's Avatar
Thread OP
Quote:
Originally Posted by happy rc
Hi gabapentin

About Trim button , can supported it ? use one pin ADC and devide resitor?

You can modify Project to use with Mini kit stm32f103c8t6.?
Hi HappyRC

The sub trim regulation is performed modifying center pot ADC value through menu

It's the same thing as moving center pot with old mechanical subtrim lever

you can see in realtime the servo movement when you press up/down buttons with selected channel and ADC to PPM value

The subtrim center value will be stored in memory for every single channels and for every single model

Very simple solution to use with ATmega328 without enough pins

The project is not intended to create new radio but to upgrade existing cheap or old radio

stm32f103c8t6 is a good start to develop a new RC radio (but at this time is not my intention)

If you want build a complete RC radio with enhanced features you can follow OpenTX project with ATmega2560

https://www.rcgroups.com/forums/show...-OpenTx/page46
Oct 10, 2017, 11:44 PM
Registered User
Ok thank you

i will not build a at2560 ,only build a TX simple but use a STM32F103C8T6 because it cheap , pins and stronger at328.

So hope you have time work with it ,
Oct 14, 2017, 09:43 AM
Registered User
pierpiero83's Avatar
Hi gabapentin,
talking about battery section, is 8,2V mandatory, or I can also use a 7,4V 2s LiPo?
Then, sorry for the newbie question, I would like to know why are you powering the arduino nano through A7 pin and not through VIN pin?
I attach your diagram below.
Oct 14, 2017, 11:57 AM
Registered User
gabapentin's Avatar
Thread OP
Quote:
Originally Posted by pierpiero83
Hi gabapentin,
talking about battery section, is 8,2V mandatory, or I can also use a 7,4V 2s LiPo?
Then, sorry for the newbie question, I would like to know why are you powering the arduino nano through A7 pin and not through VIN pin?
I attach your diagram below.
Hi Pier

No mandatory because

8.2V -:- 8.4V is LiPo at full charge

7.4V is battery nominal voltage

If you have seen schematic....

A7 pin of Arduino is only a voltage sensor for battery control not for power supply

I' m sorry for your mistake

I will change the image and description in wiki

BR's
Oct 14, 2017, 12:22 PM
Registered User
pierpiero83's Avatar
Sorry, I was stuck only on your wiki page and didn't realise I had to follow the diagram for first...
mea culpa
Oct 14, 2017, 06:33 PM
Registered User
gabapentin's Avatar
Thread OP
Quote:
Originally Posted by pierpiero83
Sorry, I was stuck only on your wiki page and didn't realise I had to follow the diagram for first...
mea culpa
don't worry Pier

I did not explain well in wiki....

------------------------------------------------------------------

Sorry Pier

about your gimbal stick with double pot for subtrim

See the schematic below for connection

please check pots values with digital multimeter

and looks at the radio's PCB if the wires of gimbals pots are connected to a resistor

I think there are at least four resistors with the same value one for every sub trim pot


Name: Subtrim_double_pot.png
Views: 82
Size: 21.0 KB
Description:
Last edited by gabapentin; Oct 14, 2017 at 07:43 PM.
Oct 16, 2017, 05:56 AM
Registered User
gabapentin's Avatar
Thread OP

Tried to make PCB


I've tried to make PCB shield with Pro Mini

Name: ArduTX_New_Pro_Mini_Header.png
Views: 79
Size: 161.6 KB
Description:

Prototype PCB with mini JST 2.0 connectors

Name: PCB_proto_JST.jpg
Views: 104
Size: 303.7 KB
Description:
Last edited by gabapentin; Oct 18, 2017 at 06:38 AM. Reason: Image update
Oct 21, 2017, 02:50 PM
Registered User
pierpiero83's Avatar

Tx module...


Hi Pat,
talking about transmitter, I bought a Flysky FS-RM003 on banggood. It fits nicely on my radio controller, no cutting needed, but obviously, like many chinese stuff, didn't come with any documentation. I even tried to email FlySky company through their official website, but they didn't answer at all.

I took a picture of the board, can you please help me understand what the pins are for and which ones I have to connect to arduino?
However, I don't know if it runs with 5V or 3.3 V.

Piero


Quick Reply
Message:
Thread Tools

Similar Threads
Category Thread Thread Starter Forum Replies Last Post
Discussion New software for the HobbyKing HK-T6A, FlySky FS-CT6A and Turborix TBXT6 radio HappyMan2009 Radios 492 Apr 30, 2018 07:47 AM
Help! HK-T6A V2 Tricopter setup, Digital Radio Guidance xn1337 Radios 0 Nov 05, 2015 08:41 AM
Discussion [GUIDE] frsky diy on flysky ct6b (hk t6a) mick3485 Radios 4 Mar 04, 2014 02:46 PM
Discussion Flysky FS-CT6B radio system. Just one quick question about setup. Please help. larsen8or117 Radios 4 Jul 01, 2011 10:55 AM
Discussion HK-T6A/FlySky FS-CT6A hack to generic wireless UART? meteor DIY Electronics 10 Apr 04, 2011 08:34 AM