↓
 

majek.sh

Marek WodziΕ„ski's home page

  • About me
  • LCD88
    • About
    • Features
    • Hardware
    • History
    • How it works
    • Posts about lcd88
  • R/C
  • Electronics
Home - Page 5 << 1 2 3 4 5 6 7 8 9 >>

Post navigation

← Older posts
Newer posts →

HobbyKing SuperSimple HK-18A and SimonK firmware

majek.sh Posted on Tuesday April 23rd, 2013 by majekSunday March 18th, 2018

Cheap and good ESC for Tricopter

ESCs are needed for every multirotor. Some are cheap, but dedicated to planes (slower response), some have extra features in firmware, but costs a little more.

But thanks to SimonK and his firmware, there is possibility to reprogram many of them. So, to build my Tricopter I decided to buy cheapest one available and reprogram it:
HobbyKing SS Series 15-18A ESC
SuperSimple HK-18A ESC

So, let’s modify it πŸ™‚

Hardware

In order to download new firmware you need some Atmel programmer (I use USBasp from HobbyKing but on eBay you should get better and cheaper version supporing both 3.3V and 5V logic levels). Also you need some real soldering skills, steady hand and possibly magnifying glass πŸ™‚

At start: remove shrink-wrap from ESC. The best and safest place to cut it is on one side.
hk-18a cut shrink-wrap

After getting shrink-wrap off, first surprise: I have probably new version of pcb because it looks a little different than on pictures from list of supported ESCs. But luckily it’s almost the same but with added programming pads:
hk-18a programming pads

As you can see on above picture there are 6 pads. But bad news is that some are clean and flat, and other one are with ‘balls’ of tin (and on each ESC there were different combination of these). This makes difficult to make some programming connector to touch reliable to these pads.
So, only soldering left for me.
To solder without problems to such small pads I made ‘balls’ of tin on all pads:
hk-18a programming pads with balls and pin description

Then I soldered header pin connector with very thin wires (Kynar wires, diameter 0.2mm/AWG32). If you first tin end of this wire, then soldering it to the ‘balls’ on pcb is easy (with magnifying glass πŸ™‚ ).
hk-18a with isp header

And just connect it to USBasp and program it!
hk-18a connected to USBasp

Software

Of course you need software to flash it into ESC πŸ™‚

Getting it

I got it directly using:

git clone https://github.com/sim-/tgy.git

Then I modified tgy.asm to disable runtime calibration:

.equ    RC_CALIBRATION  = 0     ; Support run-time calibration of min/max pulse lengths

In my opinion this is not needed for this ESC as it has quartz oscilator and will be controlled by MultiWii board instead of receiver.

Code compilation

tgy$ make tp_8khz.hex
avra -fI -o tp_8khz.hex -D tp_8khz_esc -e tp_8khz.eeprom -d tp_8khz.obj tp_8khz.asm
AVRA: advanced AVR macro assembler Version 1.3.0 Build 1 (8 May 2010)
Copyright (C) 1998-2010. Check out README file for more info
&nbsp;
   AVRA is an open source assembler for Atmel AVR microcontroller family
   It can be used as a replacement of 'AVRASM32.EXE' the original assembler
   shipped with AVR Studio. We do not guarantee full compatibility for avra.
&nbsp;
   AVRA comes with NO WARRANTY, to the extent permitted by law.
   You may redistribute copies of avra under the terms
   of the GNU General Public License.
   For more information about these matters, see the files named COPYING.
&nbsp;
Pass 1...
Pass 2...
done
&nbsp;
Used memory blocks:
   Data      :  Start = 0x0060, End = 0x008C, Length = 0x002D
   Code      :  Start = 0x0000, End = 0x03ED, Length = 0x03EE
   Code      :  Start = 0x0E00, End = 0x0FDF, Length = 0x01E0
   Code      :  Start = 0x0FE0, End = 0x0FFF, Length = 0x0020
