1
0
mirror of https://github.com/cc65/cc65.git synced 2024-12-28 06:30:16 +00:00
cc65/libsrc/cbm610
Oliver Schmidt eb9872c684 Added clock_settime() for some CBMs.
The CIA TOD only stores the time but not the date. Therefore the date set by clock_settime() ist just stored inside the C library for retrieval via clock_gettime().

The "very special" handling of 12AM/PM is based on https://groups.google.com/d/msg/comp.sys.cbm/ysVYSX4AMbc/vHrXCWEhCOUJ saying:

==========

24hr: Wr => Rd => Nx
--------------------
  0 : 92 => 12 => 01   <= Switch from 00 to 01 (24-hour notation)
  1 : 01 => 01 => 02
  2 : 02 => 02 => 03
 11 : 11 => 11 => 92
 12 : 12 => 92 => 81   <= Switch from 12 to 13 (24-hour notation)
 13 : 81 => 81 => 82
 14 : 82 => 82 => 83
 23 : 91 => 91 => 12

1. column ("24hr"): hour to be tested (decimal)
2. column ("Wr"):   hour written to TOD register (BCD)
3. column ("Rd"):   hour read from TOD register (BCD) immediately after writing the value in column 2 to see the conversion between AM/PM, if any
4. column ("Nx"):   next hour (BCD) after the hour switch

==========

Thanks Paul!
2018-08-18 01:29:40 +02:00
..
emd Create static drivers directly from source files. 2014-06-04 23:50:18 +02:00
ser Create static drivers directly from source files. 2014-06-04 23:50:18 +02:00
_scrsize.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
banking.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
break.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
cgetc.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
clrscr.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
color.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
cpeekc.s cbm stuff from greggs pull request 2017-12-11 19:52:11 +01:00
cpeekcolor.s cbm stuff from greggs pull request 2017-12-11 19:52:11 +01:00
cpeekrevers.s cbm stuff from greggs pull request 2017-12-11 19:52:11 +01:00
cpeeks.s fix cpeeks for CBM610 2017-12-12 04:32:39 +01:00
cputc.s Introduced internal gotoxy that pops both parameters. 2016-06-05 14:58:38 +02:00
crt0.s Refined the comments in the target start-up files. 2014-08-24 10:10:20 -04:00
crtc.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
devnum.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
extzp.inc Made Olivers devnum patch (r4588) work with the PET-II models. On these 2010-02-20 19:46:51 +00:00
extzp.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
get_tv.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
gettime.s Added clock_settime() for some CBMs. 2018-08-18 01:29:40 +02:00
irq.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kbhit.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kclose.s Fixed a typo 2003-12-27 16:10:53 +00:00
kernal.s TAB to space conversion 2018-06-30 16:25:43 +03:00
kiobase.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kopen.s Complete redesign of the CBM610 support. 2003-12-20 23:13:26 +00:00
krdtim.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kreadst.s Minor changes and cleanup 2003-12-20 23:38:42 +00:00
kscnkey.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kscreen.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
ksetnam.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
ksettim.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
kudtim.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
libref.s Added library reference ser_libref to SER interface. 2013-06-01 11:03:14 +02:00
mainargs.s Renamed INITBSS to INIT and INIT to ONCE. 2016-03-06 21:27:19 +01:00
peeksys.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
pokesys.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
randomize.s Fixed the random-seed generators for the Commodore targets. 2015-09-11 10:03:07 -04:00
revers.s Removed (pretty inconsistently used) tab chars from source code base. 2013-05-09 13:57:12 +02:00
settime.s Added clock_settime() for some CBMs. 2018-08-18 01:29:40 +02:00
sysuname.s New uname function 2003-08-12 17:24:02 +00:00
tmcommon.s Added clock_settime() for some CBMs. 2018-08-18 01:29:40 +02:00