AmendHub

vkoskiv

/

MacNTP

/

amendments

/

README

Amendments on September 17, 2023

Store UTC offset as string and change some rsrc IDs

Moved the STR resource IDs to the range recommended in literature for
use with cdevs, and stuck them in a header to share between the cdev
and INIT.
We now also store the UTC offset as a full string, rather than just
the minutes as a string. The cdev validates before saving, and the
INIT also checks it before using it.
The cdev now also computes an offset and updates the system clock when
setting the UTC offset, since we don't check it again until reboot,
and even then only if the clock is obviously wrong.
vkoskiv made amendment 17 about 1 year ago

Amendments on September 13, 2023

Implement a very rough first-pass control panel + fallback option

I honestly thought that the cdev would be the easy part, but the API
is quite weird, and I've had tons of issues just getting text boxes
to work as expected.
It now works just enough to edit the STR resources we use to store
settings. There is no validation yet, that will come later.
There are now two NTP urls, the fallback URL will be tried if the
primary one returns a DNS resolve error.
vkoskiv made amendment 16 about 1 year ago

Amendments on September 9, 2023

Purge resources when done to save 8K of system heap

We now no longer need to persist our resources in the system heap for
later trap access, so we now let the system purge them after MacNTP
has run. This saves 8K of system heap.
If MacNTP did end up updating the clock, it sets up the MacTCP driver,
which stays resident in the system heap until the next reboot, bloating
the system heap by 16K. Nothing we can do about that, AFAIK.
I also yanked out two globals we no longer need.
vkoskiv made amendment 15 about 1 year ago

Amendments on September 7, 2023

Large rewrite, restructure the project into an INIT

* Moved NTP client to MacNTP.{c,h}
* Rewrite main to work as an INIT
* Load NTP url and utc offset from resourcs
* Fix many bugs
* Add many new bugs
* Remove all ANSI dependencies, it's a big library
* Remove util.{c,h}
* Add basic debugging, uncomment DEBUGGING define in main.c to enable
vkoskiv made amendment 11 about 1 year ago

Amendments on August 22, 2023

Add README

I explain how to set up a development environment in Think C, since
it may not be obvious to beginners.
vkoskiv made amendment 8 about 1 year ago