&nbsp;
Assembly complete with no errors.
Segment usage:
   Code      :      1518 words (3036 bytes)
   Data      :        45 bytes
   EEPROM    :         0 bytes

If you don’t want or you are unable to compile this code, firmware compiled by me is here.

Programming firmware

In this step you need Avrdude or other AVR programming software which allows to flash ready firmware in Intel Hex format.

tgy$ make program_usbasp_tp_8khz
avrdude -c usbasp -B.5 -p m8 -U flash:w:tp_8khz.hex:i
&nbsp;
avrdude: set SCK frequency to 1500000 Hz
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: AVR device initialized and ready to accept instructions
&nbsp;
Reading | ################################################## | 100% 0.01s
&nbsp;
avrdude: Device signature = 0x1e9307
avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: set SCK frequency to 1500000 Hz
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: reading input file "tp_8khz.hex"
avrdude: writing flash (8192 bytes):
&nbsp;
Writing | ################################################## | 100% 5.02s
&nbsp;
&nbsp;
&nbsp;
avrdude: 8192 bytes of flash written
avrdude: verifying flash memory against tp_8khz.hex:
avrdude: load data flash data from input file tp_8khz.hex:
avrdude: input file tp_8khz.hex contains 8192 bytes
avrdude: reading on-chip flash data:
&nbsp;
Reading | ################################################## | 100% 4.38s
&nbsp;
&nbsp;
&nbsp;
avrdude: verifying ...
avrdude: 8192 bytes of flash verified
&nbsp;
avrdude: safemode: Fuses OK
&nbsp;
avrdude done.  Thank you.

Bootloader

Above code contains a bootloader, so further reprogramming could be very easy and could be done using only BEC/PPM connector. But for such programming you will need another device: Turnigy USB Linker or you could do it yourself using Arduino board and ArduinoUSBLinker software.

In order to bootloader works, it’s needed to change BOOTSZ and BOOTRST bits, so new value of hfuse should be 0xca (or 0xc2 if eeprom should survive chip erase).

tgy$ avrdude -c usbasp -u -p m8 -U hfuse:w:0xca:m
&nbsp;
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: AVR device initialized and ready to accept instructions
&nbsp;
Reading | ################################################## | 100% 0.01s
&nbsp;
avrdude: Device signature = 0x1e9307
avrdude: reading input file "0xca"
avrdude: writing hfuse (1 bytes):
&nbsp;
Writing | ################################################## | 100% 0.00s
&nbsp;
avrdude: 1 bytes of hfuse written
avrdude: verifying hfuse memory against 0xca:
avrdude: load data hfuse data from input file 0xca:
avrdude: input file 0xca contains 1 bytes
avrdude: reading on-chip hfuse data:
&nbsp;
Reading | ################################################## | 100% 0.00s
&nbsp;
avrdude: verifying ...
avrdude: 1 bytes of hfuse verified
&nbsp;
avrdude done.  Thank you.

Testing

I recommend to connect ESC to battery first time using 10 Ohm resistor (few Watts recommended). It’s value is small enough to allow motor start and run, but it’s also large enough that any software or hardware malfunction couldn’t burn your ESC.
modified hk-18a - testing via resistor

And on the end – small video with original and flashed ESCs with motors:

Posted in R/C | Tagged avr, r/c, simonk, tricopter, video | 3 Replies

Logic analyzer

majek.sh Posted on Monday February 25th, 2013 by majekTuesday July 2nd, 2013

This time there will be a combined article – something about my new toy: logic analyzer, but also there will be introduction to diversity video receiver.

Logic analyzer

If you do anything with digital equipment or diy projects etc, logic analyzer could be very helpful tool for debugging. It’s great also for reverse engineering πŸ™‚
From some time I had in my mind The Fabulous Logic Analyzer but parallel port is not what is available in modern laptops πŸ™
Then I saw how Saleae Logic16 works:-) It was impressive, especialy that it works also under Linux. But 100-200 euros are a little over my budget for new toy, so I started searching for affordable alternatives. After some digging on the Internet, I found that old Saleae Logic, CWAV USBee SX and other cheaper logic analyzers are based on Cypress CY7C68013A chip and have almost nothing more than this chip alone. So, I found on Ebay Lcsoft CY7C68013A Mini Board prototyping board at less than $12 and now I have one πŸ™‚
LCSoft Cypress prototyping board

