![]() |
Anwendungen von AVR-Einchip-Mikrocontrollern AT90S, ATtiny, ATmega und ATxmega Anzeige für geregeltem OpAmp sync-Signale mit ATtiny24 |
![]() |
.equ clock = 1000000 ; Taktfrequenz Prozessor in Hz
; LCD-Groesse:
.equ LcdLines = 4 ; Anzahl Zeilen (1, 2, 4)
.equ LcdCols = 20 ; Anzahl Zeichen pro Zeile (8..24)
; LCD-Ansteuerung
.equ LcdBits = 4 ; Busbreite (4 oder 8)
; Wenn 4-Bit-Ansteuerung:
.equ Lcd4High = 1 ; Busnibble (1=Oberes, 0=Unteres)
.equ LcdWait = 0 ; Ansteuerung (0 mit Busy, 1 mit Warteschleifen)
; LCD-Datenports
.equ pLcdDO = PORTA ; Daten-Ausgabe-Port
.equ pLcdDD = DDRA ; Daten-Richtungs-Port
; LCD-Kontrollports und -pins
.equ pLcdCEO = PORTB ; Control E Ausgabe-Port
.equ bLcdCEO = PORTB2 ; Controll E Ausgabe-Portpin
.equ pLcdCED = DDRB ; Control E Richtungs-Port
.equ bLcdCED = DDB2 ; Control E Richtungs-Portpin
.equ pLcdCRSO = PORTB ; Control RS Ausgabe-Port
.equ bLcdCRSO = PORTB0 ; Controll RS Ausgabe-Portpin
.equ pLcdCRSD = DDRB ; Control RS Richtungs-Port
.equ bLcdCRSD = DDB0 ; Control RS Richtungs-Portpin
; Wenn LcdWait = 0:
.equ pLcdDI = PINA ; Daten-Input-Port
.equ pLcdCRWO = PORTB ; Control RW Ausgabe-Port
.equ bLcdCRWO = PORTB1 ; Control RW Ausgabe-Portpin
.equ pLcdCRWD = DDRB ; Control RW Richtungs-Port
.equ bLcdCRWD = DDB1 ; Control RW Richtungs-Portpin
Weitere Einstellungen im Quellcode sind:
Seitenanfang | Index | Hardware | Software |
---|