View Full Version : Discussion AVR fail safe
Matt Edwards
Nov 14, 2006, 05:02 AM
my times is running out, too many long work hours and not enough hobby hours.
Has anyone made a fail safe using AVRs? I would like to make a unit, but a bit stuck on kicking a the project off.
I am not asking for code, just implementation giudelines.
Cheers & TIA
Matt
lajon63
Nov 14, 2006, 07:54 AM
I have made some RC related stuff on AVR. Do you plan to support just one channel or many? If you plan to support many channels (and you have a PPM receiver you don't mind HW hacking a bit) you could attempt to decode the PPM signal (i.e., all channels with just one input pin). Using a 16-bit timer and ICP (input capture) is probably the best solution for input in any case. You can use the output compare interrupts on the same timer to generate output. A bit more work if you plan to use one of the smaller AVR:s with no 16-bit timer.
You could search or ask at www.avrfreaks.net for more info, there are e.g., several threads about servo output generation there.
/Lars
Acetronics
Nov 14, 2006, 09:04 AM
Hi, Matt
There was a nice project on ELEKTOR Magazine those times ...
see here : http://www.elektor.com/Default.aspx?tabid=28&year=2004&month=-1&art=51726&PN=On&SearchText=
and software is free ... but not the Scheme !!! ;)
I Committed one w/ 4 Channels ( auto or manual recovering )... but processor is a PIC 16F628 !!!
Alain
Matt Edwards
Nov 14, 2006, 11:48 PM
Thanx for the replies.
Lars
I plan to do two channels only. I will do a single channel if needs be. I buy tiny2313 sub US$1.6. Freaks is always the first place to look. not much help inthis case. I don't understand Assembler well enough to code in it.
Alain,
top reference. It gives the dirtection I wanted. The pseudo code section is excellent.
Cheers
Matt
lajon63
Nov 15, 2006, 05:22 PM
Here is some servo output code in C I have used for tiny2313 (btw, good choice for this since it has the 16 timer).
http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=38601&start=24
/Lars
vBulletin® Copyright ©2000-2009, Jelsoft Enterprises Ltd.