dip.inc
author Tero Marttila <terom@fixme.fi>
Mon, 23 Aug 2010 01:07:26 +0300
changeset 36 06e1e554acbb
parent 30 5226e512755c
permissions -rw-r--r--
Rename Matrix_ShiftRight to ShiftLeft, improve matrix.inc documentation
;;
;; Reading DIP switches from SPI
;;

.set DIP_BUFFER = spi_inbuf + 1

;; Read state of dip switches
;;  Output: r16
DIP_Read8:
		; update
;		rcall		SPI_SendRecv
		
		; get bits
		lds			r16, DIP_BUFFER

		ret