Re: Regs
- Posted by Albert Brauneis <Dajawu36 at AOL.COM> Nov 29, 1998
- 516 views
Ok I got the program to work here it is: --start light.ex-- include machine.e constant SCROLL_LOCK = 16, NUM_LOCK = 32, CAPS_LOCK = 64 function key(integer light) sequence reg_list integer al reg_list = repeat(0,10) reg_list[REG_AX] = #0200 reg_list = dos_interrupt(#16, reg_list) al = and_bits(reg_list[REG_AX], #00FF) return and_bits(al,light) end function clear_screen() if key(NUM_LOCK) != 0 then puts(1, "\nNUM_LOCK = TRUE") else puts(1, "\nNUM_LOCK = FALSE") end if if key(SCROLL_LOCK) != 0 then puts(1, "\nSCROLL_LOCK = TRUE") else puts(1, "\nSCROLL_LOCK = FALSE") end if if key(CAPS_LOCK) != 0 then puts(1, "\nCAPS_LOCK = TRUE") else puts(1, "\nCAPS_LOCK = FALSE") end if --end light.ex-- Albert