It’s not compatible with Saleae despite of programmed USB VID/PID. But because I try to use opensource where possible, so my only choice was Sigrok.
After getting hard time to meet Sigrok dependency (Python3, sdcc and other unusual software), it compiled and started to run. Sigrok comes with it’s own firmware for Cypress chip, so no pirating here:-)

It’s even better, because Lcsoft board has jumper to switch between ‘Saleae mode’ and ‘Cypress Development Kit’.
In Saleae compatible mode, Sigrok uploads standard firmware, so only 8 inputs are available at 24MHz sample rate.
But when we switch to ‘native’ mode, we have logic analyzer with 16 inputs πŸ™‚ Of course 16 bit sampling is not available at 24MHz but when we narrow count of inputs up to 8, full sample rate is still available.

Sigrok is quite new project, so gui is not it’s strong side, but at least there is possibility to sample and look at waveforms, and that’s all – even saving of sampled data is not available in gui πŸ™
Sigrok's Pulseview

On the contrary, command line sigrok_cli is quite powerful.

Analyzing video receiver

So, it’s time to analyze something, and standard video receiver which comes with Fox700 transmitter as bundle is ideal for it πŸ™‚
I was wondering from some time what exactly happens on i2c bus, ie. how tuner is programmed for specific frequency, and an opportunity to get it known arrived πŸ™‚

Standard 1.2GHz video receiver
Logic analyzer and video receiver

As you can see on the above pictures, I added simple level converters with resistors and Zener diodes. It’s because logic of video receiver is 5V and Cypress is 3.3V chip. Of course I tried without Zener diodes, but weird things were happening πŸ™‚

Sampling with sigrok_cli:

$ sigrok-cli --driver fx2lafw --device samplerate=24000000 --time 1s -p 0-7
libsigrok 0.2.0
Acquisition with 8/16 probes at 24 MHz
0:00000000 00000000 00000000 00000000
1:00000000 00000000 00000000 00000000
2:00000000 00000000 00000000 00000000
3:11111111 11111111 11111111 11111111
4:11111111 11111111 11111111 11111111
5:11111111 11111111 11111111 11111111
6:11111111 11111111 11111111 11111111
7:11111111 11111111 11111111 11111111

Ones and zeros are fine, but real power of Sigrok is ability to decode protocols:

$ sigrok-cli --driver fx2lafw --device samplerate=24000000 --time 10s -p 0-7 -o test.sr
$ sigrok-cli -i test.sr -a i2c:sda=0:scl=1
i2c: "START"
i2c: "ADDRESS WRITE" "0x68"
i2c: "ACK"
i2c: "DATA WRITE" "0x05"
i2c: "NACK"
i2c: "STOP"
i2c: "START"
i2c: "ADDRESS READ" "0x50"
i2c: "ACK"
i2c: "DATA READ" "0x00"
i2c: "NACK"
i2c: "STOP"
i2c: "START"
i2c: "ADDRESS WRITE" "0x61"
i2c: "ACK"
i2c: "DATA WRITE" "0x2b"
i2c: "ACK"
i2c: "DATA WRITE" "0x6c"
i2c: "ACK"
i2c: "DATA WRITE" "0x8e"
i2c: "ACK"
i2c: "DATA WRITE" "0xf0"
i2c: "ACK"
i2c: "STOP"

Initial write and read are some junk, I think that chip used for programming tuner, had originally other purpose and peripherials, but what is really interesting is data written at address 0x61.
According to documentation of SP5055 (synthesizer used on most tuners), 0x61 is it’s ‘always valid’ address, despite of signal on address settings pin, so it always works.
During that write there are 4 bytes transferred: 2 bytes of divider (unique for each selected channel), and 2 bytes for setting state of chip and external outputs (always the same).

