sovereignx/asm/librtc.s

1182 lines
18 KiB
ArmAsm
Raw Normal View History

2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetReadWrite
; void RTC_SetReadWrite()
RTC_SetReadWrite: ; 82E2150
2015-10-06 15:00:49 +01:00
push {r7,lr}
mov r7, sp
2015-11-27 23:32:24 +00:00
bl RTC_SetReadWriteInternal
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
pop {r7}
pop {r0}
bx r0
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetReadWrite
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetReadOnly
; void RTC_SetReadOnly()
RTC_SetReadOnly: ; 82E2168
2015-10-06 15:00:49 +01:00
push {r7,lr}
mov r7, sp
2015-11-27 23:32:24 +00:00
bl RTC_SetReadOnlyInternal
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
pop {r7}
pop {r0}
bx r0
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetReadOnly
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_Init
; u8 RTC_Init()
RTC_Init: ; 82E2180
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x10
mov r7, sp
adds r1, r7, 0x4
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_GetControlReg
2015-10-06 15:00:49 +01:00
lsls r1, r0, 24
lsrs r0, r1, 24
cmp r0, 0
2015-10-10 11:50:53 +01:00
bne @082E219A
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E224E
@082E219A:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
movs r1, 0
strb r1, [r0]
adds r0, r7, 0x4
ldrb r1, [r0, 0x7]
movs r2, 0xC0
adds r0, r1, 0
ands r0, r2
adds r2, r0, 0
lsls r1, r2, 24
lsrs r0, r1, 24
cmp r0, 0x80
2015-10-10 11:50:53 +01:00
beq @082E21CA
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0, 0x7]
movs r2, 0xC0
adds r0, r1, 0
ands r0, r2
adds r2, r0, 0
lsls r1, r2, 24
lsrs r0, r1, 24
cmp r0, 0
2015-10-10 11:50:53 +01:00
bne @082E21E8
b @082E21CA
@082E21CA:
2015-11-27 23:32:24 +00:00
bl RTC_Reset
2015-10-06 15:00:49 +01:00
lsls r1, r0, 24
lsrs r0, r1, 24
cmp r0, 0
2015-10-10 11:50:53 +01:00
bne @082E21DA
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E224E
@082E21DA:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0
adds r0, r7, 0
adds r1, r7, 0
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
@082E21E8:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_GetTime
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0, 0x6]
movs r2, 0x80
adds r0, r1, 0
ands r0, r2
adds r2, r0, 0
lsls r1, r2, 24
lsrs r0, r1, 24
cmp r0, 0
2015-10-10 11:50:53 +01:00
beq @082E2236
2015-11-27 23:32:24 +00:00
bl RTC_Reset
2015-10-06 15:00:49 +01:00
lsls r1, r0, 24
lsrs r0, r1, 24
cmp r0, 0
2015-10-10 11:50:53 +01:00
bne @082E2228
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
ldrb r1, [r0]
lsls r0, r1, 4
adds r1, r0, 0
movs r2, 0xF
adds r0, r1, 0
bics r0, r2
adds r1, r0, 0
lsls r0, r1, 24
lsrs r1, r0, 24
adds r0, r1, 0
2015-10-10 11:50:53 +01:00
b @082E224E
@082E2228:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0
adds r0, r7, 0
adds r1, r7, 0
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
@082E2236:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
ldrb r1, [r0]
lsls r0, r1, 4
adds r1, r0, 0
movs r2, 0x1
adds r0, r1, 0
orrs r0, r2
adds r1, r0, 0
lsls r0, r1, 24
lsrs r1, r0, 24
adds r0, r1, 0
2015-10-10 11:50:53 +01:00
b @082E224E
@082E224E:
2015-10-06 15:00:49 +01:00
add sp, 0x10
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_Init
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_Reset
; u8 RTC_Reset()
RTC_Reset: ; 82E2258
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x10
mov r7, sp
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E2270
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E22D4
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2270:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x60
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
adds r0, r7, 0x4
ldrb r1, [r0, 0x7]
movs r2, 0
ands r1, r2
adds r2, r1, 0
movs r3, 0x40
adds r1, r2, 0
orrs r1, r3
adds r2, r1, 0
strb r2, [r0, 0x7]
adds r1, r7, 0x4
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_SetControlReg
2015-10-06 15:00:49 +01:00
adds r1, r7, 0
strb r0, [r1]
adds r0, r7, 0
ldrb r1, [r0]
adds r0, r1, 0
2015-10-10 11:50:53 +01:00
b @082E22D4
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E22D4:
2015-10-06 15:00:49 +01:00
add sp, 0x10
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_Reset
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_GetControlReg
; u8 RTC_GetControlReg(struct RtcInfo *rtc)
RTC_GetControlReg: ; 82E22DC
2015-10-06 15:00:49 +01:00
push {r4,r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E22F4
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E23A0
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E22F4:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x63
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:32:24 +00:00
bl RTC_ReadByte
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
strb r0, [r1]
ldr r0, [r7]
adds r1, r7, 0x4
ldrb r2, [r1]
movs r3, 0xC0
adds r1, r2, 0
ands r1, r3
adds r2, r7, 0x4
ldrb r3, [r2]
movs r4, 0x20
adds r2, r3, 0
ands r2, r4
adds r4, r2, 0
lsls r3, r4, 24
lsrs r2, r3, 24
lsrs r3, r2, 3
adds r2, r3, 0
orrs r1, r2
adds r2, r7, 0x4
ldrb r3, [r2]
movs r4, 0x8
adds r2, r3, 0
ands r2, r4
adds r4, r2, 0
lsls r3, r4, 24
lsrs r2, r3, 24
lsrs r3, r2, 2
adds r2, r3, 0
orrs r1, r2
adds r2, r7, 0x4
ldrb r3, [r2]
movs r4, 0x2
adds r2, r3, 0
ands r2, r4
adds r4, r2, 0
lsls r3, r4, 24
lsrs r2, r3, 24
lsrs r3, r2, 1
adds r2, r3, 0
orrs r1, r2
ldrb r2, [r0, 0x7]
movs r3, 0
ands r2, r3
adds r3, r2, 0
adds r2, r3, 0
orrs r2, r1
adds r1, r2, 0
strb r1, [r0, 0x7]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E23A0
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E23A0:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r4,r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_GetControlReg
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetControlReg
; u8 RTC_SetControlReg(struct RtcInfo *rtc)
RTC_SetControlReg: ; 82E23A8
2015-10-06 15:00:49 +01:00
push {r4,r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E23C0
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E2448
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E23C0:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
adds r0, r7, 0x4
ldr r1, [r7]
ldrb r2, [r1, 0x7]
movs r3, 0x4
adds r1, r2, 0
ands r1, r3
adds r2, r1, 0
lsls r1, r2, 3
ldr r2, [r7]
ldrb r3, [r2, 0x7]
movs r4, 0x2
adds r2, r3, 0
ands r2, r4
adds r3, r2, 0
lsls r2, r3, 2
adds r3, r2, 0
movs r4, 0x40
adds r2, r3, 0
orrs r2, r4
orrs r1, r2
ldr r2, [r7]
ldrb r3, [r2, 0x7]
movs r4, 0x1
adds r2, r3, 0
ands r2, r4
adds r3, r2, 0
lsls r2, r3, 1
orrs r1, r2
adds r2, r1, 0
strb r2, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x62
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_WriteByteReversed
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E2448
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2448:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r4,r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetControlReg
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_GetDateTime
; u8 RTC_GetDateTime(u8 *rtcDateTime)
RTC_GetDateTime: ; 82E2450
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E2468
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E24F8
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2468:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x65
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
adds r0, r7, 0x4
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E2492:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
cmp r1, 0x6
2015-10-10 11:50:53 +01:00
bls @082E24A8
b @082E24C6
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E24A8:
2015-11-27 23:32:24 +00:00
bl RTC_ReadByte
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
ldrb r2, [r1]
ldr r3, [r7]
adds r1, r2, r3
strb r0, [r1]
adds r1, r7, 0x4
adds r0, r7, 0x4
adds r1, r7, 0x4
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E2492
@082E24C6:
2015-10-06 15:00:49 +01:00
ldr r1, [r7]
adds r0, r1, 0x4
ldr r2, [r7]
adds r1, r2, 0x4
ldrb r2, [r1]
movs r3, 0x7F
adds r1, r2, 0
ands r1, r3
adds r2, r1, 0
strb r2, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E24F8
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E24F8:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_GetDateTime
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetDateTime
; u8 RTC_SetDateTime(u8 *rtcDateTime)
RTC_SetDateTime: ; 82E2500
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E2518
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E2594
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2518:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x64
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E253C:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
cmp r1, 0x6
2015-10-10 11:50:53 +01:00
bls @082E2554
b @082E2574
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2554:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
ldr r2, [r7]
adds r0, r1, r2
ldrb r1, [r0]
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_WriteByteReversed
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
adds r0, r7, 0x4
adds r1, r7, 0x4
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E253C
@082E2574:
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E2594
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2594:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetDateTime
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_GetTime
; u8 RTC_GetTime(u8 *rtcTime)
RTC_GetTime: ; 82E259C
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E25B4
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E2648
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E25B4:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x67
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
adds r0, r7, 0x4
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E25DE:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
cmp r1, 0x2
2015-10-10 11:50:53 +01:00
bls @082E25F4
b @082E2614
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E25F4:
2015-11-27 23:32:24 +00:00
bl RTC_ReadByte
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
ldrb r2, [r1]
ldr r3, [r7]
adds r1, r2, r3
adds r2, r1, 0x4
strb r0, [r2]
adds r1, r7, 0x4
adds r0, r7, 0x4
adds r1, r7, 0x4
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E25DE
@082E2614:
2015-10-06 15:00:49 +01:00
ldr r1, [r7]
adds r0, r1, 0x4
ldr r2, [r7]
adds r1, r2, 0x4
ldrb r2, [r1]
movs r3, 0x7F
adds r1, r2, 0
ands r1, r3
adds r2, r1, 0
strb r2, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E2648
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2648:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_GetTime
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetTime
; u8 RTC_SetTime(u8 *rtcTime)
RTC_SetTime: ; 82E2650
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x8
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E2668
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E26E4
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2668:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x66
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E268C:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
cmp r1, 0x2
2015-10-10 11:50:53 +01:00
bls @082E26A4
b @082E26C6
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E26A4:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
ldr r2, [r7]
adds r0, r1, r2
adds r1, r0, 0x4
ldrb r2, [r1]
adds r0, r2, 0
2015-11-27 23:32:24 +00:00
bl RTC_WriteByteReversed
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
adds r0, r7, 0x4
adds r1, r7, 0x4
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E268C
@082E26C6:
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E26E4
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E26E4:
2015-10-06 15:00:49 +01:00
add sp, 0x8
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetTime
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetUnknownData
; u8 RTC_SetUnknownData(struct RtcInfo *rtc)
RTC_SetUnknownData: ; 82E26EC
2015-10-06 15:00:49 +01:00
push {r4,r7,lr}
sub sp, 0xC
mov r7, sp
str r0, [r7]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bne @082E2704
2015-10-06 15:00:49 +01:00
movs r0, 0
2015-10-10 11:50:53 +01:00
b @082E2818
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2704:
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strb r1, [r0]
adds r0, r7, 0
adds r0, 0x8
ldr r1, [r7]
ldrb r2, [r1, 0x8]
movs r3, 0xF
adds r1, r2, 0
ands r1, r3
ldr r2, [r7]
ldrb r3, [r2, 0x8]
lsrs r2, r3, 4
adds r3, r2, 0
movs r4, 0xF
adds r2, r3, 0
ands r2, r4
adds r4, r2, 0
lsls r3, r4, 24
lsrs r2, r3, 24
adds r4, r2, 0
lsls r3, r4, 2
adds r3, r2
lsls r2, r3, 1
adds r1, r2
ldrb r2, [r0]
movs r3, 0
ands r2, r3
adds r3, r2, 0
adds r2, r3, 0
orrs r2, r1
adds r1, r2, 0
strb r1, [r0]
adds r0, r7, 0
adds r0, 0x8
ldrb r1, [r0]
cmp r1, 0xB
2015-10-10 11:50:53 +01:00
bhi @082E2770
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
adds r0, 0x8
ldr r1, [r7]
ldrb r2, [r0]
movs r3, 0
ands r2, r3
adds r3, r2, 0
ldrb r1, [r1, 0x8]
adds r2, r3, 0
orrs r2, r1
adds r1, r2, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
b @082E278E
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2770:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
adds r0, 0x8
ldr r1, [r7]
ldrb r2, [r1, 0x8]
movs r3, 0x80
adds r1, r2, 0
orrs r1, r3
ldrb r2, [r0]
movs r3, 0
ands r2, r3
adds r3, r2, 0
adds r2, r3, 0
orrs r2, r1
adds r1, r2, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E278E:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
adds r0, 0x8
ldr r1, [r7]
ldrb r2, [r0, 0x1]
movs r3, 0
ands r2, r3
adds r3, r2, 0
ldrb r1, [r1, 0x9]
adds r2, r3, 0
orrs r2, r1
adds r1, r2, 0
strb r1, [r0, 0x1]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortDirection
2015-10-06 15:00:49 +01:00
movs r1, 0x7
strh r1, [r0]
movs r0, 0x68
2015-11-27 23:32:24 +00:00
bl RTC_WriteByte
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E27C4:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x4
ldrb r1, [r0]
cmp r1, 0x1
2015-10-10 11:50:53 +01:00
bls @082E27D8
b @082E27FA
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E27D8:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
adds r0, 0x8
adds r1, r7, 0x4
ldrb r2, [r1]
adds r0, r2
ldrb r1, [r0]
adds r0, r1, 0
2015-11-27 23:32:24 +00:00
bl RTC_WriteByteReversed
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x4
adds r0, r7, 0x4
adds r1, r7, 0x4
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E27C4
@082E27FA:
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
2015-10-10 11:41:19 +01:00
ldr r0, =0x03001a7e
2015-10-06 15:00:49 +01:00
movs r1, 0
strb r1, [r0]
movs r0, 0x1
2015-10-10 11:50:53 +01:00
b @082E2818
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E2818:
2015-10-06 15:00:49 +01:00
add sp, 0xC
pop {r4,r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetUnknownData
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_WriteByte
; u8 RTC_WriteByte(u8 value)
RTC_WriteByte: ; 82E2820
2015-10-06 15:00:49 +01:00
push {r4,r5,r7,lr}
sub sp, 0x4
mov r7, sp
adds r1, r0, 0
adds r2, r7, 0
strb r1, [r2]
adds r1, r7, 0x1
movs r2, 0
strb r2, [r1]
2015-10-10 11:50:53 +01:00
@082E2832:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x1
ldrb r2, [r1]
cmp r2, 0x7
2015-10-10 11:50:53 +01:00
bls @082E283C
b @082E28BC
@082E283C:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x2
adds r3, r7, 0
ldrb r2, [r3]
adds r3, r7, 0x1
ldrb r4, [r3]
movs r5, 0x7
subs r3, r5, r4
asrs r2, r3
adds r3, r2, 0
movs r4, 0x1
adds r2, r3, 0
ands r2, r4
adds r3, r2, 0
strb r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x5
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
adds r2, r7, 0x1
adds r1, r7, 0x1
adds r2, r7, 0x1
ldrb r3, [r2]
adds r2, r3, 0x1
adds r3, r2, 0
strb r3, [r1]
2015-10-10 11:50:53 +01:00
b @082E2832
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E28BC:
2015-10-06 15:00:49 +01:00
add sp, 0x4
pop {r4,r5,r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_WriteByte
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_WriteByteReversed
; u8 RTC_WriteByteReversed(u8 value)
RTC_WriteByteReversed: ; 82E28C4
2015-10-06 15:00:49 +01:00
push {r4,r7,lr}
sub sp, 0x4
mov r7, sp
adds r1, r0, 0
adds r2, r7, 0
strb r1, [r2]
adds r1, r7, 0x1
movs r2, 0
strb r2, [r1]
2015-10-10 11:50:53 +01:00
@082E28D6:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x1
ldrb r2, [r1]
cmp r2, 0x7
2015-10-10 11:50:53 +01:00
bls @082E28E0
b @082E295C
@082E28E0:
2015-10-06 15:00:49 +01:00
adds r1, r7, 0x2
adds r3, r7, 0
ldrb r2, [r3]
adds r3, r7, 0x1
ldrb r4, [r3]
asrs r2, r4
adds r3, r2, 0
movs r4, 0x1
adds r2, r3, 0
ands r2, r4
adds r3, r2, 0
strb r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x4
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
adds r2, r7, 0x2
ldrb r3, [r2]
adds r2, r3, 0
lsls r3, r2, 1
adds r2, r3, 0
movs r3, 0x5
orrs r2, r3
adds r3, r2, 0
strh r3, [r1]
adds r2, r7, 0x1
adds r1, r7, 0x1
adds r2, r7, 0x1
ldrb r3, [r2]
adds r2, r3, 0x1
adds r3, r2, 0
strb r3, [r1]
2015-10-10 11:50:53 +01:00
b @082E28D6
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E295C:
2015-10-06 15:00:49 +01:00
add sp, 0x4
pop {r4,r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_WriteByteReversed
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_ReadByte
; u8 RTC_ReadByte()
RTC_ReadByte: ; 82E2964
2015-10-06 15:00:49 +01:00
push {r7,lr}
sub sp, 0x4
mov r7, sp
adds r0, r7, 0
movs r1, 0
strb r1, [r0]
2015-10-10 11:50:53 +01:00
@082E2970:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0
ldrb r1, [r0]
cmp r1, 0x7
2015-10-10 11:50:53 +01:00
bls @082E297A
b @082E29E0
@082E297A:
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x4
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x4
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x4
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x4
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x4
strh r1, [r0]
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortData
2015-10-06 15:00:49 +01:00
movs r1, 0x5
strh r1, [r0]
adds r0, r7, 0x1
2015-11-27 23:46:51 +00:00
ldr r1, =GPIOPortData
2015-10-06 15:00:49 +01:00
ldrh r2, [r1]
movs r3, 0x2
adds r1, r2, 0
ands r1, r3
adds r3, r1, 0
lsls r2, r3, 16
lsrs r1, r2, 16
lsrs r2, r1, 1
adds r1, r2, 0
strb r1, [r0]
adds r0, r7, 0x2
adds r1, r7, 0x2
ldrb r2, [r1]
lsrs r1, r2, 1
adds r2, r7, 0x1
ldrb r3, [r2]
lsls r2, r3, 7
orrs r1, r2
adds r2, r1, 0
strb r2, [r0]
adds r1, r7, 0
adds r0, r7, 0
adds r1, r7, 0
ldrb r2, [r1]
adds r1, r2, 0x1
adds r2, r1, 0
strb r2, [r0]
2015-10-10 11:50:53 +01:00
b @082E2970
2015-10-06 15:00:49 +01:00
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-10-10 11:50:53 +01:00
@082E29E0:
2015-10-06 15:00:49 +01:00
adds r0, r7, 0x2
ldrb r1, [r0]
adds r0, r1, 0
2015-10-10 11:50:53 +01:00
b @082E29E8
@082E29E8:
2015-10-06 15:00:49 +01:00
add sp, 0x4
pop {r7}
pop {r1}
bx r1
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_ReadByte
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetReadWriteInternal
; void RTC_SetReadWriteInternal()
RTC_SetReadWriteInternal: ; 82E29F0
2015-10-06 15:00:49 +01:00
push {r7,lr}
mov r7, sp
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortReadWrite
2015-10-06 15:00:49 +01:00
movs r1, 0x1
strh r1, [r0]
pop {r7}
pop {r0}
bx r0
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetReadWriteInternal
2015-10-06 15:00:49 +01:00
2015-11-27 23:32:24 +00:00
thumb_func_start RTC_SetReadOnlyInternal
; void RTC_SetReadOnlyInternal()
RTC_SetReadOnlyInternal: ; 82E2A04
2015-10-06 15:00:49 +01:00
push {r7,lr}
mov r7, sp
2015-11-27 23:46:51 +00:00
ldr r0, =GPIOPortReadWrite
2015-10-06 15:00:49 +01:00
movs r1, 0
strh r1, [r0]
pop {r7}
pop {r0}
bx r0
.align 2, 0
2015-10-10 11:41:19 +01:00
.pool
2015-11-27 23:32:24 +00:00
thumb_func_end RTC_SetReadOnlyInternal