\r
\r
;copy from avr/virt_ports.asm:\r
+;\r
; Port Direction Function\r
;hex dez\r
;-------------------------------------------------------------------------\r
-;00 0 in - Con status. \r
+;00 0 in - Con status. (deprecated)\r
; Returns 0xFF if the UART has a byte, 0 otherwise.\r
;01 1 in/out - Console input, aka UDR. / Console Output\r
;02 2 out - Console Output (deprecated)\r
-;03 3 in - "UART" status: bit 0 = rx, bit 1 = tx\r
-;04 4 in - "UART" data register, no wait\r
+;03 3 in - "UART" status: bit 0 = rx (UARTRXRDY) \r
+; bit 1 = tx (UARTTXRDY)\r
+;03 3 out - "UART" control (tbd)\r
+;04 4 in/out - "UART" data register, no wait\r
;\r
;------------------------ Virtual I2C interface --------------------------\r
;05 5 out - Control Port: 1 = Start read operation\r
; 0x00 = ok, 0xff = error (--> Bad Sector)\r
;\r
;\r
+;------------------------ ADC Interface ----------------------------------\r
+;17-19 23,25 in - ADC Channels 6,7 and 8 (Temp-Sensor) \r
+; ADC 6,7 only Devices in 32 pin Case (TQFP/MLF)\r
+; 8 Bit only\r
+; Fixed ADC clock (FCPU/128, 156KHz at 20MHz CPU)\r
+; Vref = VCC\r
+;20,21 in - ADC: Measure VCC\r
;\r
;------------------------ Wall Clock and Timers --------------------------\r
;40 64-71 in/out - Timer/Clock control. \r
;\r
;47-4D clock - BCD format: ss, mm, hh, DD, MM, YYl, YYh\r
;\r
+;4F debug - start/stop trace, print stack, ...\r
+;\r
;------------------------ Ports ------------------------------------------\r
;80-87 in/out - Port-Expander PCF8574 (max. 8 Chips)\r
;88-8F in/out - Port-Expander PCF8574A (not implemented yet!)\r
\r
+;-----------------------------------------------------------------------\r
+; Z80/8080 Virtual Ports\r
+\r
+UARTDR equ 1 ;UART Data Register\r
+UARTCSR equ 3 ;UART Control/Status Register\r
+UARTRXRDY equ 01h ;RxReady Status Bit Mask\r
+UARTTXRDY equ 02h ;TxReady Status Bit Mask\r
\r
READ_FUNC equ 7\r
WRITE_FUNC equ 6\r
StartTraceCmd equ 1\r
StopTraceCmd equ 0\r
\r
-\r
-\r
-\r
-\r