So, let’s check what tuned frequency should be.

Divisor is 0x2b6c (MSB is transferred first) = 11116

According to datasheet, tuned frequency is:
f = divisor * 16 * Fcomp
Fcomp is frequency of quarz or external generator (typically 4MHz) divided by 512, so:
f = divisor * 16 * 4000000 / 512

In this case synthesizer is tuned to 1389500000Hz = 1389.5MHz
But that’s not the end – we must substract intermediate frequency 479.5MHz of tuner.
So, in fact we are tuned to 910MHz and this is exactly a 0 channel which was set on this receiver during test.

Success! πŸ™‚

One thing I’m missing in sigrok_cli is lack of timestamps (number of samples could be shown using -v flag), but it’s open source and everyone could add this (maybe even I) πŸ˜‰

Right now, when I know how to control tuner in receiver, I could make my own controller.
Why? Because documentation of SP5055 and some tuners shows that there is possibility to read also some data from tuner. Most interesting is little ADC connected typically to circuit that shows offset between set and receiving frequency. With this information it’s possible to automatically fine tune to exact frequency. It’s also possible to follow frequency change while transmitter warms up. And of course it’s possible to tune to any frequency in tuner range with 125kHz step πŸ˜‰
Tuning multiple tuners at once isn’t also a problem, so making simple diversity based on video rssi it’s also possible,

Posted in Electronics, Linux, R/C | Tagged diy, fpv, i2c, logic analyzer, sigrok, video receiver | 13 Replies

Awesome spectrum analyzer from DVB-T tuner

majek.sh Posted on Tuesday February 19th, 2013 by majekSaturday June 22nd, 2013

Few weeks ago I stumbled upon some topic on one of FPV forums about checking frequency, spectrum, antennas etc. I realized that people are using cheap DVB-T tuner based on Realtek RTL2832U chip as spectrum analyzer, SDR (software defined radio) and even as osciloscope.
There were many situations in my hobby when this brilliant device could help a lot. This discovery was so hot, so I decided to buy such usb dongle ASAP, even at slightly bigger price (55zΕ‚ ~ $16) than directly from China. I found it in one shop in my town and next day I became happy owner of this tuner πŸ™‚

This is Lifeview LV5T Deluxe (branded as NOT ONLY TV):


It’s equipped with a little different tuner than described on rtlsdr/osmocomSDR site, Fitipower FC0013 capable of working within 22-1100MHz frequency range:

Software

To be clear: I use Linux πŸ™‚
First step was to download and install rtl-sdr library from http://sdr.osmocom.org/trac/wiki/rtl-sdr . In this package there are also ready made udev rules to install, so root access is not required later for using it.
On this web page one can find also links to some related projects using this library.
Next step was to get pyrtlsdr library for Python as most of these project are written in that language. After installation of few more dependencies as wxPython, numpy, matplotlib etc I started testing software πŸ™‚

RTLSDR-Scanner

My first application was RTLSDR-Scanner. Kind of old school, well known spectrum analyzer:

Easy to operate, with zoom but capable to scan only within range of whole MHz, so scan in narrower range than 1MHz is not possible (you could zoom, but it doesn’t enhance frequency resolution).
So, it was quite good, but I needed more πŸ™‚

rtlsdr-waterfall

Waterfall applications is a real power of computerized spectrum analyzer!
This very easy Python script is more than useful.

For example, scan of commercial FM radio frequencies – all in one:

And situation when waterfall shows it’s power – 433MHz ISM band scan with some devices transmitting only during small window of time (on the left it’s probably wireless sensor for weather station):

And back to R/C πŸ™‚ My 40MHz transmitter:

You could select and measure frequency range, make pan and zoom (but on lower frequencies application crash during zooming), change sesnsitivity of tuner to remove clipping and additional strips caused by this.

