kerravon wrote:
eekee wrote:
Regarding character versus block devices, I never quite understood why Unix needs that distinction. In Plan 9, you just have instructions on how to use each virtual file, documented in the server's man page. I guess the same is true of PDOS if you're only making the distinction in a library. I like that.
Thanks for the updated opinion, but just a clarification on this.
Thank you.
kerravon wrote:
From the point of view of a C application programmer, PDOS is no different from any other system. Did I mislead you to think there was?
Ah, this is where we differ; I grew up with an operating system without a concept of standard input or output. (Atari 800 & related micros.) BASIC reserved i/o control block #0 so it could use it for PRINT and INPUT, but that was just BASIC. All through the 90s, I failed to understand tutorials because they assumed standard output was so universal, they didn't need to describe it. They just called it, "the output". I had no idea what this unnamed, unspecified output was. Only in 1999 or so did I finally figure it out from Linux documentation. I did get an MS-DOS machine in the 90s and quickly learned to like redirection, but my roots were in drawing pixels to the screen and command-line programs were just one class of software. Half the programs I used were full-screen TUI which, in MS-DOS, works by writing directly to screen memory. I could understand that just fine, but it took time to comprehend this stream-of-text utility software which was layered on top. It didn't help that Atari had a complex interface for it while MS-DOS and BIOS had clunky and inconsistent interfaces.
With all that as my background, I had no way of knowing standard output was some kind of universal truth to those tutorial writers, but of course those writers would think that way if they'd learned to code on mainframes with terminals. (Or minicomputers; many universities had a VAX.) You're talking the same way they did, so I feel obligated to say that PDOS is indeed different from any OS which lacks a concept of standard input and output.

These days, I think it's a rather clever feature, but I understand those GUI OSs which eschew it altogether.
kerravon wrote:
The thing that I am (starting to) do differently now is the relationship between the OS and the BIOS/HAL/higher level. In PDOS-generic (as distinct from PDOS/386 and presumably most other OSes), is that not even the OS has to deal with block mode. It gets to leverage the C library just as application programmers already do.
I always like to look at different ways of doing things.

If it leads to easier development, it's a very good thing for the likes of us.
I wonder a little bit about non-C programs interacting with device files. I recall that when Linux needed to increase the size of the major and minor numbers of device files, there was a lot of fear of this causing incompatibility, and I don't know if things would be the same now. If, say, a Fortran program required block devices, would it be hard to port? Then again, the set of programs written in Fortran or Pascal which care about the intricacies of Unix device files is probably very small indeed.
kerravon wrote:
This might have eventuated because I am in the unusual position of having control of a C library. Other people could control one they obtained from elsewhere, but that's presumably not their main interest.
That's not so unusual, I don't think. Anyone who wants to write a POSIX microkernel OS will have at least looked at it, I'm sure. And non-POSIX OS devs could do anything.