[OpenBIOS] [PATCH] Adds the get-time word to the dictionary. Used to obtain the date and time.
Programmingkid
programmingkidx at gmail.com
Tue Oct 9 04:10:38 CEST 2012
Signed-of-by: John Arbuckle <programmingkidx at gmail.com>
---
forth/system/main.fs | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/forth/system/main.fs b/forth/system/main.fs
index 122ab1f..09c08d3 100644
--- a/forth/system/main.fs
+++ b/forth/system/main.fs
@@ -58,3 +58,10 @@ variable DIAG-list
outer-interpreter
;
+
+
+\ Returns the time ( -- second minute hour day month year )
+: get-time ( -- )
+ s" rtc" s" get-time" execute-device-method
+ 0= ABORT" Sorry but the rtc node was not found"
+;
\ No newline at end of file
--
1.7.5.4
More information about the OpenBIOS
mailing list