Audacity

Yes, you are reading right: Audacity – well known audio editing program. I made a little patch (not perfect) to allow change sample rate up to 10MHz because default maximum was 100kHz and typical rtl-sdr sample rate is about 2MHz, so selection tool and fft features are not working correctly.
Using rtl_sdr utility from rtl-sdr library, I dumped raw samples near desired frequency and then I imported it as raw 8 bit stereo samples into Audacity. Below are results:-)

My 35MHz transmitter on 71 channel. I have little problems with range on this channel and this picture shows why:

On this image you can see:

  • this is 5 channels radio (6 peaks of synchronization pulses)
  • main frequency is shifted by about 5kHz from sampling base i.e. channel frequency – and it’s cause of poor reception
  • deviation is about 3kHz (to about 8kHz from center of channel)

Using quartz for 63 channel it works much better from my experience and below is proof of this:

Shift from base frequency is less than 3kHz, so it’s better than on 71 channel.

For comparision, my simple 4 channel 40MHz transmitter:

Very tempting looks SDR# (available also on Windows) but require a lot more weird dependencies, so I put it for later.
But I’m sure that this topic will return some day with more new cool informations πŸ™‚

Update 2013.06.22: second part is here.

Posted in Electronics, Linux, R/C | Tagged r/c, rtlsdr, spectrum analyzer | 11 Replies

End of Rex 6000 era

majek.sh Posted on Monday February 18th, 2013 by majekFriday May 30th, 2014

Somewhere in 2001 year I was hooked by small PDA with touch screen: Xircom REX 6000.
There was also very broad community with active developers around this device. Addons, applications, hints and hacks were popping around πŸ™‚
This was quite expensive device, but also very unique: small, PCCARD size PDA with touch screen, permanent memory (flash), many useful bundled applications (contacts, calendar, to do list, wml browser), and possibility to sync that data between computer. More, there was also dedicated portal rex.net containing news, weather forecasts and more, which could act as sync source for REX, so you could download this info into PDA and read it later offline. Soon, some applications appeared to download very custom content (e-books, timetables, memos etc) using hack for this feature. Everyone was happy using this device πŸ™‚
And then Intel appeared, seized Xircom and announced that best feature of REX 6000, rex.net portal will be shut down in month or two.
There were not too much time to do something with it. Because I was also big fan of this device (I owned two), I’ve had my own server and I was familiar with all http/cgi stuff, I started to do reverse engineering of whole sync protocol with portal. It wasn’t easy but after about month I suceeded to make basic site working as replacement for original rex.net. Month of hard full-time work was possible because … I broke my collarbone and I had to stay at home πŸ™‚
It was also very handy that sync application (only for Windows) had url of sync site stored in Windows registry, so replacing it was very easy.

And that way rex.mamy.to was born πŸ™‚
It was my first ‘community’ project:-) Because I was unable to deliver similar data to original rex.net site, I decided to allow portal users to define urls for grabbing content. With some basic filtering (skipping not important parts of text, strip and interpret html tags) everyone could prepare ‘tailor made’ dynamic content (updated twice a day). There was also possibility to define ‘static’ content, so everyone could prepare ‘pages’ with e-books, manuals and so on. And of course, every content could be private, public or shared only with specific list of other users – and most of it were public.
As for today, more than 4000 custom ‘pages’ was created on this site by more than 3000 users from all of the world, most of it in first two years of running this site.
In Facebook era this numbers are not impressive, but these days it was quite a lot.
After rex.net shutdown, Intel even mentioned on its site that rex.mamy.to exists as community replacement for discontinued service. πŸ™‚

Right now, after about 12 years of providing uninterrupted service, it’s time to end this chapter. I run it as long as someone was using it and as long as my very old software worked without modification. But last year there were only 3 people logged in (two were syncing REX!). I’m also in the middle of migration of services from old server to new one, and after migration there is almost impossible that 12 years old compiled cgi (using libraries for Mysql 3.x) still will work.

