Subversion Repositories FlightCtrl

Rev

Blame | Last modification | View Log | RSS feed

This branch v0.68d_J16J17 is a copy of v0.68d and has support for switchting J16 and J17 on the FC board:


DIFFERENCES:

main.c -> line 101:
DDRC changed from 0x81 (128+1) to 0x8D (128+8+4+1) to make PC2 and PC3 outputs

main.h -> lines 22-25:
defined references for PC2 (=LED1) and PC3 (=LED2)

fc.c -> line 605-608:
added switching behaviour based on POTI2 and POTI3
if POTI2 >  75, output PC2 (J16) will switch to ground
if POTI2 <= 75, output PC2 (J16) will remain open collector
if POTI3 >  75, output PC3 (J17) will switch to ground
if POTI3 <= 75, output PC3 (J17) will remain open collector

NOTE on J16/J17 usage:
- use an optocoupler to switch external devices like camera's
- you can drive a LED straight on J16 or J17 (cathode on J16/J17, anode on +5V), but do not exceed 100mA (otherwise 7805 stabiliser gets too hot). T1 and T2 can handle each max. 500mA but mind the 7805 on the FC
- if you want to drive higher currents (for external high power LED's): use an extra FET or a BD transistor (eg: BD138 PNP) via the battery supply (not the +5V from the FC)


Good Luck!
Harrie - MosaKopter