summaryrefslogtreecommitdiffstats
path: root/rbutil
diff options
context:
space:
mode:
authorJack Halpin <jack.halpin@gmail.com>2010-02-09 22:29:23 +0000
committerJack Halpin <jack.halpin@gmail.com>2010-02-09 22:29:23 +0000
commit74c48090ac8dd2e52cbee7f76e770f2e1621e8bf (patch)
tree9138b9376e4cc589078e5cd82dc38fbc00be0b40 /rbutil
parent3e4e67b408239ea8cfdc201ca1ec031eb4dbc93d (diff)
downloadrockbox-74c48090ac8dd2e52cbee7f76e770f2e1621e8bf.tar.gz
rockbox-74c48090ac8dd2e52cbee7f76e770f2e1621e8bf.tar.bz2
rockbox-74c48090ac8dd2e52cbee7f76e770f2e1621e8bf.zip
Sansa Clip+: Unset pin B0 correctly in dualboot.S
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24573 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'rbutil')
-rw-r--r--rbutil/mkamsboot/dualboot.c4
-rw-r--r--rbutil/mkamsboot/dualboot/dualboot.S12
2 files changed, 8 insertions, 8 deletions
diff --git a/rbutil/mkamsboot/dualboot.c b/rbutil/mkamsboot/dualboot.c
index 998d0ed7e6..25c0c4e48f 100644
--- a/rbutil/mkamsboot/dualboot.c
+++ b/rbutil/mkamsboot/dualboot.c
@@ -126,8 +126,8 @@ unsigned char dualboot_clipplus[256] = {
0x00, 0x10, 0x90, 0xe5, 0x01, 0x18, 0x81, 0xe3, 0x00, 0x10, 0x80, 0xe5, 0x80, 0x00, 0x9f, 0xe5,
0x01, 0x10, 0xa0, 0xe3, 0x00, 0x14, 0x80, 0xe5, 0x04, 0x10, 0x80, 0xe5, 0x7d, 0x1f, 0xa0, 0xe3,
0x01, 0x10, 0x51, 0xe2, 0xfd, 0xff, 0xff, 0x1a, 0x68, 0x00, 0x9f, 0xe5, 0x20, 0x10, 0x90, 0xe5,
- 0x64, 0x00, 0x9f, 0xe5, 0x08, 0x20, 0x90, 0xe5, 0x01, 0x20, 0x82, 0xe1, 0x50, 0x00, 0x9f, 0xe5,
- 0x00, 0x10, 0xa0, 0xe3, 0x00, 0x14, 0x80, 0xe5, 0x00, 0x10, 0x80, 0xe5, 0x00, 0x00, 0x52, 0xe3,
+ 0x64, 0x00, 0x9f, 0xe5, 0x08, 0x20, 0x90, 0xe5, 0x01, 0x20, 0x82, 0xe1, 0x00, 0x10, 0xa0, 0xe3,
+ 0x04, 0x10, 0x80, 0xe5, 0x48, 0x00, 0x9f, 0xe5, 0x00, 0x14, 0x80, 0xe5, 0x00, 0x00, 0x52, 0xe3,
0x02, 0x00, 0x00, 0x1a, 0x8c, 0x00, 0x1f, 0xe5, 0x8c, 0x10, 0x1f, 0xe5, 0x01, 0x00, 0x00, 0xea,
0xa0, 0x00, 0x1f, 0xe5, 0xa0, 0x10, 0x1f, 0xe5, 0x01, 0x40, 0x43, 0xe0, 0x01, 0x20, 0x50, 0xe4,
0x01, 0x20, 0x43, 0xe4, 0x04, 0x00, 0x53, 0xe1, 0xfb, 0xff, 0xff, 0x1a, 0x01, 0x00, 0x83, 0xe2,
diff --git a/rbutil/mkamsboot/dualboot/dualboot.S b/rbutil/mkamsboot/dualboot/dualboot.S
index 10f943f1e6..dfda5b3bf0 100644
--- a/rbutil/mkamsboot/dualboot/dualboot.S
+++ b/rbutil/mkamsboot/dualboot/dualboot.S
@@ -161,7 +161,7 @@ uclcopy:
ldr r0, =GPIOB
mov r1, #(1<<0) @ pin 0
str r1, [r0, #0x400] @ GPIOB(0) = output
- str r1, [r0, #4*(1<<0)] @ write 1 to GPIOB(0)
+ str r1, [r0, #4*(1<<0)] @ write 1 to GPIOB(0) B0 set
mov r1, #500 @ small delay
1: subs r1, r1, #1
@@ -176,13 +176,13 @@ uclcopy:
orr r2, r2, r1 @ c3 || A1
- @ restore GPIOB_DIR(0)
- ldr r0, =GPIOB
+ @ Unset GPIOB(0)
mov r1, #0
- str r1, [r0, #0x400] @ Restore GPIOB_DIR to 0x00
+ str r1, [r0, #4*(1<<0)] @ write 0 to GPIOB(0) B0 unset
- @ Unset GPIOB(0)
- str r1, [r0, #4*(0<<0)] @ write 0 to GPIOB(0)
+ @ restore GPIOB_DIR to 0x00
+ ldr r0, =GPIOB
+ str r1, [r0, #0x400] @ Restore GPIOB_DIR to 0x00
cmp r2, #0 @ test input from pins
bne boot_of @ branch directly to OF if either pin high