So, this is end of rex.mamy.to, sorry.

Posted in Life | Tagged rex.mamy.to, rex6000, xircom | 15 Replies

LCD88: R/C DIY transmitter

majek.sh Posted on Saturday January 12th, 2013 by majekSunday September 1st, 2013

Another one? πŸ™‚

There are some other open source transmitter projects, so why did I start another one?
At first, I started it in 2009 – there wasn’t too much free options avaliable, ready made transmitters were also very expensive. And last, there weren’t enough flexible for me :-). Even right now I don’t know if similar transmitter exists, at least at affordable price, not thousands of $$ πŸ™‚

BLOCKS!

The gist of this project is: BLOCKS!
For each model you have some sticks, pots, switches and output channels. Between inputs and outputs there is more or less flexible ‘black box’.
In my project you could define exactly what is in this ‘black box’ by connecting math blocks together in absolutely free way.

Blocks could do:

  • trims
  • reverse
  • add
  • substract
  • negate
  • expo
  • multiply
  • convert any analog value to 3 state (for switch conditioning)
  • some casual mixers
  • limits
  • and many more…

Better explanation is just to show some examples, so look at them!
For examples you should only know that channels 0-7 are inputs, 16-23 are outputs, some has special meaning or are reseved but right now it’s not important.

Simple model – as in all entry level transmitters

It’s easy:

Channel 0 (CH0) is stick input, value goes into reverse block. Another input for this block is CH40 which remebers reverse position. Output of reverse block goes to channel 52. Another stage is trim block which takes value from channel 52 and adds it to trim value from channel 28. Other channels should be done in similar way.
Special block reverse is in fact a multiply block but it’s treaten in special way – second channel connected to it shows automaticly in ‘Reverse’ menu.
In similar way trim block is an add block which second input shows in ‘Trims’ menu.

Looks easy, isn’t it? So, let’s go ahead.

Delta or flying wing

Another example: delta mixer.
At the beggining let’s write some equations:

left aileron = ( rudder stick + elevator stick ) /2
right aileron = ( - rudder stick + elevator stick ) /2

So let’s draw blocks to calulate it:

Ok, but this is only mixer, what about trims, reverses etc?

So, look at real life model:

Looks complicated, but let me explain what’s going on.

A little transformed formula for delta mixer in this case:

right aileron=0.5*elevator+0.5*rudder
left aileron=0.5*elevator-0.5*rudder

I think that most people who flies flying wing could confirm that this type of model is very sensitive to elevator moves. One solution for this is to make expo/DR on elevator channel. But I preffer make elevator just less sensitive in favor to rudder. So, instead of using 0.5 coefficient to multiply values from both channels, I use smaller one for elevator and greater for rudder. If coeficcients sum up to 1, results will be still within allowed range (I already did it on my standalone delta mixer based on ATTINY13).

Let’s look at above picture. Blocks 1-3 are here to make flexible coefficients. On Block1 input is 1 (CH25) and trim (CH40), so it makes at output (CH41) value in range 0…2 dependent on trim position. It’s too big to further calculations, so we must scale it down using Block2. At it’s output (CH43) we have value in range 0…1. Block3 calculate second coefficient for multiplication (CH44=1-CH43). Blocks 5,7,10,11,12, form a delta mixer with adjustable amplification for both control sticks. After delta mixer, there are reverse and trims blocks to adjust servo direction and neutral point. Near input there are blocks 4,6 and 8 – there are standard trims for fine tuning during fly.

So, as long as you could make some equations to describe how channel values should be processed, you could make it.

Enough about blocks:-) Let’t go to other topics.

Software architecture

There are few types of tasks inside transmitter:

  • critical – generating accurate PPM
  • high priority – get values from inputs, calculate blocks and store results for PPM
  • best effort – user interface (menu, displaying something on LCD, trims, options etc.)

Generating PPM

