Moved source_fa into trunk
This commit is contained in:
19
Makefile
Normal file
19
Makefile
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# MPLAB IDE generated this makefile for use with GNU make.
|
||||||
|
# Project: firebee1.mcp
|
||||||
|
# Date: Sun Oct 04 21:22:09 2009
|
||||||
|
|
||||||
|
AS = mpasmwin.exe
|
||||||
|
CC = mcc18.exe
|
||||||
|
LD = mplink.exe
|
||||||
|
AR = mplib.exe
|
||||||
|
RM = rm
|
||||||
|
|
||||||
|
firebee1.cof : firebee1.o
|
||||||
|
$(LD) "..\MPASM Suite\LKR\18f4520i.lkr" "firebee1.o" /z__MPLAB_BUILD=1 /o"firebee1.cof" /M"firebee1.map" /W
|
||||||
|
|
||||||
|
firebee1.o : firebee1.asm ../../../Programme/Microchip/MPASM\ Suite/P18f4520.inc
|
||||||
|
"C:\Programme\Microchip\MPASM Suite\MPASMWIN.exe" /q /p18F4520 "firebee1.asm" /l"firebee1.lst" /e"firebee1.err" /o"firebee1.o"
|
||||||
|
|
||||||
|
clean :
|
||||||
|
$(RM) "firebee1.o" "firebee1.ERR" "firebee1.lst" "firebee1.cof" "firebee1.hex"
|
||||||
|
|
||||||
19
NMakefile
Normal file
19
NMakefile
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
# MPLAB IDE generated this makefile for use with Microsoft `nmake'.
|
||||||
|
# Project: firebee1.mcp
|
||||||
|
# Date: Sun Oct 04 21:22:09 2009
|
||||||
|
|
||||||
|
AS = mpasmwin.exe
|
||||||
|
CC = mcc18.exe
|
||||||
|
LD = mplink.exe
|
||||||
|
AR = mplib.exe
|
||||||
|
RM = del
|
||||||
|
|
||||||
|
"firebee1.cof" : "firebee1.o"
|
||||||
|
$(LD) "..\MPASM Suite\LKR\18f4520i.lkr" "firebee1.o" /z__MPLAB_BUILD=1 /o"firebee1.cof" /M"firebee1.map" /W
|
||||||
|
|
||||||
|
"firebee1.o" : "firebee1.asm" "..\..\..\Programme\Microchip\MPASM Suite\P18f4520.inc"
|
||||||
|
"C:\Programme\Microchip\MPASM Suite\MPASMWIN.exe" /q /p18F4520 "firebee1.asm" /l"firebee1.lst" /e"firebee1.err" /o"firebee1.o"
|
||||||
|
|
||||||
|
"clean" :
|
||||||
|
$(RM) "firebee1.o" "firebee1.ERR" "firebee1.lst" "firebee1.cof" "firebee1.hex"
|
||||||
|
|
||||||
619
PS2Atari_v1_4.asm
Normal file
619
PS2Atari_v1_4.asm
Normal file
@@ -0,0 +1,619 @@
|
|||||||
|
;*****************************************************************************
|
||||||
|
; PS2Atari_v1_4.asm *
|
||||||
|
; PS2 PC mouse to Atari / Amiga mouse converter by Tom Kirk March 2010 *
|
||||||
|
; Version 1.3 *
|
||||||
|
;*****************************************************************************
|
||||||
|
; *
|
||||||
|
; Enables a PS2 PC mouse to be used with Atari / Amiga computers using *
|
||||||
|
; the circuit in circuit.bmp with a PIC16F84(A)/C84 micrcontroller. *
|
||||||
|
; *
|
||||||
|
; Assembled using Microchip MPLAB and MPASM. *
|
||||||
|
; Disable case sensitivity under build options. *
|
||||||
|
; *
|
||||||
|
;*****************************************************************************
|
||||||
|
; Version 1.4 July 2010 *
|
||||||
|
; Unused Pin RA4 now correctly set as an imput. *
|
||||||
|
; (Pin is tied to +5V on PCB for easier PCB routing.) *
|
||||||
|
; My oversight when transfering from prototype to PCB. *
|
||||||
|
; Thanks to Luciano for informing me. *
|
||||||
|
; *
|
||||||
|
; Version 1.3 March 2010 *
|
||||||
|
; Corrected a bug in button routine preventing both buttons being active *
|
||||||
|
; together under certain conditions. *
|
||||||
|
; Thanks to Oliver Fleischmann for informing me. *
|
||||||
|
; (Can't believe it taken 6 Years for this bug to show itself!!) *
|
||||||
|
; *
|
||||||
|
; Version 1.2 June 07 *
|
||||||
|
; Changed left/right button outputs to fake open collector. *
|
||||||
|
; Needed to stop conflits when using a joystick pluged into other port. *
|
||||||
|
; *
|
||||||
|
; Version 1.1 August 04 *
|
||||||
|
; Added support for Amiga. *
|
||||||
|
; *
|
||||||
|
;*****************************************************************************
|
||||||
|
|
||||||
|
|
||||||
|
; list directive to define processor
|
||||||
|
list p=16F84A
|
||||||
|
|
||||||
|
; processor specific variable definitions
|
||||||
|
#include <p16F84A.inc>
|
||||||
|
|
||||||
|
; define config bits
|
||||||
|
__CONFIG _CP_OFF & _WDT_OFF & _PWRTE_ON & _XT_OSC
|
||||||
|
|
||||||
|
;4 MHz Clock
|
||||||
|
|
||||||
|
;************************ Input output usage ********************
|
||||||
|
|
||||||
|
; RA0 Atari / Amiga select i/p
|
||||||
|
; RA1 PS2 mouse data
|
||||||
|
; RA2 PS2 mouse clock
|
||||||
|
; RA3 Not used
|
||||||
|
; RA4 Not used
|
||||||
|
|
||||||
|
; RB0 Atari XA / Amiga XA o/p
|
||||||
|
; RB1 Atari XB / Amiga YB o/p
|
||||||
|
; RB2 Atari YA / Amiga YA o/p
|
||||||
|
; RB3 Atari YB / Amiga XB o/p
|
||||||
|
; RB4 Left button o/p
|
||||||
|
; RB5 Right button o/p
|
||||||
|
; RB6 Not used
|
||||||
|
; RB7 Not used
|
||||||
|
|
||||||
|
;*******************************************************************
|
||||||
|
|
||||||
|
|
||||||
|
;********** I/O port equates **************
|
||||||
|
|
||||||
|
|
||||||
|
ps2data equ 1 ;ps2 mouse data signal
|
||||||
|
ps2clk equ 2 ;ps2 mouse clock signal
|
||||||
|
|
||||||
|
|
||||||
|
;********** User register equates *********
|
||||||
|
|
||||||
|
temp equ 0ch ;Temporary storage
|
||||||
|
byte1 equ 0dh ;Byte 1 store
|
||||||
|
byte2 equ 0eh ;Byte 2 store
|
||||||
|
byte3 equ 0fh ;Byte 3 store
|
||||||
|
xinc equ 010h ;last x increment read
|
||||||
|
yinc equ 011h ;last y increment read
|
||||||
|
xlow equ 012h ;low byte of 16 bit x counter
|
||||||
|
xhigh equ 013h ;high byte of 16 bit x counter
|
||||||
|
ylow equ 014h ;low byte of 16 bit y counter
|
||||||
|
yhigh equ 015h ;high byte of 16 bit y counter
|
||||||
|
xpat equ 016h ;x pattern position
|
||||||
|
ypat equ 017h ;y pattern position
|
||||||
|
bcnt equ 018h ;bit counter
|
||||||
|
brec equ 019h ;byte received
|
||||||
|
timer equ 01ah ;timer counter
|
||||||
|
parity equ 01bh ;parity store
|
||||||
|
flag equ 01ch ;flag bits (bit 0 = ack error flag)
|
||||||
|
; (bit 1 = parity error flag)
|
||||||
|
; (bit 2 = middle button pressed flag)
|
||||||
|
; (bit 3 = middle state flag)
|
||||||
|
; (bit 4 = left button flag)
|
||||||
|
|
||||||
|
;*****************************************************************************************
|
||||||
|
|
||||||
|
;***** initialise program *******
|
||||||
|
|
||||||
|
reset clrwdt
|
||||||
|
bcf status,rp0 ;set page0
|
||||||
|
clrf intcon ;disable interupts
|
||||||
|
bsf status,rp0
|
||||||
|
movlw 084h ;set tmr0 to int clk,prescale/32
|
||||||
|
movwf option_reg
|
||||||
|
bcf status,rp0
|
||||||
|
clrf porta ;all porta outputs will be low when enabled
|
||||||
|
movlw 0h ;set mouse buttons and x y start levels
|
||||||
|
movwf portb
|
||||||
|
bsf status,rp0
|
||||||
|
movlw 017h ;set porta bit 3 as an unused output
|
||||||
|
movwf trisa
|
||||||
|
movlw 030h ;set portb bit 4 and 5 as inputs (left/right button o/ps open collector)
|
||||||
|
movwf trisb
|
||||||
|
bcf status,rp0
|
||||||
|
|
||||||
|
clrf byte1 ;set start up values
|
||||||
|
clrf byte2
|
||||||
|
clrf byte3
|
||||||
|
clrf xinc
|
||||||
|
clrf yinc
|
||||||
|
clrf xlow
|
||||||
|
clrf xhigh
|
||||||
|
clrf ylow
|
||||||
|
clrf yhigh
|
||||||
|
clrf xpat
|
||||||
|
clrf ypat
|
||||||
|
clrf flag
|
||||||
|
|
||||||
|
|
||||||
|
;***************** set up ps2 mouse *********************
|
||||||
|
|
||||||
|
|
||||||
|
start call ps2read ;read power up self test report
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0aah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;read power up pc mouse id
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0h ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
restart movlw 0ffh ;send reset pc mouse command
|
||||||
|
call ps2wri
|
||||||
|
btfsc flag,0 ;ack bit?
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;ack returned
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0fah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;read self test report
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0aah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;read pc mouse id
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0h ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
movlw 0f4h ;send enable reporting command
|
||||||
|
call ps2wri
|
||||||
|
btfsc flag,0 ;ack bit?
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;ack returned
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0fah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart
|
||||||
|
|
||||||
|
movlw 0f3h ;send set sample rate command
|
||||||
|
call ps2wri
|
||||||
|
btfsc flag,0 ;ack bit?
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;ack returned
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0fah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart
|
||||||
|
|
||||||
|
movlw 028h ;send sample rate (40)
|
||||||
|
call ps2wri
|
||||||
|
btfsc flag,0 ;ack bit?
|
||||||
|
goto restart ;no so jump
|
||||||
|
|
||||||
|
call ps2read ;ack returned
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movlw 0fah ;correct ?
|
||||||
|
subwf brec,w
|
||||||
|
btfss status,z
|
||||||
|
goto restart
|
||||||
|
|
||||||
|
;******************* Main program loop ****************************
|
||||||
|
|
||||||
|
main call ps2read ;read 3 byte pc mouse packet
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movf brec,w
|
||||||
|
movwf byte1
|
||||||
|
call ps2read
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movf brec,w
|
||||||
|
movwf byte2
|
||||||
|
call ps2read
|
||||||
|
btfsc flag,1 ;parity error?
|
||||||
|
goto restart ;yes so jump
|
||||||
|
movf brec,w
|
||||||
|
movwf byte3
|
||||||
|
|
||||||
|
;adjust the 16 bit x counter
|
||||||
|
|
||||||
|
clrf temp ;use temp as high byte
|
||||||
|
btfsc byte1,4 ;extend sign bit into high byte
|
||||||
|
decf temp,f
|
||||||
|
|
||||||
|
movf byte2,w ;add low bytes
|
||||||
|
addwf xlow,f
|
||||||
|
btfsc status,c ;add carry to high
|
||||||
|
incf xhigh,f
|
||||||
|
movf temp,w ;add high bytes
|
||||||
|
addwf xhigh,f
|
||||||
|
|
||||||
|
;adjust the 16 bit y counter
|
||||||
|
|
||||||
|
clrf temp ;use temp as high byte
|
||||||
|
btfsc byte1,5 ;extend sign bit into high byte
|
||||||
|
decf temp,f
|
||||||
|
|
||||||
|
movf byte3,w ;add low bytes
|
||||||
|
addwf ylow,f
|
||||||
|
btfsc status,c ;add carry to high
|
||||||
|
incf yhigh,f
|
||||||
|
movf temp,w ;add high bytes
|
||||||
|
addwf yhigh,f
|
||||||
|
|
||||||
|
;left button
|
||||||
|
|
||||||
|
btfss byte1,0 ;is the left pc mouse button pressed
|
||||||
|
goto lbutt ;no so jump
|
||||||
|
bsf flag,4 ;set left button flag
|
||||||
|
goto nbutt
|
||||||
|
lbutt bcf flag,4 ;reset left button flag
|
||||||
|
|
||||||
|
;right button
|
||||||
|
|
||||||
|
nbutt btfss byte1,1 ;is the right pc mouse button pressed
|
||||||
|
goto rbutt ;no so jump
|
||||||
|
bcf portb,5 ;set right button as pressed
|
||||||
|
bsf status,rp0 ;by setting pin as a low output
|
||||||
|
bcf trisb,5
|
||||||
|
bcf status,rp0
|
||||||
|
goto mbut
|
||||||
|
rbutt bsf status,rp0 ;set right button as not pressed
|
||||||
|
bsf trisb,5 ;by setting pin as an input
|
||||||
|
bcf status,rp0
|
||||||
|
|
||||||
|
;middle button
|
||||||
|
|
||||||
|
mbut btfss byte1,2 ;check if middle button pressed
|
||||||
|
goto mbutt ;jump if not
|
||||||
|
btfsc flag,2 ;check middle button pressed flag
|
||||||
|
goto mbex ;set so jump
|
||||||
|
movlw 08h ;toggle middle state flag
|
||||||
|
xorwf flag,f
|
||||||
|
bsf flag,2 ;set middle button pressed flag
|
||||||
|
goto mbex
|
||||||
|
|
||||||
|
mbutt btfss flag,2
|
||||||
|
goto mbex
|
||||||
|
bcf flag,2 ;reset middle button pressed flag
|
||||||
|
mbex
|
||||||
|
|
||||||
|
btfsc flag,3 ;check middle state flag
|
||||||
|
goto setlb ;jump if set
|
||||||
|
btfsc flag,4 ;check left button flag
|
||||||
|
goto setlb ;jump if set
|
||||||
|
bsf status,rp0 ;no flags set so set left buuton not pressed
|
||||||
|
bsf trisb,4 ;by setting pin as an input
|
||||||
|
bcf status,rp0
|
||||||
|
goto main
|
||||||
|
setlb bcf portb,4 ;set left button pressed
|
||||||
|
bsf status,rp0 ;by setting pin as a low output
|
||||||
|
bcf trisb,4
|
||||||
|
bcf status,rp0
|
||||||
|
goto main
|
||||||
|
|
||||||
|
|
||||||
|
;***************************** Subs *****************************************
|
||||||
|
|
||||||
|
;***** Read a byte from the ps2 mouse ******
|
||||||
|
|
||||||
|
ps2read btfss porta,ps2data ;data low ?
|
||||||
|
goto ps2r1 ;yes so start reading data
|
||||||
|
call trans ;no so do emulated mouse move
|
||||||
|
clrf tmr0 ;clear rtcc before delay
|
||||||
|
|
||||||
|
oned btfss porta,ps2data ;data low ?
|
||||||
|
goto ps2r1 ;yes so start reading data
|
||||||
|
movlw 0dh ;delay between emulated mouse moves
|
||||||
|
subwf tmr0,w
|
||||||
|
btfss status,z
|
||||||
|
goto oned ;not done so jump
|
||||||
|
goto ps2read ;check again
|
||||||
|
|
||||||
|
ps2r1 call wlow ;wait until clock goes low for start bit
|
||||||
|
|
||||||
|
call whigh ;wait until clock is high
|
||||||
|
|
||||||
|
movlw 08h ;read 8 data bits
|
||||||
|
movwf bcnt
|
||||||
|
clrf parity ;clear parity counter
|
||||||
|
|
||||||
|
ps2r2 call wlow ;wait until clock is low
|
||||||
|
bcf status,c ;clear carry flag
|
||||||
|
btfss porta,ps2data ;data bit set ?
|
||||||
|
goto ps2r3 ;no so jump
|
||||||
|
incf parity,f ;yes so inc the parity counter
|
||||||
|
bsf status,c ;set carry bit
|
||||||
|
ps2r3 rrf brec,f ;shift carry into destination
|
||||||
|
|
||||||
|
call whigh ;wait until clock is high
|
||||||
|
|
||||||
|
decfsz bcnt,f ;finished the 8 bits?
|
||||||
|
goto ps2r2 ;no so do again
|
||||||
|
|
||||||
|
call wlow ;for the parity bit
|
||||||
|
btfsc porta,ps2data ;parity bit set?
|
||||||
|
incf parity,f ;yes so inc the parity counter
|
||||||
|
bcf flag,1 ;clear flag (no error)
|
||||||
|
btfss parity,0 ;check calculated parity
|
||||||
|
bsf flag,1 ;set flag (parity error!)
|
||||||
|
call whigh
|
||||||
|
|
||||||
|
call wlow ;for the stop bit
|
||||||
|
call whigh
|
||||||
|
|
||||||
|
return ;and exit
|
||||||
|
|
||||||
|
;***** Write a byte to the ps2 mouse ******
|
||||||
|
|
||||||
|
ps2wri movwf brec ;speed not important at this point so
|
||||||
|
movwf temp ;calculate parity seperate for sake of
|
||||||
|
movlw 08h ;clarity
|
||||||
|
movwf bcnt
|
||||||
|
clrf parity
|
||||||
|
ps2w1 rrf temp,f ;shift bit into carry
|
||||||
|
movlw 01h ;preset for bit set
|
||||||
|
btfss status,c ;test carry
|
||||||
|
clrw ;bit zero so no addition
|
||||||
|
addwf parity,f ;update parity
|
||||||
|
decfsz bcnt,f ;any more bits to do?
|
||||||
|
goto ps2w1 ;yes so jump
|
||||||
|
comf parity,f ;only intrested in bit 0.
|
||||||
|
;parity bit is complement of bit 0
|
||||||
|
|
||||||
|
movlw 08h ;bit count to 8
|
||||||
|
movwf bcnt
|
||||||
|
|
||||||
|
call clkl ;set clock low
|
||||||
|
|
||||||
|
movlw 021h ;wait 100 uS
|
||||||
|
movwf temp
|
||||||
|
ps2ww decfsz temp,f
|
||||||
|
goto ps2ww
|
||||||
|
|
||||||
|
call datl ;set data low
|
||||||
|
nop ;wait 5 uS
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
nop
|
||||||
|
call clkh ;set clock high
|
||||||
|
|
||||||
|
ps2w2 call wlow ;wait for clock to go low
|
||||||
|
rrf brec,f ;rotate bit into carry for testing
|
||||||
|
btfss status,c
|
||||||
|
goto ps2w3 ;jump if bit is low
|
||||||
|
call dath ;set data high
|
||||||
|
goto ps2w4
|
||||||
|
ps2w3 call datl ;set data low
|
||||||
|
ps2w4 call whigh ;wait for clock to go high
|
||||||
|
|
||||||
|
decfsz bcnt,f ;any more bits to send?
|
||||||
|
goto ps2w2 ;yes so jump
|
||||||
|
|
||||||
|
call wlow ;wait for clock to go low
|
||||||
|
btfss parity,0 ;send parity bit
|
||||||
|
goto ps2w5
|
||||||
|
call dath
|
||||||
|
goto ps2w6
|
||||||
|
ps2w5 call datl
|
||||||
|
ps2w6 call whigh
|
||||||
|
|
||||||
|
call wlow ;send stop bit
|
||||||
|
call dath
|
||||||
|
call whigh
|
||||||
|
|
||||||
|
call wlow ;read ack from mouse
|
||||||
|
bcf flag,0
|
||||||
|
btfsc porta,ps2data
|
||||||
|
bsf flag,0
|
||||||
|
call whigh
|
||||||
|
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* wait for ps2 clock to go low **********
|
||||||
|
|
||||||
|
wlow btfsc porta,ps2clk
|
||||||
|
goto wlow
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* wait for ps2 clock to go high **********
|
||||||
|
|
||||||
|
whigh btfss porta,ps2clk
|
||||||
|
goto whigh
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* set ps2 clock low *********************
|
||||||
|
|
||||||
|
clkl bsf status,rp0
|
||||||
|
bcf trisa,ps2clk
|
||||||
|
bcf status,rp0
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* set ps2 clock high ********************
|
||||||
|
|
||||||
|
clkh bsf status,rp0
|
||||||
|
bsf trisa,ps2clk
|
||||||
|
bcf status,rp0
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* set ps2 data low *********************
|
||||||
|
|
||||||
|
datl bsf status,rp0
|
||||||
|
bcf trisa,ps2data
|
||||||
|
bcf status,rp0
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;******* set ps2 data high *********************
|
||||||
|
|
||||||
|
dath bsf status,rp0
|
||||||
|
bsf trisa,ps2data
|
||||||
|
bcf status,rp0
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
;********* emulate mouse move ***************************
|
||||||
|
|
||||||
|
;move the emulated mouse by one step in the x direction if needed
|
||||||
|
|
||||||
|
trans movf xlow,w ;is the x counter zero?
|
||||||
|
iorwf xhigh,w
|
||||||
|
btfsc status,z
|
||||||
|
goto ymove ;no so jump to y direction
|
||||||
|
|
||||||
|
btfsc xhigh,7 ;is the x counter positive or negative?
|
||||||
|
goto xneg ;jump if negative
|
||||||
|
|
||||||
|
incf xpat,f ;increment the pattern list position
|
||||||
|
movlw 04h ;test if end of pattern list
|
||||||
|
subwf xpat,w
|
||||||
|
btfsc status,z
|
||||||
|
clrf xpat ;end of pattern list so reset
|
||||||
|
movlw 0ffh ;subtract 1 from the 16 bit counter by adding ffffh
|
||||||
|
addwf xlow,f
|
||||||
|
btfsc status,c ;add carry to high byte
|
||||||
|
incf xhigh,f
|
||||||
|
addwf xhigh,f
|
||||||
|
goto ymove ;exit to y direction
|
||||||
|
|
||||||
|
xneg decf xpat,f ;decrement the pattern list position
|
||||||
|
movlw 0ffh ;test if end of pattern list
|
||||||
|
subwf xpat,w
|
||||||
|
btfss status,z
|
||||||
|
goto xno
|
||||||
|
movlw 03h ;end of pattern list so reset
|
||||||
|
movwf xpat
|
||||||
|
xno movlw 01h ;add 1 to the 16 bit counter
|
||||||
|
addwf xlow,f
|
||||||
|
btfsc status,c ;add carry to high byte
|
||||||
|
incf xhigh,f
|
||||||
|
|
||||||
|
;move the emulated mouse by one step in the y direction if needed
|
||||||
|
|
||||||
|
ymove movf ylow,w ;is the y counter zero?
|
||||||
|
iorwf yhigh,w
|
||||||
|
btfsc status,z
|
||||||
|
goto out ;no so jump to output pattern
|
||||||
|
|
||||||
|
btfsc yhigh,7 ;is the y counter positive or negative?
|
||||||
|
goto yneg ;jump if negative
|
||||||
|
|
||||||
|
incf ypat,f ;increment the pattern list position
|
||||||
|
movlw 04h ;test if end of pattern list
|
||||||
|
subwf ypat,w
|
||||||
|
btfsc status,z
|
||||||
|
clrf ypat ;end of pattern list so reset
|
||||||
|
movlw 0ffh ;subtract 1 from the 16 bit counter by adding ffffh
|
||||||
|
addwf ylow,f
|
||||||
|
btfsc status,c ;add carry to high byte
|
||||||
|
incf yhigh,f
|
||||||
|
addwf yhigh,f
|
||||||
|
goto out ;exit to output pattern
|
||||||
|
|
||||||
|
yneg decf ypat,f ;decrement the pattern list position
|
||||||
|
movlw 0ffh ;test if end of pattern list
|
||||||
|
subwf ypat,w
|
||||||
|
btfss status,z
|
||||||
|
goto yno
|
||||||
|
movlw 03h ;end of pattern list so reset
|
||||||
|
movwf ypat
|
||||||
|
yno movlw 01h ;add 1 to the 16 bit counter
|
||||||
|
addwf ylow,f
|
||||||
|
btfsc status,c ;add carry to high byte
|
||||||
|
incf yhigh,f
|
||||||
|
|
||||||
|
;output new x and y patterns
|
||||||
|
|
||||||
|
out btfsc porta,0 ;test if set for atari
|
||||||
|
goto amiga
|
||||||
|
|
||||||
|
movf xpat,w ;get the x pattern bits
|
||||||
|
bsf pclath,1 ;set page 2
|
||||||
|
call pattx
|
||||||
|
movwf temp ;store the pattern in temp
|
||||||
|
movf ypat,w ;get the y pattern bits
|
||||||
|
call patty
|
||||||
|
clrf pclath ;set page 0
|
||||||
|
iorwf temp,f ;store the pattern in temp
|
||||||
|
|
||||||
|
goto outpat
|
||||||
|
|
||||||
|
amiga movf xpat,w ;get the x pattern bits
|
||||||
|
bsf pclath,1 ;set page 2
|
||||||
|
call apatx
|
||||||
|
movwf temp ;store the pattern in temp
|
||||||
|
movf ypat,w ;get the y pattern bits
|
||||||
|
call apaty
|
||||||
|
clrf pclath ;set page 0
|
||||||
|
iorwf temp,f ;store the pattern in temp
|
||||||
|
|
||||||
|
outpat movf temp,w ;get patterns
|
||||||
|
andlw 0fh ;ensure high nibble stays zero
|
||||||
|
movwf portb ;ouput patterns
|
||||||
|
|
||||||
|
|
||||||
|
return
|
||||||
|
|
||||||
|
|
||||||
|
;*************** pattern lists **************
|
||||||
|
|
||||||
|
org 0200h
|
||||||
|
|
||||||
|
;atari patterns
|
||||||
|
pattx addwf pcl,f
|
||||||
|
retlw 0
|
||||||
|
retlw 1
|
||||||
|
retlw 3
|
||||||
|
retlw 2
|
||||||
|
|
||||||
|
patty addwf pcl,f
|
||||||
|
retlw 0
|
||||||
|
retlw 4
|
||||||
|
retlw 0ch
|
||||||
|
retlw 8
|
||||||
|
|
||||||
|
;amiga patterns
|
||||||
|
apatx addwf pcl,f
|
||||||
|
retlw 0
|
||||||
|
retlw 1
|
||||||
|
retlw 9
|
||||||
|
retlw 8
|
||||||
|
|
||||||
|
apaty addwf pcl,f
|
||||||
|
retlw 0
|
||||||
|
retlw 4
|
||||||
|
retlw 6
|
||||||
|
retlw 2
|
||||||
|
|
||||||
|
;*******************************************************************************
|
||||||
|
|
||||||
|
END
|
||||||
|
|
||||||
|
|
||||||
BIN
circuit.bmp
Normal file
BIN
circuit.bmp
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 31 KiB |
845
firebee1.asm
Normal file
845
firebee1.asm
Normal file
@@ -0,0 +1,845 @@
|
|||||||
|
;**********************************************************
|
||||||
|
;* firebee1 PIC18F4321 MAIN FILE
|
||||||
|
;**********************************************************
|
||||||
|
;* CREATED BY FREDI ASCHWANDEN
|
||||||
|
;* DATE 22.9.2009
|
||||||
|
;**********************************************************
|
||||||
|
list PE=18f4520 ;EXTENDED INSTRUCTION SET
|
||||||
|
include "P18f4520.inc"
|
||||||
|
;------------------------ Equates --------------------------;
|
||||||
|
;Register addresses
|
||||||
|
;BANK 0
|
||||||
|
SECS equ 0x00
|
||||||
|
SECS_ALARM EQU 0x01
|
||||||
|
MINS equ 0x02
|
||||||
|
MINS_ALRAM EQU 0x03
|
||||||
|
HOURS equ 0x04
|
||||||
|
HOURS_ALARM EQU 0x05
|
||||||
|
DAY_OF_WEEK EQU 0x06
|
||||||
|
DAYS EQU 0x07
|
||||||
|
MONTHS EQU 0x08
|
||||||
|
YEARS EQU 0x09 ;offset vom 1968
|
||||||
|
REGA EQU 0x0A
|
||||||
|
REGB EQU 0x0B
|
||||||
|
REGC EQU 0x0C
|
||||||
|
REGD EQU 0x0D
|
||||||
|
RTC_RAM EQU 0x0E ; bis 0x3F
|
||||||
|
free equ 0x40
|
||||||
|
TICKS equ 0x41 ;125MS
|
||||||
|
TASTE_ON_TIME EQU 0x42
|
||||||
|
TASTE_OFF_TIME EQU 0x43
|
||||||
|
POWER_ON_TIME EQU 0x44
|
||||||
|
AD_KANAL EQU 0x45
|
||||||
|
U_ERR EQU 0x46 ;SPANNUNGSFEHLER WENN BIT 0=1, BIT1=1 WARTEN AUF GELADEN
|
||||||
|
U_ERR_TIME EQU 0x47 ;ZEIT SEIT SPANNUNGSFEHLER
|
||||||
|
U_POWER_IN EQU 0x48 ;SPANNUNG POWER IN 1V CA. 6E
|
||||||
|
RX_B EQU 0x49 ;RECEIVED BYT
|
||||||
|
RX_STATUS EQU 0x4A ;STATUS: 0x00=WAIT AUF MCF COMMANDO, 0x82=EMPFANGE 64BYT FROM RTC
|
||||||
|
TX_STATUS EQU 0x4B ;STATUS: 0x00=WAIT 0x81=SENDE 64BYT FROM RTC
|
||||||
|
GO_SUB EQU 0x4C ;WENN GLEICH 0xFB DANN SUBROUTINE AUSF<53>HREN
|
||||||
|
GO_INT EQU 0x4D ;WENN GLEICH 0xFB DANN SUBROUTINE AUSF<53>HREN
|
||||||
|
EAPIR1 EQU 0x4E ;INTERRUPT ACTIV UND ENABLE
|
||||||
|
EAPIR2 EQU 0x4F ;INTERRUPT ACTIV UND ENABLE
|
||||||
|
;BANK 1 AB 0x100
|
||||||
|
RX_BUFFER EQU 0x100 ;0x80 BYT BUFFER BIS 0x17F BANK
|
||||||
|
TX_BUFFER EQU 0x180 ;0X80 BYT BUFFER BIS 0x1FF BANK
|
||||||
|
|
||||||
|
;--------------------------------------------------------------
|
||||||
|
SEND_RTC_TIME EQU .2 ;0.25 SEC (EINHEIT IST EIN TICK = 128MS
|
||||||
|
RESET_ON_TIME EQU .2 ;0.25 SEC (EINHEIT IST EIN TICK = 128MS
|
||||||
|
RESET_OFF_TIME EQU .4 ;0.5 SEC (EINHEIT IST EIN TICK = 128MS
|
||||||
|
OFF_TIME EQU .20 ;2.5 SEC (EINHEIT IST EIN TICK = 128MS
|
||||||
|
ON_TIME EQU .2 ;0.25 SEC (EINHEIT IST EIN TICK = 128MS
|
||||||
|
TIMER_HB EQU .240 ;256- (32768Hz PRO 1/8SEC = 4096TICKS/256) => 256-16=240 (resp 256-16/4 (wenn osco) = 252)
|
||||||
|
TIME_MAX EQU .160 ;MAXIMALTIME
|
||||||
|
U_ERR_PW_AUS EQU .5 ;5 SEC
|
||||||
|
;SERIEL
|
||||||
|
SYNC1 EQU 0FFh
|
||||||
|
SYNC1_DATA EQU 'A';
|
||||||
|
SYNC2 EQU 0FEh
|
||||||
|
SYNC2_DATA EQU 'C';
|
||||||
|
SYNC3 EQU 0FDh
|
||||||
|
SYNC3_DATA EQU 'P';
|
||||||
|
SYNC4 EQU 0FCh
|
||||||
|
SYNC4_DATA EQU 'F';
|
||||||
|
REQ_RTCD_FROM_PIC EQU 01h ;RTC AND NVRAM DATEN VOM PIC ANFORDERN
|
||||||
|
RTCD_FROM_PIC EQU 81h ;RTC AND NVRAM DATEN HEADER UND STATUS
|
||||||
|
REQ_RTCD_FROM_MCF EQU 02h ;RTC AND NVRAM DATEN VOM MCF ANFORDERN
|
||||||
|
RTCD_FROM_MCF EQU 82h ;RTC AND NVRAM DATEN HEADER UND STATUS
|
||||||
|
U_MIN_TO_MCF EQU 03h ;UNTERSPANNUNGSMITTEILUNG AN PROCESSOR
|
||||||
|
EXT_SUB_GO EQU 04h ;SERIELL CODE UM SUBROUTINEN/INTERRUPTS ZU AKTIVIEREN
|
||||||
|
EXT_SUB_STOP EQU 05h ;SERIELL CODE UM SUBROUTINEN/INTERRUPTS ZU STOPPEN
|
||||||
|
CLK_SLEEP EQU B'00010010' ;125kHz intern, SLEEP MODE
|
||||||
|
CLK_ACTIV EQU B'01110010' ;inTernal CLK=8MHz, SLEEP MODE, SLEEP MODE
|
||||||
|
EXT_CODE EQU 0xFB ;CODE F<>R EXTERNE SUBROUTINEN/INTERRUPTS AUSF<53>HREN (FireBee!)
|
||||||
|
EXTERN_INT_ADR EQU 0x2000 ;HIER MUSS 0xFB STEHEN WENN EXTERNE INTERRUPTS AUSF<53>HRBAR
|
||||||
|
EXTERN_INTERRUPTS EQU 0x2002 ;STARTPUNKT EXTERNE SUBROUTINES
|
||||||
|
EXTERN_SUB_ADR EQU 0x2010 ;HIER MUSS 0xFB STEHEN WENN EXTERNE SUBROUTINES AUSF<53>HRBAR
|
||||||
|
EXTERN_SUBROUTINES EQU 0x2012 ;STARTPUNKT EXTERNE SUBROUTINES
|
||||||
|
REQ_BLOCK EQU 0xA0 ;BLOCK DATEN LESEN -> CODE UND 3 BYTS ADRESSE = TOTAL 4 BYTES
|
||||||
|
READ_BLOCK EQU 0xA1 ;PROGRAMM BLOCK PIC->MCF -> CODE, 3 BYTS ADRESSE UND 64 BYTS DATEN = TOTAL 68 BYTES
|
||||||
|
WRITE_BLOCK EQU 0xA2 ;PROGRAMM BLOCK MCF->PIC -> CODE, 3 BYTS ADRESSE UND 64 BYTS DATEN = TOTAL 68 BYTES
|
||||||
|
PRG_OK_PIC EQU 0x22 ;PROGRAMMIERUNG BLOCK FERTIG
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
; Start at the reset vector
|
||||||
|
Reset_Vector code 0x000
|
||||||
|
BRA KALT_START
|
||||||
|
;--------------------------------------------------------------
|
||||||
|
HIGH_INT_VEC code 0x0008
|
||||||
|
GOTO 0x18
|
||||||
|
|
||||||
|
LOW_INT_VEC code 0x0018
|
||||||
|
INT_HANDLER
|
||||||
|
CLRF BSR ;IMMER ACCESS BANK
|
||||||
|
;SETZEN GRUPPE 1
|
||||||
|
MOVFF PIE1,EAPIR1 ;INTERRUPTS HOLEN
|
||||||
|
MOVF PIR1,0 ;MASKE
|
||||||
|
ANDWF EAPIR1 ;ACTIVE SETZEN
|
||||||
|
BTFSC EAPIR1,TMR1IF ;uhr interrupt?
|
||||||
|
BRA RTC_ISR ;ja->
|
||||||
|
BTFSC EAPIR1,ADIF ;AD INTERRUTP?
|
||||||
|
BRA AD_ISR ;JA->
|
||||||
|
BTFSC EAPIR1,TXIF ;seriell TX?
|
||||||
|
BRA TX_ISR ;JA->
|
||||||
|
BTFSC EAPIR1,RCIF ;seriell RX?
|
||||||
|
BRA RX_ISR ;JA->
|
||||||
|
|
||||||
|
;SETZEN GRUPPE 2
|
||||||
|
MOVFF PIE2,EAPIR2 ;INTERRUPTS HOLEN
|
||||||
|
MOVF PIR2,0 ;MASKE
|
||||||
|
ANDWF EAPIR2 ;ACTIVE SETZEN
|
||||||
|
|
||||||
|
BTFSC EAPIR2,HLVDIF ;UNDER/OVERVOLTAGE DETECT
|
||||||
|
BRA HLVD_ISR ;JA->
|
||||||
|
RETFIE
|
||||||
|
|
||||||
|
;TESTEN UND SETZEN GRUPPE 1
|
||||||
|
MOVFF PIE1,EAPIR1 ;INTERRUPTS HOLEN
|
||||||
|
MOVF PIR1,0 ;MASKE
|
||||||
|
ANDWF EAPIR1 ;ACTIVE SETZEN
|
||||||
|
TSTFSZ EAPIR1
|
||||||
|
BRA INT_HANDLER
|
||||||
|
;TESTEN UND SETZEN GRUPPE 2
|
||||||
|
MOVFF PIE2,EAPIR2 ;INTERRUPTS HOLEN
|
||||||
|
MOVF PIR2,0 ;MASKE
|
||||||
|
ANDWF EAPIR2 ;ACTIVE SETZEN
|
||||||
|
TSTFSZ EAPIR2
|
||||||
|
BRA INT_HANDLER
|
||||||
|
|
||||||
|
MOVLW EXT_CODE ;GO EXTERNE SUBROUTINEN AKTIV?
|
||||||
|
CPFSEQ GO_INT ;SKIP WENN JA
|
||||||
|
RETFIE
|
||||||
|
GOTO EXTERN_INTERRUPTS ;REGISTER SICHERN UND STARTEN
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
; Start application beyond vector area
|
||||||
|
CODE 0x0100
|
||||||
|
KALT_START
|
||||||
|
;RESET MODE
|
||||||
|
CLRF BSR ;BANK 0
|
||||||
|
;ALLE INT AUS UND R<>CKSETZEN
|
||||||
|
CLRF INTCON ;alle INTERRUPT AUS
|
||||||
|
CLRF RCON ;INT PRIORITY AUS
|
||||||
|
CLRF PIE1 ;MASK DISABLE
|
||||||
|
CLRF PIE2
|
||||||
|
CLRF PIR1 ;INT ACT AUS
|
||||||
|
CLRF PIR2
|
||||||
|
CLRF IPR1 ;LOW PRIORITY
|
||||||
|
CLRF IPR2
|
||||||
|
; clock
|
||||||
|
; MOVLW B'01000000' ;32MHZ
|
||||||
|
; MOVWF OSCTUNE
|
||||||
|
CLRF OSCTUNE
|
||||||
|
;CLOCK
|
||||||
|
MOVLW CLK_ACTIV
|
||||||
|
MOVWF OSCCON
|
||||||
|
; div init
|
||||||
|
;SET PORT A: **7:#master/0.409*5V0 **6:PIC_AMKB_RX **5:PIC_SWTICH **4:HIGH_CHARGE_CURRENT **3:2V5 *2:3V3/2 **1:1V25 **0:POWER_IN/11
|
||||||
|
CLRF PORTA ;#master(7)=0, REST=0
|
||||||
|
MOVLW B'11111111' ;DIRECTION: alles auf Input
|
||||||
|
MOVWF TRISA
|
||||||
|
;SET PORT B: **7:PGD **6:PGC **5:PGM **4:PIN_INT,1V5 **3:GAME PORT PIN10 **2:GAME PORT PIN11 **1:GAME PORT PIN6 **0: GAME PORT PIN5
|
||||||
|
CLRF PORTB ;ALLES AUF 0
|
||||||
|
MOVWF TRISB
|
||||||
|
;SET PORT C: **7: PIC_RX **6:PIC_TX **5:AMKB_TX **4:GAME PORT PIN4 **3:GAME PORT PIN12 **2:GAME PORT PIN13 **1+0: OCS 32K768Hz
|
||||||
|
CLRF PORTC
|
||||||
|
MOVWF TRISC
|
||||||
|
;SET PORT D: **7:#RSTI **6:GAME PORT PIN3 **5:PS2 KB CLK **4:PS2 MS CLK **3:PS2 KB DATA **2:MS DATA **1:TASTER **0:POWER ON/OFF (0=ON)
|
||||||
|
; SET TASTE UND POWER
|
||||||
|
CLRF PORTD ;ALLES AUF 0
|
||||||
|
MOVWF TRISD ;ALLES AUF INPUT
|
||||||
|
;SET PORT E: **3:#MCLR **2:#PCI_RESET **1:PCI 3V3 **0:PIC LED (0=ON)
|
||||||
|
MOVLW B'00000001' ;LED OFF
|
||||||
|
CLRF PORTE ;ALLES AUF 0
|
||||||
|
MOVWF TRISE ;ALLES AUF INPUT
|
||||||
|
;--------------------------
|
||||||
|
; set OVERvoltage detekt
|
||||||
|
MOVLW B'10011011' ;INT WENN <20>BER 3.9V
|
||||||
|
MOVWF HLVDCON
|
||||||
|
MOVLW B'00000011' ;ERRORS ON, WAIT AUF LADEN
|
||||||
|
MOVWF U_ERR
|
||||||
|
MOVLW .20 ;SEIT 20SEC ERROR
|
||||||
|
MOVWF U_ERR_TIME ;SETZEN
|
||||||
|
BSF PIE2,HLVDIE ;Enable interrupt
|
||||||
|
;INTIALISIERUNGSPROGAMME
|
||||||
|
CALL LADESTROM ;LADESTROM EINSTELLEN
|
||||||
|
;UHR initialisieren
|
||||||
|
MOVLW TIMER_HB ;Preload TMR1 register
|
||||||
|
MOVWF TMR1H ;
|
||||||
|
CLRF TMR1L ;=0
|
||||||
|
MOVLW B'00001111' ; 8 BIT, osc1 enable, TIMER MODE, TIMMER ENABLE
|
||||||
|
MOVWF T1CON ; SET
|
||||||
|
CLRF TICKS ; 1/8 sec register
|
||||||
|
CLRF SECS ; Initialize timekeeping registers
|
||||||
|
CLRF MINS ;
|
||||||
|
MOVLW .12
|
||||||
|
MOVWF HOURS
|
||||||
|
MOVLW .1
|
||||||
|
MOVWF DAY_OF_WEEK
|
||||||
|
MOVLW .1
|
||||||
|
MOVWF DAYS
|
||||||
|
MOVLW .8
|
||||||
|
MOVWF MONTHS
|
||||||
|
MOVLW .42
|
||||||
|
MOVWF YEARS ;MONTAG 19.7.2010 12:00:00 (JAHR-1968)
|
||||||
|
CLRF TASTE_ON_TIME
|
||||||
|
CLRF TASTE_OFF_TIME
|
||||||
|
CLRF POWER_ON_TIME
|
||||||
|
BSF PIE1,TMR1IE ;Enable Timer1 interrupt
|
||||||
|
;AD WANDLER INITIALISIEREN
|
||||||
|
CLRF AD_KANAL ;BEI 0 BEGINNEN
|
||||||
|
CLRF ADCON0 ;AD MOUDUL AUS
|
||||||
|
MOVLW B'00001001' ;VREF=VDD,ANALOG INPUT AN0-AN5
|
||||||
|
MOVWF ADCON1
|
||||||
|
MOVLW B'00000000' ;LINKSSB<53>NDIG,0 TAD,CLOCK=Fosc/2
|
||||||
|
MOVWF ADCON2
|
||||||
|
; BSF PIE1,ADIE ;INTERRUPT ENABLE
|
||||||
|
CLRF U_POWER_IN ;WERT AUF 0 VOLT
|
||||||
|
; seriell initialisieren
|
||||||
|
CLRF SPBRGH
|
||||||
|
MOVLW .16
|
||||||
|
MOVWF SPBRG ;BAUDE RATE = 115K
|
||||||
|
MOVLW B'00000100' ;TX AUS, ASYNC HIGH SPEED
|
||||||
|
MOVWF TXSTA
|
||||||
|
MOVLW B'10010000' ;SERIEL EIN,RX EIN,
|
||||||
|
MOVWF RCSTA
|
||||||
|
MOVLW B'00001000' ;16BIT BRG, RISING EDGE INTERRUPT
|
||||||
|
MOVWF BAUDCON ;SETZEN
|
||||||
|
;EXTERNER SUBROUTINES
|
||||||
|
CLRF GO_SUB
|
||||||
|
; interrupts
|
||||||
|
CLRF INTCON3 ;EXTER INTERRUPT AUS, low priority
|
||||||
|
MOVLW B'11110000' ;PORT B PULLUPS AUS, EXT INT ON RISING EDGE, TMR0 AND BPIP Low priority
|
||||||
|
MOVWF INTCON2
|
||||||
|
MOVLW B'11000000' ;global on, PERIPHERAL INT on
|
||||||
|
MOVWF INTCON
|
||||||
|
;CLOCK
|
||||||
|
MOVLW CLK_SLEEP ;GEHT JETZT IN SLEEP MODE
|
||||||
|
MOVWF OSCCON
|
||||||
|
;-------------------------------------------------------------------------
|
||||||
|
;---------------------------- MAIN LOOP -------------------------------------------------
|
||||||
|
;-------------------------------------------------------------------------
|
||||||
|
MAIN
|
||||||
|
MOVLW EXT_CODE ;GO EXTERNE SUBROUTINEN AKTIV?
|
||||||
|
CPFSEQ GO_SUB ;SKIP WENN JA
|
||||||
|
BRA WARTEN ;SONST WARTEN
|
||||||
|
CALL MAIN2,1 ;REGISTER SICHERN UND STARTEN
|
||||||
|
WARTEN
|
||||||
|
BTFSC TRISD,RD0 ;SKIP IF POWER ON
|
||||||
|
SLEEP ;SLEPP BIS ZUM N<>CHSTEN INTERRUPT
|
||||||
|
BRA MAIN
|
||||||
|
MAIN2
|
||||||
|
CALL EXTERN_SUBROUTINES ;EXTERNE SUBROUTINEN AUSF<53>HREN AN STELLE 0 MUSS 0xFA STEHEN SONST UNG<4E>LTIG
|
||||||
|
RETURN 1 ;RETURN MIT REGISTER ZUR<55>CK
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;--------------------------- subroutines -------------------------------------------------
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;POWER ON/OFF
|
||||||
|
POWER_EIN
|
||||||
|
;CLOCK
|
||||||
|
MOVLW CLK_ACTIV
|
||||||
|
MOVWF OSCCON
|
||||||
|
|
||||||
|
BCF TRISA,RA7 ;CLOCK EINSCHALTEN
|
||||||
|
BCF TRISD,RD7 ;#RSTI AKTIVIEREN = LOW
|
||||||
|
BCF TRISB,RB4 ;PIC_INT AKTIVIEREN
|
||||||
|
BCF TRISD,RD0 ;POWER ON
|
||||||
|
BRA LS_ON_POWER ;LADESTROM EINSTELLEN
|
||||||
|
POWER_AUS
|
||||||
|
;CLOCK
|
||||||
|
MOVLW CLK_SLEEP
|
||||||
|
MOVWF OSCCON
|
||||||
|
|
||||||
|
BSF TRISD,RD0 ;POWER OFF
|
||||||
|
BSF TRISD,RD7 ;#RSTI DEAKTIVIEREN
|
||||||
|
BSF TRISB,RB4 ;PIC INT DEAKTIVIEREN
|
||||||
|
BSF TRISA,RA7 ;CLOCK DEAKTIVIEREN
|
||||||
|
CLRF POWER_ON_TIME ;R<>CKSETZEN
|
||||||
|
BRA LS_OFF_POWER ;LADESTROM EINSTELLEN
|
||||||
|
;LADESTROM EINSTELLEN ----------------------------
|
||||||
|
LADESTROM
|
||||||
|
BTFSC TRISD,RD0 ; ONPOWER?
|
||||||
|
BRA LS_OFF_POWER ; NEIN->
|
||||||
|
LS_ON_POWER ;GROSSER LADESTROM 5A
|
||||||
|
BCF TRISA,RA4 ;10K ON
|
||||||
|
RETURN
|
||||||
|
LS_OFF_POWER ;KLEINER LADESTROM_MIN 1.85A
|
||||||
|
BSF TRISA,RA4 ;10K OFF
|
||||||
|
RETURN
|
||||||
|
;---------------------------------------------------
|
||||||
|
;SERIELL AUS/EIN
|
||||||
|
SERIAL_OFF
|
||||||
|
BCF TXSTA,TXEN ;TX AUS
|
||||||
|
BCF PIE1,RCIE ;DISABLE RX interrupt
|
||||||
|
BCF PIR1,RCIF ;CLEAR RX interrupt
|
||||||
|
BCF PIE1,TXIE ;DISABLE TX interrupt
|
||||||
|
BCF PIR1,TXIF ;CLEAR TX interrupt
|
||||||
|
RETURN
|
||||||
|
SERIAL_ON
|
||||||
|
BTFSC TXSTA,TXEN ;SCHON EIN?
|
||||||
|
RETURN ;JA->
|
||||||
|
BSF TXSTA,TXEN ;TX EIN
|
||||||
|
MOVLW SYNC1
|
||||||
|
MOVWF RX_STATUS ;AUF SYNC WARTEN
|
||||||
|
CLRF TX_STATUS
|
||||||
|
MOVFF RCREG,RX_B ;RCREG LEEREN
|
||||||
|
MOVFF RCREG,RX_B ;RCREG LEEREN
|
||||||
|
BCF PIR1,TXIF ;CLEAR TX interrupt
|
||||||
|
BCF PIR1,RCIF ;INTERRUPT RX FLAG L<>SCHEN
|
||||||
|
BSF PIE1,RCIE ;ENABLE RX interrupt
|
||||||
|
NOP
|
||||||
|
RETURN
|
||||||
|
;---------------------------------------------------------------------
|
||||||
|
; TASTENDRUCK
|
||||||
|
TASTE
|
||||||
|
BTFSS PORTD,RD1 ;TASTE GEDR<44>CKT?
|
||||||
|
BRA TG_JA ;->JA
|
||||||
|
;TASTE NICHT GEDR<44>CKT ODER LOSGELASSEN
|
||||||
|
CLRF TASTE_ON_TIME ;R<>CKSETZEN
|
||||||
|
|
||||||
|
MOVLW TIME_MAX ;MAX
|
||||||
|
CPFSGT TASTE_OFF_TIME ;L<>NGER?
|
||||||
|
INCF TASTE_OFF_TIME ;NEIN ERH<52>HEN
|
||||||
|
|
||||||
|
MOVLW RESET_OFF_TIME ;2SEC
|
||||||
|
CPFSGT POWER_ON_TIME ;L<>NGER?
|
||||||
|
RETURN ;NEIN->
|
||||||
|
;RESET AUFHEBEN
|
||||||
|
BSF TRISD,RD7 ;JA -> #RSTI DEAKTIVIEREN =HIGH
|
||||||
|
CALL SERIAL_ON ;SERIELL EINSCHALTEN
|
||||||
|
RETURN
|
||||||
|
;TASTE GEDR<44>CKT
|
||||||
|
TG_JA
|
||||||
|
MOVLW OFF_TIME+1
|
||||||
|
CPFSLT TASTE_ON_TIME ;K<>RZER ALS ONTIME+1
|
||||||
|
RETURN ;NEIN->FERTIG
|
||||||
|
BTFSC TRISD,RD0 ;ONPOWER?
|
||||||
|
BRA TG_OFF_POWER ;NEIN->
|
||||||
|
TG_ON_POWER
|
||||||
|
MOVLW SEND_RTC_TIME ;ZEIT F<>R RTC REQ FROM MCF HOLEN?
|
||||||
|
CPFSEQ TASTE_ON_TIME ;TEST
|
||||||
|
BRA TG_ON_POWER2 ;NEIN->
|
||||||
|
SEND_RTC_REG
|
||||||
|
MOVLW REQ_RTCD_FROM_MCF
|
||||||
|
MOVWF TXREG ;SENDEN
|
||||||
|
BRA TG_END;
|
||||||
|
TG_ON_POWER2
|
||||||
|
MOVLW RESET_ON_TIME ;
|
||||||
|
CPFSLT TASTE_ON_TIME ;K<>RZER?
|
||||||
|
BRA RESETEN
|
||||||
|
TG_ON_POWER3
|
||||||
|
MOVLW OFF_TIME
|
||||||
|
CPFSLT TASTE_ON_TIME ;K<>RZER ON/OFF TIME?
|
||||||
|
CALL POWER_AUS ;NEIN->POWER OFF
|
||||||
|
BRA TG_END
|
||||||
|
TG_OFF_POWER
|
||||||
|
MOVLW ON_TIME
|
||||||
|
CPFSLT TASTE_ON_TIME ;K<>RZER ALS ON/OFF TIME?
|
||||||
|
CALL POWER_EIN ;NEIN->POWER ON
|
||||||
|
TG_END
|
||||||
|
CLRF TASTE_OFF_TIME ;R<>CKSETZEN
|
||||||
|
INCF TASTE_ON_TIME ;ERH<52>HEN
|
||||||
|
RETURN
|
||||||
|
RESETEN
|
||||||
|
BCF TRISD,RD7 ;NEIN-> #RSTI AKTIVIEREN =LOW -->>>RESET
|
||||||
|
CALL SERIAL_OFF ;SERIELL DEAKTIVIEREN
|
||||||
|
BRA TG_ON_POWER3
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;----------------------------------------- INTERRUPTS
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
; SERIELL INTERRUPTS
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;TX
|
||||||
|
TX_ISR ;TRANSMIT
|
||||||
|
MOVLW RTCD_FROM_PIC ;RTC DATEN SENDEN?
|
||||||
|
CPFSEQ TX_STATUS ;SKIP JA
|
||||||
|
BRA TX_ISR1 ;NEIN->
|
||||||
|
MOVFF POSTINC0,TXREG ;BYT SENDEN
|
||||||
|
MOVLW 0x3F ;SCHON LETZTES BYTS?
|
||||||
|
CPFSGT FSR0L ;SKIP WENN FERTIG
|
||||||
|
RETFIE ;NEIN WEITERE SENDEN
|
||||||
|
TX_ISR_FERTIG
|
||||||
|
CLRF TX_STATUS
|
||||||
|
BCF PIE1,TXIE ;SONST DISABLE interrupt
|
||||||
|
BCF PIR1,TXIF ;INTERRUPT FLAG L<>SCHEN
|
||||||
|
RETFIE
|
||||||
|
TX_ISR1
|
||||||
|
MOVLW READ_BLOCK ;READ BLOCK?
|
||||||
|
CPFSEQ TX_STATUS ;SKIP JA
|
||||||
|
BRA TX_ISR2 ;NEIN->
|
||||||
|
MOVFF POSTINC0,TXREG ;BYT SENDEN
|
||||||
|
MOVLW 0xC3 ;SCHON LETZTES BYTS?
|
||||||
|
CPFSGT FSR0L ;SKIP WENN FERTIG
|
||||||
|
RETFIE ;NEIN WEITERE SENDEN
|
||||||
|
TX_ISR2
|
||||||
|
BRA TX_ISR_FERTIG
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;RX
|
||||||
|
RX_ISR ; BYT RECEIVED
|
||||||
|
MOVFF RCREG,RX_B ; BYT HOLEN
|
||||||
|
; MOVFF RX_B,TXREG ; ECHO
|
||||||
|
MOVLW SYNC4 ;IM SYNC STATUS?
|
||||||
|
CPFSLT RX_STATUS ;SKIP WENN NEIN
|
||||||
|
BRA RX_SYNC_START ;JA -> ZUERST SYNC EMPFANGEN
|
||||||
|
;---------------
|
||||||
|
MOVLW RTCD_FROM_MCF ; DATEN VOM MCF CODE 0x82?
|
||||||
|
CPFSEQ RX_STATUS ; WENN JA-> SKIP
|
||||||
|
BRA RX_ISR1 ; NEIN->
|
||||||
|
;64 BYT EMPFANGEN -------------------------------------
|
||||||
|
MOVFF RX_B,POSTINC1 ;HOLEN -> (CNT+)
|
||||||
|
MOVLW 0x3F ;64 BYT <20>BERTRAGEN?
|
||||||
|
CPFSLT FSR1L ;NEIN ->SKIP
|
||||||
|
CLRF RX_STATUS ;JA FERTIG
|
||||||
|
RETFIE
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR1
|
||||||
|
CPFSEQ RX_B ;BLOCK HEADER 0X82?
|
||||||
|
BRA RX_ISR2 ;NEIN->
|
||||||
|
MOVWF RX_STATUS ;STATUS SETZEN = EMPFANGENES BYT
|
||||||
|
LFSR 1,.0 ;BYT COUNTER AUF O
|
||||||
|
RETFIE
|
||||||
|
RX_ISR2
|
||||||
|
MOVLW REQ_RTCD_FROM_PIC ;DATEN SENDEN?
|
||||||
|
CPFSEQ RX_B ;SKIP WENN JA
|
||||||
|
BRA RX_ISR3 ;SONST NEXT
|
||||||
|
;BLOCK HEADER UND 64 BYT SENDEN -----------------------------------------
|
||||||
|
LFSR 0,.0
|
||||||
|
BCF PIR1,TXIF ;INTERRUPT FLAG L<>SCHEN
|
||||||
|
BSF PIE1,TXIE ;Enable interrupt
|
||||||
|
MOVLW RTCD_FROM_PIC
|
||||||
|
MOVWF TX_STATUS ;STATUS SETZEN
|
||||||
|
MOVWF TXREG ;BLOCK HEADER = 0X81
|
||||||
|
CLRF RX_STATUS ;STATUS R<>CKSETZEN
|
||||||
|
RETFIE ;UND WEG
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR3
|
||||||
|
MOVLW EXT_SUB_GO ;EXT SUB FREIGEBEN?
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA RX_ISR4 ;NEIN->
|
||||||
|
;EXT SUBS FREIGEBEN --------------------------------------------------------------
|
||||||
|
MOVLW (EXTERN_INT_ADR & 0xFF0000)>>16
|
||||||
|
MOVWF TBLPTRU
|
||||||
|
MOVLW (EXTERN_INT_ADR & 0x00FF00)>>8
|
||||||
|
MOVWF TBLPTRH
|
||||||
|
MOVLW (EXTERN_INT_ADR & 0x0000FF)
|
||||||
|
MOVWF TBLPTRL ;ADRESSE SETZEN
|
||||||
|
TBLRD* ;WERT HOLEN (MUSS 0xFB SEIN SONST UNG<4E>LTIG)
|
||||||
|
MOVFF TABLAT,GO_INT ;EXTERNE SUBROUTINES AKTIVIEREN WENN OK
|
||||||
|
MOVLW (EXTERN_SUB_ADR & 0xFF0000)>>16
|
||||||
|
MOVWF TBLPTRU
|
||||||
|
MOVLW (EXTERN_SUB_ADR & 0x00FF00)>>8
|
||||||
|
MOVWF TBLPTRH
|
||||||
|
MOVLW (EXTERN_SUB_ADR & 0x0000FF)
|
||||||
|
MOVWF TBLPTRL ;ADRESSE SETZEN
|
||||||
|
TBLRD* ;WERT HOLEN (MUSS 0xFB SEIN SONST UNG<4E>LTIG)
|
||||||
|
MOVFF TABLAT,GO_SUB ;EXTERNE SUBROUTINES AKTIVIEREN WENN OK
|
||||||
|
CLRF RX_STATUS ;STATUS R<>CKSETZEN
|
||||||
|
RETFIE ;UND WEG
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR4
|
||||||
|
MOVLW EXT_SUB_STOP ;EXT SUB STOPPEN?
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA RX_ISR5 ;NEIN->
|
||||||
|
;EXT SUBS STOPPEN --------------------------------------------------------------
|
||||||
|
CLRF GO_INT ;STOPPEN
|
||||||
|
CLRF GO_SUB ;STOPPEN
|
||||||
|
CLRF RX_STATUS ;STATUS R<>CKSETZEN
|
||||||
|
RETFIE ;UND WEG
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR5
|
||||||
|
MOVLW REQ_BLOCK ;REQ BLOCK?
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA RX_ISR6 ;NEIN->
|
||||||
|
;REQ BLOCK ----------------------------------------------------------------
|
||||||
|
MOVWF RX_STATUS ;STATUS SETZEN = EMPFANGENES BYT
|
||||||
|
LFSR 1,TX_BUFFER ;BYT COUNTER AUF TX_BUFFER -> GLEICH EINTRAGEN
|
||||||
|
RETFIE
|
||||||
|
RX_ISR6
|
||||||
|
CPFSEQ RX_STATUS ;REQ BLOCK ADRESSE EMPFANGFEN?
|
||||||
|
BRA RX_ISR7 ;NEIN->
|
||||||
|
;3 BYT EMPFANGEN -------------------------------------
|
||||||
|
MOVFF RX_B,POSTINC1 ;HOLEN -> (CNT+)
|
||||||
|
MOVLW 0x82 ;3 BYT <20>BERTRAGEN? (BUFFER BEGINNT BEI 0x180
|
||||||
|
CPFSLT FSR1L ;NEIN ->SKIP
|
||||||
|
BRA RX_RB3BOK
|
||||||
|
RETFIE
|
||||||
|
RX_RB3BOK
|
||||||
|
LFSR 1,TX_BUFFER ;BYT RX COUNTER AUF TX_BUFFER
|
||||||
|
MOVFF POSTINC1,TBLPTRU ;ADRESSE EINTRAGEN
|
||||||
|
MOVFF POSTINC1,TBLPTRH
|
||||||
|
MOVFF POSTINC1,TBLPTRL
|
||||||
|
MOVLW 0xC2 ;67 BYT <20>BERTRAGEN? (BUFFER BEGINNT BEI 0x180
|
||||||
|
RX_RB3B2
|
||||||
|
TBLRD *+ ;LESEN UND NEXT
|
||||||
|
MOVFF TABLAT,POSTINC1 ;UND EINTRAGEN
|
||||||
|
CPFSEQ FSR1L ;WENN FERTIG ->SKIP
|
||||||
|
BRA RX_RB3B2 ;SONST LOOP
|
||||||
|
;BLOCK HEADER 3 BYTS ADRESSE UND 64 BYT SENDEN STARTEN -----------------------------------------
|
||||||
|
LFSR 0,TX_BUFFER ;TX COUNTER AUF TX_BUFFER
|
||||||
|
BCF PIR1,TXIF ;INTERRUPT FLAG L<>SCHEN
|
||||||
|
BSF PIE1,TXIE ;Enable interrupt
|
||||||
|
MOVLW READ_BLOCK ;CODE HEADER 0xA1
|
||||||
|
MOVWF TX_STATUS ;STATUS SETZEN
|
||||||
|
MOVWF TXREG ;BLOCK HEADER = 0XA1
|
||||||
|
CLRF RX_STATUS ;STATUS R<>CKSETZEN
|
||||||
|
RETFIE ;UND WEG
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR7
|
||||||
|
MOVLW WRITE_BLOCK ;WRITE BLOCK 0xA2 BYT EMPFANGEN?
|
||||||
|
CPFSEQ RX_STATUS ;WENN JA-> SKIP
|
||||||
|
BRA RX_ISR8 ;NEIN->
|
||||||
|
;WRITE BLOCK ----------------------------------------------------------------------------
|
||||||
|
;67 BYT EMPFANGEN -------------------------------------
|
||||||
|
MOVFF RX_B,POSTINC1 ;HOLEN -> (CNT+)
|
||||||
|
MOVLW 0x42 ;67 BYT <20>BERTRAGEN?
|
||||||
|
CPFSLT FSR1L ;WENN FERTIG ->SKIP
|
||||||
|
RETFIE
|
||||||
|
; ADRESSE UND DATEN SIND DA -> PROGRAMMING FLASH
|
||||||
|
LFSR 1,RX_BUFFER ;BYT COUNTER AUF RX BUFFER
|
||||||
|
MOVFF POSTINC1,TBLPTRU ;TABLE POINTER SETZEN
|
||||||
|
MOVLW (EXTERN_INT_ADR & 0xFF0000)>>16
|
||||||
|
CPFSLT TBLPTRU ;TEST OB WENIGER ALS ERLAUBT
|
||||||
|
BRA NO_PROG ;JA->
|
||||||
|
MOVFF POSTINC1,TBLPTRH ;TABLE POINTER SETZEN
|
||||||
|
MOVLW (EXTERN_INT_ADR & 0x00FF00)>>8
|
||||||
|
CPFSLT TBLPTRU ;TEST OB WENIGER ALS ERLAUBT
|
||||||
|
BRA NO_PROG ;JA->
|
||||||
|
MOVFF POSTINC1,TBLPTRL ;TABLE POINTER SETZEN
|
||||||
|
;EREASE BLOCK
|
||||||
|
BSF EECON1,EEPGD ; point to Flash program memory
|
||||||
|
BCF EECON1,CFGS ; access Flash program memory
|
||||||
|
BSF EECON1,WREN ; enable write to memory
|
||||||
|
BSF EECON1,FREE ; enable Row Erase operation
|
||||||
|
MOVLW 55h
|
||||||
|
MOVWF EECON2 ; write 55h
|
||||||
|
MOVLW 0AAh ; write 0AAh
|
||||||
|
MOVWF EECON2
|
||||||
|
BSF EECON1,WR ; start erase (CPU stall)
|
||||||
|
MOVLW 0x42 ;67 BYT
|
||||||
|
WRITE_WORD_TO_HREGS
|
||||||
|
MOVFF POSTINC1,TABLAT ; get byte of buffer data
|
||||||
|
TBLWT+* ; write data, perform a short write to internal TBLWT holding register.
|
||||||
|
CPFSLT FSR1L ;SCHON BEI 67 BYTES?
|
||||||
|
BRA WRITE_WORD_TO_HREGS ;NEIN->LOOP
|
||||||
|
PROGRAM_MEMORY
|
||||||
|
BSF EECON1,EEPGD ; point to Flash program memory
|
||||||
|
BCF EECON1,CFGS ; access Flash program memory
|
||||||
|
BSF EECON1,WREN ; enable write to memory
|
||||||
|
MOVLW 55h
|
||||||
|
MOVWF EECON2 ; write 55h
|
||||||
|
MOVLW 0AAh
|
||||||
|
MOVWF EECON2 ; write 0AAh
|
||||||
|
BSF EECON1,WR ; start program (CPU stall)
|
||||||
|
BCF EECON1,WREN ; disable write to memory
|
||||||
|
NO_PROG
|
||||||
|
CLRF RX_STATUS ;AUF NORMLA SCHALTEN
|
||||||
|
RETFIE ;UND FERTIG
|
||||||
|
;WRITE BLOCK SETZEN?
|
||||||
|
RX_ISR8
|
||||||
|
CPFSEQ RX_B ;BLOCK HEADER COMMANDOE 0XA2?
|
||||||
|
BRA RX_ISR9 ;NEIN->
|
||||||
|
MOVWF RX_STATUS ;STATUS SETZEN = EMPFANGENES BYT
|
||||||
|
LFSR 1,RX_BUFFER ;BYT COUNTER AUF RX BUFFER
|
||||||
|
RETFIE
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_ISR9
|
||||||
|
CLRF RX_STATUS
|
||||||
|
RETFIE
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
;SYNC ABWARTEN UND WENN DA "OK!" SENDEN ----------------------------------------------------
|
||||||
|
;-------------------------------------------------------------------------------------
|
||||||
|
RX_SYNC_START
|
||||||
|
MOVLW SYNC1
|
||||||
|
CPFSEQ RX_STATUS
|
||||||
|
BRA RX_SYNC2
|
||||||
|
MOVLW SYNC1_DATA
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA NON_SYNC
|
||||||
|
MOVLW SYNC2
|
||||||
|
MOVWF RX_STATUS
|
||||||
|
RETFIE
|
||||||
|
NON_SYNC
|
||||||
|
MOVLW SYNC1
|
||||||
|
MOVWF RX_STATUS
|
||||||
|
RETFIE
|
||||||
|
RX_SYNC2 ;TEST AUF SYNC UND DATA 2
|
||||||
|
MOVLW SYNC2
|
||||||
|
CPFSEQ RX_STATUS
|
||||||
|
BRA RX_SYNC3 ;NICHT SYNC 2
|
||||||
|
MOVLW SYNC2_DATA
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA NON_SYNC
|
||||||
|
MOVLW SYNC3
|
||||||
|
MOVWF RX_STATUS
|
||||||
|
RETFIE
|
||||||
|
RX_SYNC3 ;TEST AUF SYNC UND DATA 3
|
||||||
|
MOVLW SYNC3
|
||||||
|
CPFSEQ RX_STATUS
|
||||||
|
BRA RX_SYNC4 ;NICHT SYNC 3
|
||||||
|
MOVLW SYNC3_DATA
|
||||||
|
CPFSEQ RX_B
|
||||||
|
BRA NON_SYNC
|
||||||
|
MOVLW SYNC4
|
||||||
|
MOVWF RX_STATUS
|
||||||
|
RETFIE
|
||||||
|
RX_SYNC4 ;TEST AUF SYNC UND DATA 4
|
||||||
|
MOVLW SYNC4
|
||||||
|
CPFSEQ RX_STATUS
|
||||||
|
BRA NON_SYNC ;WIEDER VON VORN
|
||||||
|
MOVLW SYNC4_DATA
|
||||||
|
CPFSEQ RX_B ;SKIP OK
|
||||||
|
BRA NON_SYNC ;NICHT SYNC4 DATA
|
||||||
|
RX_WAIT1
|
||||||
|
BTFSS TXSTA,TRMT
|
||||||
|
BRA RX_WAIT1
|
||||||
|
MOVLW 'O' ;SENDE OK!
|
||||||
|
MOVWF TXREG;
|
||||||
|
RX_WAIT2
|
||||||
|
BTFSS TXSTA,TRMT
|
||||||
|
BRA RX_WAIT2
|
||||||
|
MOVLW 'K' ;SENDE OK!
|
||||||
|
MOVWF TXREG;
|
||||||
|
RX_WAIT3
|
||||||
|
BTFSS TXSTA,TRMT
|
||||||
|
BRA RX_WAIT3
|
||||||
|
MOVLW '!'
|
||||||
|
MOVWF TXREG;
|
||||||
|
CLRF RX_STATUS ;OK START NORMAL
|
||||||
|
RETFIE
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;SPANNUNGS<47>BERWACHUNGS INTERRUPT
|
||||||
|
HLVD_ISR
|
||||||
|
BTFSS U_ERR,1 ;WARTEN AUF GELADEN?
|
||||||
|
BRA HLVD_LE ;NEIN UNTERSPANNUNG DETEKT->
|
||||||
|
BCF U_ERR,0 ;SPANNUNGSFEHLER AUS
|
||||||
|
BCF U_ERR,1 ;WARTEN AUF GELADEN=AUS
|
||||||
|
MOVLW U_ERR_PW_AUS+2 ;POWER AUS <20>BERSPRINGEN
|
||||||
|
MOVWF U_ERR_TIME ;ZEIT SETZEN
|
||||||
|
MOVLW B'00010111' ;INT WENN UNTER 3.12V
|
||||||
|
MOVWF HLVDCON
|
||||||
|
WAIT_LVDOK:
|
||||||
|
BTFSS HLVDCON,IVRST ;ABWARTEN BIS AENDERUNG AKTIV
|
||||||
|
BRA WAIT_LVDOK
|
||||||
|
BCF PIR2,HLVDIF ;INTERRUPT FLAG L<>SCHEN
|
||||||
|
RETFIE
|
||||||
|
HLVD_LE ;UNTERSPANNUNG
|
||||||
|
BSF U_ERR,0 ;ERROR SETZEN
|
||||||
|
BSF U_ERR,1 ;WARTEN AUF GELADEN SETZEN
|
||||||
|
CLRF U_ERR_TIME ;R<>CKSETZEN
|
||||||
|
;MESSAGE AN PROCESSOR
|
||||||
|
MOVLW U_MIN_TO_MCF
|
||||||
|
MOVWF TXREG ;SENDEN
|
||||||
|
|
||||||
|
MOVLW B'10011010' ;INT WENN <20>BER 3.7V
|
||||||
|
MOVWF HLVDCON
|
||||||
|
BRA WAIT_LVDOK
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;A/D INTERRUPT
|
||||||
|
AD_ISR
|
||||||
|
BCF PIR1,ADIF ;CLEAR INTERRUPT PENDIG
|
||||||
|
RETFIE ;RETURN
|
||||||
|
;*************************************************************************************************************
|
||||||
|
; uhr interrupt ALLE 1/8 SEC
|
||||||
|
RTC_ISR
|
||||||
|
;UHR WIEDER R<>CKSETZEN UND AKTIVIEREN
|
||||||
|
MOVLW TIMER_HB ;WIEDER AUF STARTWERT
|
||||||
|
MOVWF TMR1H ;SETZEN
|
||||||
|
BCF PIR1,TMR1IF ;INTERRUPT FLAG L<>SCHEN
|
||||||
|
BSF PORTB,RB4 ;PIC INT HIGH --------
|
||||||
|
BSF TRISE,RE0 ;LED=OFF
|
||||||
|
BCF PORTB,RB4 ;PIC INT = LOW
|
||||||
|
BTFSC TRISD,RD0 ;POWER OFF?
|
||||||
|
BRA POWER_OFF_I ;JA->
|
||||||
|
; POWER IS ON:
|
||||||
|
; BLINKEN 4X/SEC WENN RESET
|
||||||
|
BTFSC TRISD,RD7 ;RESET AKTIV?
|
||||||
|
BRA PINGS ;NEIN->
|
||||||
|
BTFSC TICKS,0 ;UNGERADE TICKS?
|
||||||
|
BCF TRISE,RE0 ;NEIN->LED=ON
|
||||||
|
BRA PINGS
|
||||||
|
POWER_OFF_I
|
||||||
|
MOVLW .3
|
||||||
|
ANDWF SECS,0 ;4 SEKUNDEN AUSMASKIEREN
|
||||||
|
BNZ PINGS ;NICHT MODULO4 ->
|
||||||
|
MOVLW .7
|
||||||
|
CPFSEQ TICKS ;7. TICK?
|
||||||
|
BRA POWER_OFF_I2 ;NEIN->
|
||||||
|
BCF TRISE,RE0 ;JA->LED=ON
|
||||||
|
POWER_OFF_I2
|
||||||
|
MOVLW .30 ; WENIGER ALS 30 SEC SEIT LETZTEM SPANNUNGSFEHLER?
|
||||||
|
CPFSLT U_ERR_TIME
|
||||||
|
BRA PINGS ;NEIN->
|
||||||
|
MOVLW .5
|
||||||
|
CPFSEQ TICKS ;5. TICK?
|
||||||
|
BRA PINGS ;NEIN->
|
||||||
|
BCF TRISE,RE0 ;JA->LED=ON
|
||||||
|
PINGS
|
||||||
|
CALL TASTE ;UP TASTE
|
||||||
|
; TASTE LOSGELASSEN?
|
||||||
|
MOVLW RESET_OFF_TIME
|
||||||
|
CPFSGT TASTE_OFF_TIME ;TASTE L<>NGER ALS 2 SEC LOSGELASSEN?
|
||||||
|
BRA PINGW ;NEIN->
|
||||||
|
BSF TRISD,RD7 ;JA-> #RSTI INAKTIV =HIGH
|
||||||
|
BTFSS TRISD,RD0 ;POWER ON?
|
||||||
|
CALL SERIAL_ON ;ja->SERIELL EINSCHALTEN
|
||||||
|
;--TICKS=125MS
|
||||||
|
PINGW
|
||||||
|
INCF TICKS ;inc ticks
|
||||||
|
BTFSS TRISD,RD0 ;POWER ON?
|
||||||
|
BRA PINGS2 ;JA->
|
||||||
|
MOVLW 20
|
||||||
|
CPFSLT U_POWER_IN ;LADEGER<45>T ANGESCHLOSSEN?
|
||||||
|
BRA PINGS2 ;->JA LED HELLER
|
||||||
|
MOVLW TIME_MAX ;>=MAXIMALZEIT?
|
||||||
|
CPFSLT U_ERR_TIME ;SEIT SPANNUNGSFEHLER
|
||||||
|
BSF TRISE,RE0 ;JA -> LED OFF
|
||||||
|
PINGS2
|
||||||
|
MOVLW .7 ; 7?
|
||||||
|
CPFSGT TICKS
|
||||||
|
RETFIE ; NEIN ->RETURN
|
||||||
|
SEKUNDEN
|
||||||
|
;led blinken POWER ON-----------------------------------------
|
||||||
|
BTFSS TRISD,RD0 ;POWER ON?
|
||||||
|
BCF TRISE,RE0 ;JA -> LED_ON
|
||||||
|
;TIMER U_ERR ERH<52>HEN
|
||||||
|
MOVLW TIME_MAX ;>=MAXIMALZEIT?
|
||||||
|
CPFSGT U_ERR_TIME ;SEIT SPANNUNGSFEHLER
|
||||||
|
INCF U_ERR_TIME ;NEIN ERH<52>HEN
|
||||||
|
;SPANNUNGSFEHLER BEARBEITEN ----------------------------------------
|
||||||
|
MOVLW U_ERR_PW_AUS ;POWER AUS ZEIT?
|
||||||
|
CPFSEQ U_ERR_TIME ;
|
||||||
|
BRA SEK_NPA ;NEIN
|
||||||
|
CALL POWER_AUS ;JA AUSSCHALTEN
|
||||||
|
;--------------------------------------------------------
|
||||||
|
SEK_NPA
|
||||||
|
;SPANNUNG POWER IN MESSEN
|
||||||
|
MOVLW B'00000001' ;KANAL 0, AD ON
|
||||||
|
MOVWF ADCON0 ;
|
||||||
|
BSF ADCON0,1 ;GO
|
||||||
|
SEK_2
|
||||||
|
BTFSC ADCON0,1 ;FERTIG?
|
||||||
|
BRA SEK_2 ;NEIN
|
||||||
|
MOVFF ADRESH,U_POWER_IN ;OK WERT EINTRAGEN
|
||||||
|
|
||||||
|
;SPANNUNG 2V5 MESSEN -> U_ERR TIMER NICHT ERH<52>HEN WENN <20>BER 3.2V RESP. WIEDER -1
|
||||||
|
BTFSC TRISD,RD0 ;POWER ON?
|
||||||
|
BRA SEK_4 ;NEIN NICHT MESSEN
|
||||||
|
|
||||||
|
MOVLW B'00001101' ;KANAL 3, AD ON
|
||||||
|
MOVWF ADCON0 ;
|
||||||
|
BSF ADCON0,1 ;GO
|
||||||
|
SEK_3
|
||||||
|
BTFSC ADCON0,1 ;FERTIG?
|
||||||
|
BRA SEK_3 ;NEIN
|
||||||
|
MOVLW .200 ;UNTER 3.2V -> WENN WERT <20>BER 78%
|
||||||
|
CPFSLT ADRESH ;JA ->
|
||||||
|
BRA SEK_4 ;SONST WEITER
|
||||||
|
;TIMER U_ERR ERH<52>HEN
|
||||||
|
BTFSS U_ERR,0 ;SPANNUNGSERROR?
|
||||||
|
BRA SEK_4 ;NEIN
|
||||||
|
MOVLW TIME_MAX ;>=MAXIMALZEIT?
|
||||||
|
CPFSGT U_ERR_TIME ;SEIT SPANNUNGSFEHLER
|
||||||
|
DECF U_ERR_TIME ;NEIN -> -1
|
||||||
|
;-------------------------------------------------------------
|
||||||
|
SEK_4
|
||||||
|
CLRF TICKS
|
||||||
|
INCF SECS ; Increment seconds
|
||||||
|
MOVLW .59 ; 60 seconds elapsed?
|
||||||
|
CPFSGT SECS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
MINUTEN
|
||||||
|
CLRF SECS ; Clear seconds
|
||||||
|
INCF MINS ; Increment minutes
|
||||||
|
MOVLW .59 ; 60 minutes elapsed?
|
||||||
|
CPFSGT MINS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
STUNDEN
|
||||||
|
CLRF MINS ; clear minutes
|
||||||
|
INCF HOURS ; Increment hours
|
||||||
|
MOVLW .23 ; 24 hours elapsed?
|
||||||
|
CPFSGT HOURS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
TAGE_UND_TAG_DER_WOCHE
|
||||||
|
CLRF HOURS ; Reset hours
|
||||||
|
MOVLW .7
|
||||||
|
CPFSLT DAY_OF_WEEK
|
||||||
|
CLRF DAY_OF_WEEK
|
||||||
|
INCF DAY_OF_WEEK
|
||||||
|
INCF DAYS
|
||||||
|
MOVLW .28
|
||||||
|
CPFSGT DAYS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
MEHR_ALS_28_TAGE
|
||||||
|
MOVLW .2
|
||||||
|
CPFSEQ MONTHS ;FEB?
|
||||||
|
BRA NOT_FEB ;NEIN->
|
||||||
|
FEB
|
||||||
|
MOVLW .3
|
||||||
|
ANDWF YEARS,0 ;SCHALTJAHR
|
||||||
|
BNZ NEXT_MONTH ;NEIN->
|
||||||
|
SCHALTJAHR
|
||||||
|
MOVLW .29
|
||||||
|
CPFSGT DAYS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
NEXT_MONTH
|
||||||
|
MOVLW .1
|
||||||
|
MOVWF DAYS
|
||||||
|
INCF MONTHS
|
||||||
|
MOVLW 12
|
||||||
|
CPFSGT MONTHS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
YEAR
|
||||||
|
MOVLW .1
|
||||||
|
MOVWF MONTHS
|
||||||
|
INCF YEARS
|
||||||
|
RETFIE ;RETURN
|
||||||
|
NOT_FEB
|
||||||
|
MOVLW .30
|
||||||
|
CPFSGT DAYS
|
||||||
|
RETFIE
|
||||||
|
MEHR_ALS_30_TAGE
|
||||||
|
MOVLW .4 ;APRIL?
|
||||||
|
CPFSEQ MONTHS ;SKIP
|
||||||
|
BRA NOT_APRIL
|
||||||
|
BRA NEXT_MONTH ;APRIL->
|
||||||
|
NOT_APRIL
|
||||||
|
MOVLW .6 ;JUNI?
|
||||||
|
CPFSEQ MONTHS
|
||||||
|
BRA NOT_JUNI
|
||||||
|
BRA NEXT_MONTH ;JUNI->
|
||||||
|
NOT_JUNI
|
||||||
|
MOVLW .9 ;SEPTEMBER?
|
||||||
|
CPFSEQ MONTHS
|
||||||
|
BRA NOT_SEP
|
||||||
|
BRA NEXT_MONTH ;SEPTEMBER->
|
||||||
|
NOT_SEP
|
||||||
|
MOVLW .11 ;NOVEMBER?
|
||||||
|
CPFSEQ MONTHS ;SKIP
|
||||||
|
RETFIE ;SIND MONATE MIT 31 TAGEN->
|
||||||
|
BRA NEXT_MONTH ;SONST NOVEMBER->
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
; ENDE MAIN
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
; EXTERN_SUBOUTINES FOGEN AB 0x1000 DIE SP<53>TER EINPROGRAMMIERT WERDEN
|
||||||
|
;**********************************************************************************************"""""""""""""
|
||||||
|
end
|
||||||
BIN
firebee1.cof
Normal file
BIN
firebee1.cof
Normal file
Binary file not shown.
0
firebee1.err
Normal file
0
firebee1.err
Normal file
82
firebee1.hex
Normal file
82
firebee1.hex
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
:020000040000FA
|
||||||
|
:020000007FD0AF
|
||||||
|
:020002000000FC
|
||||||
|
:040008000CEF00F009
|
||||||
|
:08001800E06A9DCF4EF09E50FE
|
||||||
|
:100020004E174EB115D24EBD11D24EB918D14EBB9E
|
||||||
|
:100030002BD1A0CF4FF0A1504F174FB5F3D11000E7
|
||||||
|
:100040009DCF4EF09E504E174E67E6D7A0CF4FF093
|
||||||
|
:10005000A1504F174F67E0D7FB0E4D63100001EF23
|
||||||
|
:0200600010F09E
|
||||||
|
:10010000E06AF26AD06A9D6AA06A9E6AA16A9F6AE2
|
||||||
|
:10011000A26A9B6A720ED36E806AFF0E926E816A2B
|
||||||
|
:10012000936E826A946E836A956E010E846A966EEF
|
||||||
|
:100130009B0ED26E030E466F140E476FA084E9EC3F
|
||||||
|
:1001400000F0F00ECF6ECE6A0F0ECD6E416B006BDD
|
||||||
|
:10015000026B0C0E046F010E066F010E076F080E86
|
||||||
|
:10016000086F2A0E096F426B436B446B9D80456B91
|
||||||
|
:10017000C26A090EC16E000EC06E486BB06A100EE6
|
||||||
|
:10018000AF6E040EAC6E900EAB6E080EB86E4C6B7C
|
||||||
|
:10019000F06AF00EF16EC00EF26E120ED36EFB0E10
|
||||||
|
:1001A0004C6302D0D7ED00F095B00300F8D709EC0E
|
||||||
|
:1001B00010F01300720ED36E929E959E93989590B8
|
||||||
|
:1001C0000AD0120ED36E9580958E9388928E446BD2
|
||||||
|
:1001D00004D095B002D09298120092881200AC9A86
|
||||||
|
:1001E0009D9A9E9A9D989E981200ACBA1200AC8A75
|
||||||
|
:1001F000FF0E4A6F4B6BAECF49F0AECF49F09E98E1
|
||||||
|
:100200009E9A9D8A0000120083A20BD0426BA00E22
|
||||||
|
:100210004365432B040E44651200958EF5EC00F007
|
||||||
|
:100220001200150E4261120095B00ED0020E42630C
|
||||||
|
:1002300003D0020EAD6E0CD0020E42610CD0140E33
|
||||||
|
:100240004261E1EC00F004D0020E4261DAEC00F011
|
||||||
|
:10025000436B422B1200959EEFEC00F0F0D7810E1D
|
||||||
|
:100260004B6309D0EECFADFF3F0EE96410004B6B3E
|
||||||
|
:100270009D989E981000A10E4B6305D0EECFADFF68
|
||||||
|
:10028000C30EE9641000F3D7AECF49F0FC0E4A610B
|
||||||
|
:1002900097D0820E4A6306D049C0E6FF3F0EE16068
|
||||||
|
:1002A0004A6B1000496304D04A6F10EE00F0100052
|
||||||
|
:1002B000010E496309D000EE00F09E989D88810EE2
|
||||||
|
:1002C0004B6FAD6E4A6B1000040E496314D0000EE4
|
||||||
|
:1002D000F86E200EF76E000EF66E0800F5CF4DF0AA
|
||||||
|
:1002E000000EF86E200EF76E100EF66E0800F5CFB9
|
||||||
|
:1002F0004CF04A6B1000050E496304D04D6B4C6BFB
|
||||||
|
:100300004A6B1000A00E496304D04A6F11EE80F0D2
|
||||||
|
:1003100010004A631DD049C0E6FF820EE16001D0A3
|
||||||
|
:10032000100011EE80F0E6CFF8FFE6CFF7FFE6CF42
|
||||||
|
:10033000F6FFC20E0900F5CFE6FFE162FBD701EE42
|
||||||
|
:1003400080F09E989D88A10E4B6FAD6E4A6B100099
|
||||||
|
:10035000A20E4A632DD049C0E6FF420EE1601000B4
|
||||||
|
:1003600011EE00F0E6CFF8FF000EF8601FD0E6CFE8
|
||||||
|
:10037000F7FF200EF8601AD0E6CFF6FFA68EA69CF7
|
||||||
|
:10038000A684A688550EA76EAA0EA76EA682420E58
|
||||||
|
:10039000E6CFF5FF0F00E160FBD7A68EA69CA684F2
|
||||||
|
:1003A000550EA76EAA0EA76EA682A6944A6B1000E1
|
||||||
|
:1003B000496304D04A6F11EE00F010004A6B100040
|
||||||
|
:1003C000FF0E4A6309D0410E496303D0FE0E4A6F07
|
||||||
|
:1003D0001000FF0E4A6F1000FE0E4A6306D0430E57
|
||||||
|
:1003E0004963F7D7FD0E4A6F1000FD0E4A6306D031
|
||||||
|
:1003F000500E4963EED7FC0E4A6F1000FC0E4A63A4
|
||||||
|
:10040000E8D7460E4963E5D7ACA2FED74F0EAD6ED6
|
||||||
|
:10041000ACA2FED74B0EAD6EACA2FED7210EAD6ED8
|
||||||
|
:100420004A6B100046A30AD046914693070E476FC9
|
||||||
|
:10043000170ED26ED2AAFED7A19410004681468331
|
||||||
|
:10044000476B030EAD6E9A0ED26EF4D79E9C1000D1
|
||||||
|
:10045000F00ECF6E9E9081889680819895B005D0E1
|
||||||
|
:1004600095BE11D041B196900ED0030E00150BE150
|
||||||
|
:10047000070E416301D096901E0E476104D0050E11
|
||||||
|
:10048000416301D0969004EC01F0040E436504D062
|
||||||
|
:10049000958E95A0F5EC00F0412B95A006D0200E8E
|
||||||
|
:1004A000486103D0A00E47619680070E4165100099
|
||||||
|
:1004B00095A09690A00E4765472B050E476302D086
|
||||||
|
:1004C000E1EC00F0010EC26EC282C2B2FED7C4CF10
|
||||||
|
:1004D00048F095B00DD00D0EC26EC282C2B2FED7EA
|
||||||
|
:1004E000C80EC46005D046A103D0A00E47654707DB
|
||||||
|
:1004F000416B002B3B0E00651000006B022B3B0E86
|
||||||
|
:1005000002651000026B042B170E04651000046BCB
|
||||||
|
:10051000070E0661066B062B072B1C0E07651000E5
|
||||||
|
:10052000020E086310D0030E091503E11D0E0765C6
|
||||||
|
:100530001000010E076F082B120E08651000010E47
|
||||||
|
:10054000086F092B10001E0E07651000040E0863CB
|
||||||
|
:1005500001D0EFD7060E086301D0EBD7090E086370
|
||||||
|
:0C05600001D0E7D70B0E08631000E3D7B2
|
||||||
|
:00000001FF
|
||||||
1979
firebee1.lst
Normal file
1979
firebee1.lst
Normal file
File diff suppressed because it is too large
Load Diff
188
firebee1.map
Normal file
188
firebee1.map
Normal file
@@ -0,0 +1,188 @@
|
|||||||
|
MPLINK 4.35, Linker
|
||||||
|
Linker Map File - Created Fri Oct 01 13:06:43 2010
|
||||||
|
|
||||||
|
Section Info
|
||||||
|
Section Type Address Location Size(Bytes)
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
Reset_Vector code 0x000000 program 0x000002
|
||||||
|
.cinit romdata 0x000002 program 0x000002
|
||||||
|
HIGH_INT_VEC code 0x000008 program 0x000004
|
||||||
|
LOW_INT_VEC code 0x000018 program 0x00004a
|
||||||
|
.code code 0x000100 program 0x00046c
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Program Memory Usage
|
||||||
|
Start End
|
||||||
|
--------- ---------
|
||||||
|
0x000000 0x000003
|
||||||
|
0x000008 0x00000b
|
||||||
|
0x000018 0x000061
|
||||||
|
0x000100 0x00056b
|
||||||
|
1214 out of 33048 program addresses used, program memory utilization is 3%
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Symbols - Sorted by Name
|
||||||
|
Name Address Location Storage File
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
AD_ISR 0x00044c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
FEB 0x000526 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_ISR 0x000424 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_LE 0x00043c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
INT_HANDLER 0x000018 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
KALT_START 0x000100 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LADESTROM 0x0001d2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_OFF_POWER 0x0001da program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_ON_POWER 0x0001d6 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN 0x00019e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN2 0x0001ae program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_28_TAGE 0x000520 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_30_TAGE 0x00054c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MINUTEN 0x0004fa program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NEXT_MONTH 0x000532 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NON_SYNC 0x0003d2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_APRIL 0x000554 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_FEB 0x000546 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_JUNI 0x00055c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_SEP 0x000564 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NO_PROG 0x0003ac program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS 0x000486 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS2 0x0004aa program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGW 0x000498 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_AUS 0x0001c2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_EIN 0x0001b4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I 0x00046a program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I2 0x000478 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PROGRAM_MEMORY 0x00039a program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RESETEN 0x000256 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RTC_ISR 0x000450 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR 0x000288 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR1 0x0002a4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR2 0x0002b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR3 0x0002c8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR4 0x0002f6 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR5 0x000304 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR6 0x000312 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR7 0x000350 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR8 0x0003b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR9 0x0003bc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_RB3B2 0x000334 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_RB3BOK 0x000322 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC2 0x0003d8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC3 0x0003ea program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC4 0x0003fc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC_START 0x0003c0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT1 0x000408 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT2 0x000410 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT3 0x000418 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SCHALTJAHR 0x00052c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEKUNDEN 0x0004b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_2 0x0004ca program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_3 0x0004dc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_4 0x0004f0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_NPA 0x0004c4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEND_RTC_REG 0x000232 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SERIAL_OFF 0x0001de program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SERIAL_ON 0x0001ea program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
STUNDEN 0x000504 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TAGE_UND_TAG_DER_WOCHE 0x00050e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TASTE 0x000208 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_END 0x000250 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_JA 0x000222 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_OFF_POWER 0x000248 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER 0x00022c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER2 0x000238 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER3 0x00023e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR 0x00025e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR1 0x000276 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR2 0x000286 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR_FERTIG 0x00026e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WAIT_LVDOK 0x000434 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WARTEN 0x0001a8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WRITE_WORD_TO_HREGS 0x000390 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
YEAR 0x00053e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Symbols - Sorted by Address
|
||||||
|
Name Address Location Storage File
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
INT_HANDLER 0x000018 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
KALT_START 0x000100 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN 0x00019e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WARTEN 0x0001a8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN2 0x0001ae program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_EIN 0x0001b4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_AUS 0x0001c2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LADESTROM 0x0001d2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_ON_POWER 0x0001d6 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_OFF_POWER 0x0001da program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SERIAL_OFF 0x0001de program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SERIAL_ON 0x0001ea program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TASTE 0x000208 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_JA 0x000222 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER 0x00022c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEND_RTC_REG 0x000232 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER2 0x000238 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER3 0x00023e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_OFF_POWER 0x000248 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_END 0x000250 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RESETEN 0x000256 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR 0x00025e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR_FERTIG 0x00026e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR1 0x000276 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR2 0x000286 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR 0x000288 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR1 0x0002a4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR2 0x0002b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR3 0x0002c8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR4 0x0002f6 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR5 0x000304 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR6 0x000312 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_RB3BOK 0x000322 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_RB3B2 0x000334 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR7 0x000350 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WRITE_WORD_TO_HREGS 0x000390 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PROGRAM_MEMORY 0x00039a program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NO_PROG 0x0003ac program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR8 0x0003b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_ISR9 0x0003bc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC_START 0x0003c0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NON_SYNC 0x0003d2 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC2 0x0003d8 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC3 0x0003ea program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_SYNC4 0x0003fc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT1 0x000408 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT2 0x000410 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RX_WAIT3 0x000418 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_ISR 0x000424 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
WAIT_LVDOK 0x000434 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_LE 0x00043c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
AD_ISR 0x00044c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
RTC_ISR 0x000450 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I 0x00046a program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I2 0x000478 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS 0x000486 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGW 0x000498 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS2 0x0004aa program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEKUNDEN 0x0004b0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_NPA 0x0004c4 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_2 0x0004ca program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_3 0x0004dc program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_4 0x0004f0 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MINUTEN 0x0004fa program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
STUNDEN 0x000504 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
TAGE_UND_TAG_DER_WOCHE 0x00050e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_28_TAGE 0x000520 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
FEB 0x000526 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
SCHALTJAHR 0x00052c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NEXT_MONTH 0x000532 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
YEAR 0x00053e program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_FEB 0x000546 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_30_TAGE 0x00054c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_APRIL 0x000554 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_JUNI 0x00055c program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_SEP 0x000564 program static C:\FireBee\MLAB\firebee1\firebee1.asm
|
||||||
|
|
||||||
|
|
||||||
53
firebee1.mcp
Normal file
53
firebee1.mcp
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
[HEADER]
|
||||||
|
magic_cookie={66E99B07-E706-4689-9E80-9B2582898A13}
|
||||||
|
file_version=1.0
|
||||||
|
device=PIC18F4520
|
||||||
|
[PATH_INFO]
|
||||||
|
BuildDirPolicy=BuildDirIsProjectDir
|
||||||
|
dir_src=
|
||||||
|
dir_bin=
|
||||||
|
dir_tmp=
|
||||||
|
dir_sin=
|
||||||
|
dir_inc=
|
||||||
|
dir_lib=
|
||||||
|
dir_lkr=
|
||||||
|
[CAT_FILTERS]
|
||||||
|
filter_src=*.asm
|
||||||
|
filter_inc=*.h;*.inc
|
||||||
|
filter_obj=*.o
|
||||||
|
filter_lib=*.lib
|
||||||
|
filter_lkr=*.lkr
|
||||||
|
[CAT_SUBFOLDERS]
|
||||||
|
subfolder_src=
|
||||||
|
subfolder_inc=
|
||||||
|
subfolder_obj=
|
||||||
|
subfolder_lib=
|
||||||
|
subfolder_lkr=
|
||||||
|
[FILE_SUBFOLDERS]
|
||||||
|
file_000=.
|
||||||
|
file_001=.
|
||||||
|
[GENERATED_FILES]
|
||||||
|
file_000=no
|
||||||
|
file_001=no
|
||||||
|
[OTHER_FILES]
|
||||||
|
file_000=no
|
||||||
|
file_001=no
|
||||||
|
[FILE_INFO]
|
||||||
|
file_000=firebee1.asm
|
||||||
|
file_001=C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr
|
||||||
|
[SUITE_INFO]
|
||||||
|
suite_guid={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
suite_state=
|
||||||
|
[TOOL_SETTINGS]
|
||||||
|
TS{DD2213A8-6310-47B1-8376-9430CDFC013F}=
|
||||||
|
TS{BFD27FBA-4A02-4C0E-A5E5-B812F3E7707C}=/o"$(BINDIR_)$(TARGETBASE).cof" /M"$(BINDIR_)$(TARGETBASE).map" /W
|
||||||
|
TS{ADE93A55-C7C7-4D4D-A4BA-59305F7D0391}=
|
||||||
|
[INSTRUMENTED_TRACE]
|
||||||
|
enable=0
|
||||||
|
transport=0
|
||||||
|
format=0
|
||||||
|
[CUSTOM_BUILD]
|
||||||
|
Pre-Build=
|
||||||
|
Pre-BuildEnabled=1
|
||||||
|
Post-Build=
|
||||||
|
Post-BuildEnabled=1
|
||||||
71
firebee1.mcs
Normal file
71
firebee1.mcs
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
[Header]
|
||||||
|
MagicCookie={0b13fe8c-dfe0-40eb-8900-6712719559a7}
|
||||||
|
Version=1.0
|
||||||
|
[File000]
|
||||||
|
Location=C:\FireBee\MLAB\firebee1\firebee1.o
|
||||||
|
Folder=Intermediary
|
||||||
|
DeviceName=PIC18F4520
|
||||||
|
LanguageToolSuiteID={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
LanguageToolID={49D3CA3F-D9A3-4518-9943-226A347E8CC7}
|
||||||
|
LanguageToolLocation=C:\Program Files (x86)\Microchip\MPASM Suite\MPASMWIN.exe
|
||||||
|
PPAD=$(BINDIR)||$(TMPDIR)||$(AINDIR)||$(INCDIR)||$(LIBDIR)||$(LKRDIR)||
|
||||||
|
SOLK=<src>|firebee1.asm||<obj>||<lib>||<lkr>|C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr||
|
||||||
|
SuiteArgsString=
|
||||||
|
ToolArgsString=
|
||||||
|
TraceCmdString=
|
||||||
|
DebugOptions=
|
||||||
|
[File001]
|
||||||
|
Location=C:\FireBee\MLAB\firebee1\firebee1.err
|
||||||
|
Folder=Intermediary
|
||||||
|
DeviceName=PIC18F4520
|
||||||
|
LanguageToolSuiteID={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
LanguageToolID={49D3CA3F-D9A3-4518-9943-226A347E8CC7}
|
||||||
|
LanguageToolLocation=C:\Program Files (x86)\Microchip\MPASM Suite\MPASMWIN.exe
|
||||||
|
PPAD=$(BINDIR)||$(TMPDIR)||$(AINDIR)||$(INCDIR)||$(LIBDIR)||$(LKRDIR)||
|
||||||
|
SOLK=<src>|firebee1.asm||<obj>||<lib>||<lkr>|C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr||
|
||||||
|
SuiteArgsString=
|
||||||
|
ToolArgsString=
|
||||||
|
TraceCmdString=
|
||||||
|
DebugOptions=
|
||||||
|
[File002]
|
||||||
|
Location=C:\FireBee\MLAB\firebee1\firebee1.lst
|
||||||
|
Folder=Output
|
||||||
|
DeviceName=PIC18F4520
|
||||||
|
LanguageToolSuiteID={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
LanguageToolID={49D3CA3F-D9A3-4518-9943-226A347E8CC7}
|
||||||
|
LanguageToolLocation=C:\Program Files (x86)\Microchip\MPASM Suite\MPASMWIN.exe
|
||||||
|
PPAD=$(BINDIR)||$(TMPDIR)||$(AINDIR)||$(INCDIR)||$(LIBDIR)||$(LKRDIR)||
|
||||||
|
SOLK=<src>|firebee1.asm||<obj>||<lib>||<lkr>|C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr||
|
||||||
|
SuiteArgsString=
|
||||||
|
ToolArgsString=
|
||||||
|
TraceCmdString=
|
||||||
|
DebugOptions=
|
||||||
|
[File003]
|
||||||
|
Location=C:\FireBee\MLAB\firebee1\firebee1.cof
|
||||||
|
Folder=Output
|
||||||
|
DeviceName=PIC18F4520
|
||||||
|
LanguageToolSuiteID={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
LanguageToolID={96C98149-AA1B-4CF9-B967-FAE79CAB663C}
|
||||||
|
LanguageToolLocation=C:\Program Files (x86)\Microchip\MPASM Suite\mplink.exe
|
||||||
|
PPAD=$(BINDIR)||$(TMPDIR)||$(AINDIR)||$(INCDIR)||$(LIBDIR)||$(LKRDIR)||
|
||||||
|
SOLK=<src>|firebee1.asm||<obj>||<lib>||<lkr>|C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr||
|
||||||
|
SuiteArgsString=
|
||||||
|
ToolArgsString=/o"$(BINDIR_)$(TARGETBASE).cof" /M"$(BINDIR_)$(TARGETBASE).map" /W
|
||||||
|
TraceCmdString=
|
||||||
|
DebugOptions=
|
||||||
|
[File004]
|
||||||
|
Location=C:\FireBee\MLAB\firebee1\firebee1.hex
|
||||||
|
Folder=Output
|
||||||
|
DeviceName=PIC18F4520
|
||||||
|
LanguageToolSuiteID={6B3DAA78-59C1-46DD-B6AA-DBDAE4E06484}
|
||||||
|
LanguageToolID={96C98149-AA1B-4CF9-B967-FAE79CAB663C}
|
||||||
|
LanguageToolLocation=C:\Program Files (x86)\Microchip\MPASM Suite\mplink.exe
|
||||||
|
PPAD=$(BINDIR)||$(TMPDIR)||$(AINDIR)||$(INCDIR)||$(LIBDIR)||$(LKRDIR)||
|
||||||
|
SOLK=<src>|firebee1.asm||<obj>||<lib>||<lkr>|C:\Program Files (x86)\Microchip\MPASM Suite\LKR\18f4520_g.lkr||
|
||||||
|
SuiteArgsString=
|
||||||
|
ToolArgsString=/o"$(BINDIR_)$(TARGETBASE).cof" /M"$(BINDIR_)$(TARGETBASE).map" /W
|
||||||
|
TraceCmdString=
|
||||||
|
DebugOptions=
|
||||||
|
[TOOL_LOC_STAMPS]
|
||||||
|
tool_loc{49D3CA3F-D9A3-4518-9943-226A347E8CC7}=C:\Program Files (x86)\Microchip\MPASM Suite\MPASMWIN.exe
|
||||||
|
tool_loc{96C98149-AA1B-4CF9-B967-FAE79CAB663C}=C:\Program Files (x86)\Microchip\MPASM Suite\mplink.exe
|
||||||
BIN
firebee1.mcw
Normal file
BIN
firebee1.mcw
Normal file
Binary file not shown.
156
firebeei1.map
Normal file
156
firebeei1.map
Normal file
@@ -0,0 +1,156 @@
|
|||||||
|
MPLINK 4.33, Linker
|
||||||
|
Linker Map File - Created Mon Jan 11 14:35:58 2010
|
||||||
|
|
||||||
|
Section Info
|
||||||
|
Section Type Address Location Size(Bytes)
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
Reset_Vector code 0x000000 program 0x000004
|
||||||
|
.cinit romdata 0x000004 program 0x000002
|
||||||
|
LOW_INT_VEC code 0x000018 program 0x00004a
|
||||||
|
.code code 0x000100 program 0x00033c
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Program Memory Usage
|
||||||
|
Start End
|
||||||
|
--------- ---------
|
||||||
|
0x000000 0x000005
|
||||||
|
0x000018 0x000061
|
||||||
|
0x000100 0x00043b
|
||||||
|
908 out of 33048 program addresses used, program memory utilization is 2%
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Symbols - Sorted by Name
|
||||||
|
Name Address Location Storage File
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
AD_ISR 0x000326 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
FEB 0x0003ee program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_ISR 0x000300 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_LE 0x00031a program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
INT_HANDLER 0x00001e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
INT_HANDLER2 0x00002e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
KALT_START 0x000100 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LADESTROM 0x0001d2 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_OFF_POWER 0x0001de program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_ON_POWER 0x0001d8 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN 0x00019e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_28_TAGE 0x0003e6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_30_TAGE 0x000414 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MINUTEN 0x0003c0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NEXT_MONTH 0x0003fa program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NON_SYNC 0x0002ae program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_APRIL 0x00041e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_FEB 0x00040e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_JUNI 0x000428 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_SEP 0x000432 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS 0x000368 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS2 0x000380 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_AUS 0x0001c0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_EIN 0x0001a6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I 0x000346 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I2 0x000356 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR 0x000256 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR1 0x000268 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR2 0x000274 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_RFM 0x000290 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_RRFP 0x000280 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC2 0x0002b4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC3 0x0002c6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC4 0x0002d8 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC_START 0x00029c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_UNBEK 0x00027c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT1 0x0002e4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT2 0x0002ec program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT3 0x0002f4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RESETEN 0x000232 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RTC_ISR 0x000326 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SCHALTJAHR 0x0003f4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEKUNDEN 0x000386 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_2 0x0003ac program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_NPA 0x00039c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEND_RTC_REG 0x00020c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
STUNDEN 0x0003ca program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TAGE_UND_TAG_DER_WOCHE 0x0003d4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TASTE 0x0001e4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_END 0x00022c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_JA 0x0001fa program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_OFF_POWER 0x000224 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER 0x000206 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER2 0x000212 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER3 0x000218 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR 0x00023c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR1 0x000254 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR_FERTIG 0x00024c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
WAIT_LVDOK 0x000312 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
WARTEN 0x0001a0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
YEAR 0x000406 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Symbols - Sorted by Address
|
||||||
|
Name Address Location Storage File
|
||||||
|
--------- --------- --------- --------- ---------
|
||||||
|
INT_HANDLER 0x00001e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
INT_HANDLER2 0x00002e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
KALT_START 0x000100 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MAIN 0x00019e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
WARTEN 0x0001a0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_EIN 0x0001a6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_AUS 0x0001c0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LADESTROM 0x0001d2 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_ON_POWER 0x0001d8 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
LS_OFF_POWER 0x0001de program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TASTE 0x0001e4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_JA 0x0001fa program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER 0x000206 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEND_RTC_REG 0x00020c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER2 0x000212 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_ON_POWER3 0x000218 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_OFF_POWER 0x000224 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TG_END 0x00022c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RESETEN 0x000232 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR 0x00023c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR_FERTIG 0x00024c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TX_ISR1 0x000254 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR 0x000256 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR1 0x000268 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_ISR2 0x000274 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_UNBEK 0x00027c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_RRFP 0x000280 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_RFM 0x000290 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC_START 0x00029c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NON_SYNC 0x0002ae program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC2 0x0002b4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC3 0x0002c6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_SYNC4 0x0002d8 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT1 0x0002e4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT2 0x0002ec program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RC_WAIT3 0x0002f4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_ISR 0x000300 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
WAIT_LVDOK 0x000312 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
HLVD_LE 0x00031a program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
RTC_ISR 0x000326 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
AD_ISR 0x000326 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I 0x000346 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
POWER_OFF_I2 0x000356 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS 0x000368 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
PINGS2 0x000380 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEKUNDEN 0x000386 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_NPA 0x00039c program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SEK_2 0x0003ac program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MINUTEN 0x0003c0 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
STUNDEN 0x0003ca program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
TAGE_UND_TAG_DER_WOCHE 0x0003d4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_28_TAGE 0x0003e6 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
FEB 0x0003ee program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
SCHALTJAHR 0x0003f4 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NEXT_MONTH 0x0003fa program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
YEAR 0x000406 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_FEB 0x00040e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
MEHR_ALS_30_TAGE 0x000414 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_APRIL 0x00041e program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_JUNI 0x000428 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
NOT_SEP 0x000432 program static C:\firebee\MLAB\firebee1\firebee1.asm
|
||||||
|
|
||||||
|
|
||||||
125
readme.txt
Normal file
125
readme.txt
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
PS2 -> Atari /Amiga Mouse Adapter
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|
||||||
|
Version 1.4 July 2010
|
||||||
|
|
||||||
|
|
||||||
|
Due to the short supply of mice for the Atari computers I decided to build an adapter that would allow me to use a serial mouse on my Atari, but even these are getting a bit old now, so I got the soldering iron out again and here's the result. A PS2 Mouse adapter for the Atari. It supports a standard PS2 mouse with 2 or 3 buttons and can also be used with the Microsoft optical IntelliMouse that comes with a USB to PS2 adapter. The middle button on the PS2 mouse is used as a left click and hold function for easy selection. Click the middle button again to release. Now for the bad news, for some reason Microsoft mice don't support the middle button in standard PS2 mode. :-(
|
||||||
|
|
||||||
|
Please don't shout at me all you Atari users but as an added feature if you change a link then the adapter can be used with an Amiga as well.
|
||||||
|
|
||||||
|
|
||||||
|
All files, programs etc contained in this archive are copright 2010 by Tom Kirk. Personal use is allowed but any commercial use is not allowed. Please feel free to use my work but don't rip me off.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Files in this archive.
|
||||||
|
~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
readme.txt This text file
|
||||||
|
circuit.bmp Picture of circuit in bitmap format
|
||||||
|
PS2Atari_v1_4.hex Object code of the PIC16F84 program in Intel hex
|
||||||
|
PS2Atari_v1_4.asm Source code of the PIC16F84 program
|
||||||
|
pcbtop.bmp Top layer of the PCB in bitmap format
|
||||||
|
pcbbot.bmp Bottom layer of the PCB in bitmap format
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Technical Details.
|
||||||
|
~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
When the PS2 mouse is moved or a button changes state a packet of data is sent, my circuit decodes this data and then simulates the Atari mouse.
|
||||||
|
|
||||||
|
The circuit consists of a single microcontroller that contains a program to do the conversion. The circuit is shown in the file circuit.bmp
|
||||||
|
|
||||||
|
The microcontroller (PIC) can be either a PIC16C84 or PIC16F84 or PIC16F84A.
|
||||||
|
|
||||||
|
The PIC (IC1) needs to be programmed with the program.
|
||||||
|
The program is supplied in two forms PS2Atari_v1_4.hex is an object code file in Intel hex and can be read by most programmers capable of programming the PIC
|
||||||
|
|
||||||
|
PS2Atari_v1_4.asm is the source code of the program and can be assembled with the free MPLAB / MPASM software from Microchip if you wish to create your own object file. Note needs "Disable case sensitivity" under build options setting in MPLAB to assemble without errors.
|
||||||
|
|
||||||
|
The PIC should be programmed with oscillator as XT, watchdog disabled, powerup timer enabled and code protection off. (No point code protecting a freely available program.)
|
||||||
|
|
||||||
|
The source code and object code is compatible with all the PIC microcontrollers listed above.
|
||||||
|
|
||||||
|
I've built mine using a printed circuit board but it's small enough to be built using a small piece of stripboard.
|
||||||
|
|
||||||
|
On my PCB I have a 6 pin mini din socket at one end and a 9 pin D type socket at the other. I can then use a standard port extender lead to connect to the Atari. I've found that a 9 pin PC serial extension lead can also be used for this as well if you remove the fastening screws.
|
||||||
|
|
||||||
|
If you decide to build one on a piece of stripboard it will be easier to use cable mounted sockets as PCB types don't fit onto a stripboard.
|
||||||
|
|
||||||
|
Once built the board can be mounted into a small plastic box.
|
||||||
|
|
||||||
|
No special software is required on the Atari and it will work with all software.
|
||||||
|
Your favourite mouse accelerator program may be used if required.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Parts list.
|
||||||
|
~~~~~~~~~~~
|
||||||
|
|
||||||
|
IC1 PIC16F84A or PIC16F84 or PIC16C84
|
||||||
|
|
||||||
|
Fi1 4 MHz Ceramic resonator
|
||||||
|
|
||||||
|
R1 10K
|
||||||
|
R2 10K
|
||||||
|
|
||||||
|
C1 4.7 uF
|
||||||
|
C2 0.1 uF
|
||||||
|
|
||||||
|
All capacitors should be rated at 16V or more.
|
||||||
|
|
||||||
|
CN1 6 pin mini din PCB mounting socket
|
||||||
|
CN2 9 Pin D type PCB mounting socket
|
||||||
|
|
||||||
|
|
||||||
|
JP1 3 pin header and 2 way link
|
||||||
|
|
||||||
|
|
||||||
|
If building on a piece of stripboard I suggest using cable mounting types of connectors and use a small piece of multicore cable between the sockets and the stripboard. You will find the PCB sockets do not fit on a piece of stripboard.
|
||||||
|
|
||||||
|
If you don't need the switchable Atari/Amiga support forget the 3 pin header and just use a wire link instead.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
History.
|
||||||
|
~~~~~~~~
|
||||||
|
|
||||||
|
Version 1.4 July 2010
|
||||||
|
Unused Pin RA4 now correctly set as an imput.
|
||||||
|
(Pin is tied to +5V on PCB for easier PCB routing.)
|
||||||
|
My oversight when transfering from prototype to PCB.
|
||||||
|
Thanks to Luciano for informing me.
|
||||||
|
|
||||||
|
Version 1.3 Released March 2010
|
||||||
|
Corrected a bug in button routine preventing both buttons being active together under certain conditions.
|
||||||
|
Thanks to Oliver Fleischmann for informing me.
|
||||||
|
(Can't believe it taken 6 Years for this bug to show itself!!)
|
||||||
|
|
||||||
|
Version 1.2 Released March 2009
|
||||||
|
Changed left/right button outputs to fake open collector.
|
||||||
|
Needed to stop conflits when using a joystick pluged into other port.
|
||||||
|
|
||||||
|
Version 1.1 Released September 2004.
|
||||||
|
Added support for the Amiga and added the middle button support.
|
||||||
|
|
||||||
|
Version 1.0 Never released.
|
||||||
|
My original version for the Atari only.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Help.
|
||||||
|
~~~~~
|
||||||
|
|
||||||
|
If you need further information or help then contact me at tgkirk@aol.com
|
||||||
|
|
||||||
|
Please allow a few days for a reply as I have other commitments as well.
|
||||||
|
|
||||||
|
Tom Kirk July 2010
|
||||||
|
|
||||||
|
P.S. I also have on my web site a Playstation controller to Atari adapter and a PC viewer for Atari format picture files.
|
||||||
|
|
||||||
|
http://www.tgkirk.110mb.com
|
||||||
Reference in New Issue
Block a user