;*********************************************************** ;* * ;* BLMC-Mega-1n1p * ;* * ;* Jan.2006 s.stoecker@gmx.de * ;* * ;* vielen Dank an Bernhard und Karlheinz * ;* * ;* schaut ins Web unter: * ;* http://www.jetcontrol.de/Bastelstube/BLMC/1n1p/1n1p.htm * ;* http://home.versanet.de/~b-konze/ * ;* http://people.freenet.de/khruehlow/ * ;* * ;*********************************************************** .equ FORCE_LIPO = 1 ; 1=Lipo und 0=NC wenn keine Buecke .equ ActiveFreeRun = 1 .equ MOT_BRAKE = 1 ;********************** ;* Motoreinstellungen * ;********************** .equ Motor =1 ; Chipsledde 9n12p 16x0,55Y ;.equ Motor =2 ; mönchweiler ;.equ Motor =3 ; was weiss ich noch fuer einer:-) .equ Use_8_9Grad =0 .equ Use_10_3Grad =0 .equ Use_13_1Grad =1 .equ Use_6_1Grad =0 .equ Use_4_1GRAD =0 .equ Use_15_0Grad =0 .equ Use_22_5Grad =0 ;********************** ;* PORT definitions * ;********************** .equ ApFET_PORT = PORTC .equ AnFET_PORT = PORTD .equ BpFET_PORT = PORTD .equ BnFET_PORT = PORTD .equ CpFET_PORT = PORTC .equ CnFET_PORT = PORTC .equ BRAKE_PORT = PORTD .equ Accu_Port = PORTC .equ LI_Port = PORTB .equ LI_Port_IN = PINB ;********************** ;* PORT D definitions * ;********************** .equ c_comp = 6 ;i common comparator input (AIN0) .equ BpFET = 5 ;o FET Phase B high .equ BnFET = 4 ;o FET Phase B low .equ AnFET = 3 ;o FET Phase A low .equ rcp_in = 2 ;i r/c pulse input .equ txd = 1 ;o uart tx .equ rxd = 0 ;i uart rx .equ INIT_PD = 0 .if RC_PULS == 1 .equ DIR_PD = (1<