I use hardware PWM generator to make an accurate PPM signal. In best possible way πŸ™‚
That’s possible because of using timer in CTC mode and interrupts with right, but not so critical place in time. The point is that writing new value to timer in this mode during generating waveform is effective only for new cycle and doesn’t affect current operation, so it could be calculated and programmed anytime during this period. I calculate it just after end of synchro pulse (in interrupt triggered by this event), so CPU has at least 10000 clocks to do it, and this is more than enough. Because of that, there is absolutely no jitter and pulses are just perfect. πŸ™‚

Getting values, calculating it and other things

That’s another cool solution here: multitasking in AVR!
After copying output values to buffer for generating PPM, CPU starts getting analog values from ADCs (using interrupts). They are filtered and recalculated and results are put in input channels. Meantime 2 thing are running: PPM generation using interrups and user interface or other not critical things. When all values from inputs are ready, a task switch occurs. User interface thread is interrupted, state is saved to ram and block calculation task begins. After processing and calculating all blocks, this task ends and switches back to user interface task.

This way PPM is generated perfectly, calculating blocks is done in high priority thread, and the rest fo time could be used to draw some fancy things on color LCD πŸ™‚
Great advantage of multitasking is that during programming user interface I could do whatever I want without bothering myself about timing as long as interrupts are enabled.

Memory

I decided to use internal flash memory as main storage for model definitions (blocks, initial channel values etc.). I organized data into containers with headers containing information about model number, contents of container (block, channel, comment…) and length. And one important rule: there could be many containers with the same ‘id’ but only last in memory is valid. It makes updates as simple as writing new version of container at the end of other containers. It also help to reduce flash write/erase cycles. Only drawback is that memody should be compacted from time to time.
But using trims could fill all flash memory very fast, so I decided to make temporary storage only for channels (4 bytes/ch) in eeprom. In future there will be possibility to move values from eeprom back to flash. It will be needed to backup/restore model definitions.

Features

  • Model memory (maximum 31).
  • Each model comprise of:
    • comments, model name is one of them and is mandatory (maximum 256 per model) – they could be assigned to channels and blocks
    • channels, some are dedicated to inputs, some to outputs, the rest could be used for trims, reverses, connections between blocks etc. (maximum 253 per model)
    • blocks, they do math operations on input channels and store result to another channel(s) (maximum 255 per model)
    • block processing order, right now you must manually generate list of blocks in order they should be processed
  • 8 output channels, but it could be increased keeping in mind that output frame should be extended
  • 8 analog inputs, they can be also ‘conditioned’ and used for switches
  • PPM output (super accurate, jitter free, ~11000 steps per channel)
  • internal calculations does on 16 bit fixed point numbers (6+10), it is equivalent of more than 2048 steps
  • serial bootloader, so firmware upgrade could be done using standard usb-serial cable/interface
  • Colour LCD screen
  • 6 keys for menu navigation
  • Open source! (code will be available soon)

A little bit of history

In 2006, when I started to think about R/C models, I bought cheapest 4 channel transmitter with idea, that if I’ll need more – I’ll make it:-)
Somewhere between 2007 and 2008, during discussion on Alexrc forum, idea of very flexible and fully programmable transmitter were born.
Idea was to define model inside transmitter using basic blocks (sum, multiply etc) and connections between inputs, blocks and outputs.
In 2008 I made a universal board for my projects using Atmega8L and LCD screen from Siemens S65 phone.
In 2009 I replaced Atmega8L with Atmega88 – it allowed to safely (within cpu specs) increase cpu clock up to 11MHz while still running at 3V. And then real story begins:-)
At the end of 2009 I had some things finished: generating ppm, calculating blocks and basics of user interface (menu, keyboard). And then project stuck for almost 3 years.
I tried to make it too universal, and it didn’t worked for UI. During these years I used simple transmitters – there were enough for my planes. But at the end Tricopter appeared:-) Problems with arming control board and need for more channels resurrected old project.
So, at the end od 2012 i removed some code (mostly UI related), revised some assumption (store model definitions not only in flash, but also use eeprom for this), and project moved forward.
I put this board into empty old transmitter bought at about $2, added FrSky DHT module, connected all together and right now it could be used in real world:-)

