Changeset 2362
- Timestamp:
- Jul 14, 2011 8:14:19 AM (23 months ago)
- File:
-
- 1 edited
-
cpu/arm/olpc/1.75/rtc.fth (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
cpu/arm/olpc/1.75/rtc.fth
r2252 r2362 1 purpose: Driver for external IDT1338 RTC chip on XO-1.75 2 1 3 0 0 " " " /" begin-package 2 4 " rtc" name … … 21 23 22 24 headers 23 : open ( -- true ) 24 true 25 : open ( -- okay ) 26 0 ['] rtc@ catch if ( x ) 27 drop false exit ( -- false ) 28 then ( value ) 29 30 \ Ensure that the Clock Halt bit is off 31 dup h# 80 and if ( value ) 32 \ Turn off Clock Halt 33 h# 7f and 0 rtc! ( ) 34 \ Verify that it went off 35 0 rtc@ h# 80 and ( error? ) 36 dup if ." RTC Clock Halt is stuck on" cr then ( error? ) 37 0= ( okay? ) 38 else ( value ) 39 drop true ( true ) 40 then ( okay? ) 25 41 ; 26 42 : close ( -- )
Note: See TracChangeset
for help on using the changeset viewer.
