Hi
I am a bit curious about how to reopen the KEYBOARD: device in MC code. In my scenario I work from ISDOS. I am aware that only one keyboard channel can be open at any time
Obviously the keyboard driver is initially active via the EDITOR: when working from ISDOS.
First I disable interrupts, then I read the $KEY_EDIT EXOS variable to find the existing keyboard device channel. I use this value to close the keyboard channel. Both actions return code 0 (no error).
Then I attempt to open a new keyboard channel (HL equals bytestring...... 9,"KEYBOARD:"). This fails. Return code is different from 0.
Is there some mechanism that keeps the default keyboard channel open at all times in ISDOS.
I can of course make EXOS call 5 to read the keyboard by using the channel no from the $KEY_EDIT EXOS variable or use I/O ports directly. I just wanted to try using another channel.
I have seen some examples of code that opened another channel for the keyboard. Yet their code did not close the default channel, and only one channel can be used at any time. So what am I missing?
regards
Jesper