forked from len0rd/rockbox
Slightly better instruction order, added comment.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16833 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
91a564e4b9
commit
06ec18d93f
2 changed files with 11 additions and 7 deletions
|
|
@ -32,6 +32,7 @@
|
||||||
/* Output 8 bits to the LCD. Instruction order is devised to maximize the
|
/* Output 8 bits to the LCD. Instruction order is devised to maximize the
|
||||||
* delay between changing the data line and the CLK L->H transition, which
|
* delay between changing the data line and the CLK L->H transition, which
|
||||||
* makes the LCD controller sample DATA.
|
* makes the LCD controller sample DATA.
|
||||||
|
* Requires CLK = 1 on entry.
|
||||||
*
|
*
|
||||||
* Custom calling convention:
|
* Custom calling convention:
|
||||||
* %a0 - GPIO_OUT_ADDR
|
* %a0 - GPIO_OUT_ADDR
|
||||||
|
|
@ -63,8 +64,8 @@
|
||||||
bcc.s 1f
|
bcc.s 1f
|
||||||
eor.l %d6, %d0 /* 1: Flip data bit */
|
eor.l %d6, %d0 /* 1: Flip data bit */
|
||||||
1:
|
1:
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
bra.w .wr_bit7
|
bra.w .wr_bit7
|
||||||
|
|
||||||
|
|
@ -72,6 +73,7 @@
|
||||||
/* Output 16 bits to the LCD. Instruction order is devised to maximize the
|
/* Output 16 bits to the LCD. Instruction order is devised to maximize the
|
||||||
* delay between changing the data line and the CLK L->H transition, which
|
* delay between changing the data line and the CLK L->H transition, which
|
||||||
* makes the LCD controller sample DATA.
|
* makes the LCD controller sample DATA.
|
||||||
|
* Requires CLK = 1 on entry.
|
||||||
*
|
*
|
||||||
* Custom calling convention:
|
* Custom calling convention:
|
||||||
* %a0 - GPIO_OUT_ADDR
|
* %a0 - GPIO_OUT_ADDR
|
||||||
|
|
@ -102,8 +104,8 @@
|
||||||
bcc.s 1f
|
bcc.s 1f
|
||||||
eor.l %d6, %d0 /* 1: Flip data bit */
|
eor.l %d6, %d0 /* 1: Flip data bit */
|
||||||
1:
|
1:
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
nop
|
nop
|
||||||
|
|
||||||
|
|
@ -113,8 +115,8 @@
|
||||||
eor.l %d6, %d0
|
eor.l %d6, %d0
|
||||||
1:
|
1:
|
||||||
move.l %d1, (%a0) /* Set CLK = 1 (delayed) */
|
move.l %d1, (%a0) /* Set CLK = 1 (delayed) */
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0)
|
move.l %d0, (%a0)
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
.endm
|
.endm
|
||||||
bit_out
|
bit_out
|
||||||
|
|
|
||||||
|
|
@ -32,6 +32,7 @@
|
||||||
/* Output 8 bits to the LCD. Instruction order is devised to maximize the
|
/* Output 8 bits to the LCD. Instruction order is devised to maximize the
|
||||||
* delay between changing the data line and the CLK L->H transition, which
|
* delay between changing the data line and the CLK L->H transition, which
|
||||||
* makes the LCD controller sample DATA.
|
* makes the LCD controller sample DATA.
|
||||||
|
* Requires CLK = 1 on entry.
|
||||||
*
|
*
|
||||||
* Custom calling convention:
|
* Custom calling convention:
|
||||||
* %a0 - GPIO_OUT_ADDR
|
* %a0 - GPIO_OUT_ADDR
|
||||||
|
|
@ -63,8 +64,8 @@
|
||||||
bcc.s 1f
|
bcc.s 1f
|
||||||
eor.l %d6, %d0 /* 1: Flip data bit */
|
eor.l %d6, %d0 /* 1: Flip data bit */
|
||||||
1:
|
1:
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
bra.w .wr_bit7
|
bra.w .wr_bit7
|
||||||
|
|
||||||
|
|
@ -72,6 +73,7 @@
|
||||||
/* Output 16 bits to the LCD. Instruction order is devised to maximize the
|
/* Output 16 bits to the LCD. Instruction order is devised to maximize the
|
||||||
* delay between changing the data line and the CLK L->H transition, which
|
* delay between changing the data line and the CLK L->H transition, which
|
||||||
* makes the LCD controller sample DATA.
|
* makes the LCD controller sample DATA.
|
||||||
|
* Requires CLK = 1 on entry.
|
||||||
*
|
*
|
||||||
* Custom calling convention:
|
* Custom calling convention:
|
||||||
* %a0 - GPIO_OUT_ADDR
|
* %a0 - GPIO_OUT_ADDR
|
||||||
|
|
@ -102,8 +104,8 @@
|
||||||
bcc.s 1f
|
bcc.s 1f
|
||||||
eor.l %d6, %d0 /* 1: Flip data bit */
|
eor.l %d6, %d0 /* 1: Flip data bit */
|
||||||
1:
|
1:
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
move.l %d0, (%a0) /* Output new state and set CLK = 0*/
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
nop
|
nop
|
||||||
|
|
||||||
|
|
@ -113,8 +115,8 @@
|
||||||
eor.l %d6, %d0
|
eor.l %d6, %d0
|
||||||
1:
|
1:
|
||||||
move.l %d1, (%a0) /* Set CLK = 1 (delayed) */
|
move.l %d1, (%a0) /* Set CLK = 1 (delayed) */
|
||||||
move.l %d0, %d1
|
|
||||||
move.l %d0, (%a0)
|
move.l %d0, (%a0)
|
||||||
|
move.l %d0, %d1
|
||||||
eor.l %d7, %d1
|
eor.l %d7, %d1
|
||||||
.endm
|
.endm
|
||||||
bit_out
|
bit_out
|
||||||
|
|
@ -310,7 +312,7 @@ lcd_write_data:
|
||||||
movem.l (%sp), %d2-%d4/%d6-%d7/%a2-%a3
|
movem.l (%sp), %d2-%d4/%d6-%d7/%a2-%a3
|
||||||
lea.l (7*4, %sp), %sp
|
lea.l (7*4, %sp), %sp
|
||||||
rts
|
rts
|
||||||
|
|
||||||
|
|
||||||
/*** The following functions are only needed for main LCDs ***/
|
/*** The following functions are only needed for main LCDs ***/
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue