logoalt Hacker News

rbanffylast Monday at 4:54 PM1 replyview on HN

> Btw, I'd love to know where this idea about no assembler programs on OS/2 came from.

It’s certainly a misunderstanding - nothing prevents someone from writing assembly. Could also be a lack of official documentation on how to make the API calls from assembly. Another possible source is that you can’t access the hardware directly in OS/2, which was more closely associated with low-level programming.


Replies

tengwar2last Monday at 7:56 PM

But you could access the hardware directly. I don't remember the details, but I build a hardware clock running at 10ms cycle time and was able to poll it. Also my build relied fundamentally on reading from a couple of external DAC converters which presented 2 x 10-12 bits for x and y coordinates to some sort of PIO arrangement which I don't now recall. I didn't write a device driver, which I remember as being significantly more difficult (mainly because you couldn't use CodeView).

Just as a brief explanation: this was in the late 80's. I was using a device called an imaging photon detector to detect individual photo events. This was the back end of an early electronic camera running at about ISO 1G. Not a digital camera - the photo events were recorded as analogue xy coordinates, with a resolution of about 400x400 and a photon rate of about 100k/s (not an exact figure - as the rate increased, you lost an increasing number of events due to clash. I had a load of wire-wrap to rearrange the bits before they were presented to the computer (bit-bashing on the 80386/33 wasn't fast enough), then the xy coordinated were presented to some sort of PIO. In some cases I wanted to take video, hence the hardware clock, since the nearest thing available on the PC only ran at something like 13.3Hz and was used for polling the mouse. There was no GUI available at the time, so I built my own.

I don't remember a huge amount of detail, and the source is on 5¼" floppy, but as I remember it none of this was difficult for a very amateur self-taught C/asm programmer. The only significant problem was working out that the OS/2 1.0 documentation of the mouse system lied (it didn't have the display capability claimed, and attempting to use it shut down mouse polling), and third party manuals just copied the lies without testing. That was easy enough to work out, and building a couple of threads to display the mouse cursor was easy.

show 1 reply