Future

  • Switch to Atmega168 or Atmega328 (I have both and code is ready – it’s only a matter of doing PCB and solder it together)
  • Because right now there is almost impossible to buy S65 LCD display (but I have few πŸ™‚ ), I bought another similar one. Plan is to make code supporting also this new display.
  • Change code to run on standard Arduino board based on Atmega328 (check all timings in code and rewrite it to support other cpu frequencies)
  • More code, more features (but not on Atmega88 because I already hit memory limit)
  • Timers, i/o extender (more inputs, trainer mode)
  • …
Posted in Electronics, R/C | Tagged arduino, avr, diy, frsky, lcd88, ppm, r/c, transmitter | 6 Replies

Post navigation

← Older posts
Newer posts →
  • English
  • Polski

Recent Posts

  • Jeep Grand Cherokee ZJ electric fan
  • New 3D printer – vn-corexy
  • Classic keyboard for Lenovo X230
  • Changes, changes
  • Writing to internal FLASH on Arduino
  • dm-cache in Slackware
  • Christmas tree lamps with Arduino and WS2811 leds :-)
  • Initrd in Slackware
  • Picture thief
  • Soldering AWG10 wire to XT60 connector
  • LCD88 – going public :-)
  • XEBOOT – tiny Amega8 xmodem bootloader
  • RTL-SDR and ADS-B
  • Bluetooth dongle from China :-)
  • 2013 ended, 2014 is here

Recent Comments

  • demostenes on HobbyKing SuperSimple HK-18A and SimonK firmware
  • majek on Soldering AWG10 wire to XT60 connector
  • Hello on Soldering AWG10 wire to XT60 connector
  • wefwe on End of Rex 6000 era
  • KudΕ‚aty on Frequency meter up to 100MHz
  • majek on Frequency meter up to 100MHz
  • somok on Frequency meter up to 100MHz
  • majek on Frequency meter up to 100MHz
  • AM Technologies on Frequency meter up to 100MHz
  • majek on LCD88: R/C DIY transmitter

Categories

  • 3D printing (1)
  • Car (1)
  • Electronics (22)
  • Life (12)
  • Linux (9)
  • R/C (20)

Archives

  • July 2022 (1)
  • January 2021 (1)
  • April 2018 (1)
  • March 2018 (1)
  • June 2015 (1)
  • March 2015 (1)
  • January 2015 (1)
  • December 2014 (2)
  • August 2014 (1)
  • June 2014 (1)
  • May 2014 (1)
  • March 2014 (2)
  • February 2014 (1)
  • November 2013 (1)
  • August 2013 (1)
  • June 2013 (3)
  • April 2013 (1)
  • February 2013 (3)
  • January 2013 (2)
  • December 2012 (1)
  • October 2012 (1)
  • September 2012 (1)
  • August 2012 (9)
  • July 2012 (1)
  • June 2012 (2)
  • March 2007 (1)
  • March 2006 (1)
  • October 2005 (1)
  • February 2002 (1)

Tags

1-wire ads-b arduino avr awstats car china crash dialog diy dns e-osd e-wro fpv frsky fun g-osd gps gΕ‚upota harpagan i2c lcd lcd88 linux logic analyzer multiwii netia osd ppm r/c repair rex.mamy.to rex6000 rtlsdr simonk slackware small things spectrum analyzer transmitter tricopter video video receiver vn-corexy watchdog xircom

Blogs

  • Blog Akuaku
  • Savage Chickens
  • xkcd

Friends

  • Belfer
  • Copernicus Project
  • freesco.pl
  • Harpagan
  • Sadziu
  • Tropiciel
  • Wydawnictwo Dobrew (audiobooki)
  • Wydawnictwo Muszkin

Hosting

  • mamy.to
©2025 - majek.sh - Weaver Xtreme Theme
↑