[Coco] os version check

Robert Gault robert.gault at worldnet.att.net
Wed Sep 30 22:16:39 EDT 2009


Wayne Campbell wrote:
> I haven't been able to locate any system call that I can use to return the version of the OS. It may be that this info is not available through the system. For the meantime, I'm going to add a parameter to DCom that will be used to identify the OS. The option will be 'n'. By default, n will be TRUE (meaning NitrOS09). If you pass the option '-n', DCom will use the TMode Pause/-Pause form. No option, or 'n' as the option, will cause DCom to use the TMode -pau=1/-pau=0 form.
> 
> If someone knows of a system call that allows you to determine different systems, please let me know.
> 
> Wayne
> 

There is no command that I know of which will distinguish OS-9 versions. 
However, you could try reading the sys/motd file.

OS-9 Level1 version 1
WELCOME TO COLOR COMPUTER OS-9

OS-9 Level1 version 2
Same as above

OS-9 Level2
No sys/motd file. However, the startup file contains
Welcome to OS-9 Level2

NitrOS-9 GaleForce
NitrOS-9 v1.22f                   and much more info. Earlier versions
                                   don't have motd.

NitrOS-9 current both Level1 and Level2
Welcome to NitrOS-9 Level #!              Where # is 1 or 2.



More information about the Coco mailing list