The text of a manual · part 16 of 20
Allegro DOS Owner's Manual: Chapter 6 Software Developer's Guide for MS-DOS, pages 126 to 134
Pages 126 to 134 of 166, from Allegro DOS Owner's Manual
The original document is the PDF (1.1 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.
For the Juniper Systems Allegro-DOS
Page 126
▲ Function AH=2Eh
Note: The behavior of the panning sub-functions 00 - 03 depends on the current font size and video mode. Subfunction: AL = 00h (pan left) Pans screen left. If screen is at leftmost limit, no action is taken. Returns nothing.
126
Allegro DOS Owner’s Manual
Page 127
Subfunction: AL = 01h (pan right) Pans screen right. If screen is at rightmost limit, no action is taken. Returns nothing. Subfunction: AL = 02h (pan up) Pans screen up. If screen is at top of 25 row virtual display, no action is taken. Returns nothing. Subfunction: AL = 03h (pan down) Pans screen down. If screen is at bottom of 25 row virtual display, no action is taken. Returns nothing. Subfunction: AL = 04h (pan xy - text mode only) Locates the upper left corner of display window to row/column specified on the virtual 80x25 display. Call with BH=row, BL=column. Range of row/column values depends on font size. The display window must be contained within 80 x 25 virtual display. (0,0) is top left corner. Returns nothing. Subfunction: AL = 06h (pc card power while in suspend) Determines whether to leave PC Card powered when the system is suspended or to turn power off. Some cards may draw substantial current even when suspended and may need to be powered down during suspend so the Allegro’s batteries are not drained. Call with:
BL=00h BL=01h BL=02h return current setting in AL power off during suspend power on during suspend (default)
Subfunction: AL = 07h (suspend Allegro) Suspends the Allegro to low power suspend state and remains there until a valid wakeup event occurs. Calling this function is identical to pressing the On/Off key when the system is in suspend/resume mode. Returns nothing. Subfunction: AL = 0Ah (get Allegro status byte) Returns status bye in AL where: b7-b1 b0
= = reserved power manager setting 1=on, 0=off
Subfunction: AL = 0Bh (set cpu busy/done) Applications should set CPU busy when a block of processing needs to be performed. CPU busy overrides power manager and keeps the CPU running fast for as long as it is set. CPU done should be called after CPU busy to tell the CPU that processing is complete and the Allegro can return to a lower power state. Allegro DOS Owner’s Manual
127
Page 128
WARNING: CPU busy drains the batteries rapidly and should only be enabled when needed. Returns nothing. Call with:
BL=00h BL=01h
CPU busy CPU done
Subfunction: AL = 0Ch (disable BIOS power manager) Disables automatic power management functions in the BIOS. The Allegro generally uses less power with power manager enabled. Returns nothing. Subfunction: AL = 0Dh (enable BIOS power manager) Enables automatic power management functions in the BIOS. The system generally uses less power with power manager enabled. Returns nothing. Subfunction: AL = 0Fh (get CPU version) Returns CPU version as follows: AL=version major (b7-b4)+version minor (b3-b0). Subfunction: AL = 10h (get keypad shift flag settings) Returns current shift flag settings in AL. See Subfunction AL=11h. Subfunction: AL = 11h (set keypad shift flag settings) The keyboard shift flags (Ctrl, Alt, Shift) can be individually controlled such that when the key is pressed it registers as either left, right, or both scan codes. The Alt-nnn function can be enabled/disabled with this function. Call with:
BL=b7-b0 where: b1,b0 = 01 10 11 b3,b2 = 01 10 11 b5,b4 = 01 10 11 b6 = 0 1 b7 = right Shift only left Shift only both (Default) right Alt only left Alt only both (Default) right Ctrl only left Ctrl only both (Default) disable Alt-nnn enable Alt-nnn (default) reserved
Subfunction: AL = 12h (get Allegro ID) Returns offset of Allegro ID string in AX. Segment is F000.
128
Allegro DOS Owner’s Manual
Page 129
Subfunction: AL = 14h (select font size in text mode) Call with: b1 = 00h return current setting in AL 01h set 8 x 8 pixels 02h set 8 x 12 pixels 03h set 10 x 12 pixels 04h set 16 x 16 pixels Subfunction: AL = 15h (perform system hard reset) No arguments, when called does a hard reset. Subfunction: AL = 19h (set LED brightness) Call with: b1 = 00h return current setting in AL = 01h dim = 02h medium = 03h bright Subfunction: AL = 1Ah (get battery % charge) Returns AL = % C, range 0 to 100%. Subfunction: AL = 20h (get BIOS version) Returns offset of BIOS version string in AX. Segment is F000. Subfunction: AL = 24h (BIOS Setup popup window) Invokes the BIOS Setup window. Control is passed to the BIOS Setup utility. The function returns when the user exits the Setup utility. The video state is automatically saved and restored during this call. Returns nothing. This function requires the BIOS video save buffer to be available. If the buffer is not available because another system popup window is in use (such as the “battery change” window), this call is ignored. Subfunction: AL = 26h (get/set vehicle mode) Disallows battery charging when vehicle mode is ON and the battery gauge percent charge register is greater than 90% (refer to subfunction 1A). This prevents excessive overcharging when the Allegro is connected to an external power supply where the power is cycled on and off frequently, such as in a vehicle. When vehicle mode is OFF, charging is allowed no matter what value is in the percent charge register.
Allegro DOS Owner’s Manual
129
Page 130
▲ Function AH=2Fh Subfunction: AL = 00h (read status byte) Output: AL = Status Byte, where: Subfunction: AL = 01h (read video contrast) Output: AL = Video Contrast The range of video contrast is from 0 to 63. Subfunction: AL = 0Ch/AL = 0Dh (turn backlight off/on) AL = 0Ch turns the display backlight off. AL = 0Dh turns the display backlight on. Returns nothing. Subfunction: AL = 0Eh/AL = 0Fh (set heater off/auto) AL = 0Eh turns the display heater off. AL = 0Fh sets the display heater to automatic. Returns nothing. ❖ Note: In automatic mode, the heater is active when the display temperature is below -3° C. Subfunction: AL = 10h/AL = 11h (set key beep off/on) AL = 10h turns the key beep off. AL = 11h turns the key beep on. Returns nothing. Subfunction: AL = 12h (power down system) This function causes the Allegro to immediately power off just like it does when the On/Off key is pressed and the Allegro is in On/Off mode. If external power is connected to the Allegro, this function causes the Allegro to go into a semi-low power state where it appears to be off, but it is actually on. Any event that normally causes the Allegro to turn on (pressing the On/Off key, com port ring in, etc.) causes the Allegro to reboot. When the external power is removed, the Allegro powers off. Subfunction: AL = 13h (put system in reboot mode) When it is executed, the Allegro is set to reboot mode. In this mode the on/off key causes power to be turned off. Returns nothing. Subfunction: AL = 14h (put system in suspend/resume mode) When it is executed, the Allegro is set to suspend/resume mode. In this mode, the power is not completely shut off. The Allegro is still running but at very low power, so it appears to be off. When the key is pressed, the Allegro resumes where it left off.
130
Allegro DOS Owner’s Manual
Page 131
Subfunction: AL = 15h (set auto suspend duration) This subfunction requires an input value to set the auto suspend duration. The input value is passed in the BL register. There is no output. If BL = 00h auto suspend is disabled 01h duration = 5 min 02h duration = 10 min 03h duration = 15 min 04h duration = 20 min 05h duration = 25 min 06h duration = 30 min 07h duration = 35 min
08h duration = 40 min 09h duration = 45 min 0Ah duration = 50 min 0Bh duration = 55 min 0Ch duration = 60 min 0Dh duration = 65 min 0Eh duration = 70 min 0Fh duration = 75 min
Subfunction: AL = 16h (set video contrast) This subfunction requires an input value to set the video contrast ratio. The input value is passed in the BL register and has a range of 00h to 63h. Returns nothing. Subfunction: AL = 18h (get performance level) The purpose of this function is to read the current performance level. Output: AL = 00h miser 01h low 02h medium 03h high 04h hyper Subfunction: AL = 19h (set performance level) This subfunction requires an input value to set the performance level. The input value is passed in the BL register. Valid register values are shown below. BL = 00h miser 01h low 02h medium 03h high 04h hyper No value is returned to the AL register. ❖ Note: If the eighth bit is set (e.g., 1XXXXXXX, X = 0 or 1), the system is put into a low power mode (i.e., “sleep”) until a system timer tick occurs which restores the system to normal power. Timer ticks occur once every 55 milliseconds. The performance level is not changed when the sleep function is called. It is commonly used in applications to save power while waiting for a keystroke.
Allegro DOS Owner’s Manual
131
Page 132
Subfunction: AL = 1Ah/AL = 1Bh (set auto-panning off/on) There is no output for these subfunctions. AL = 1Ah turns autopanning off. AL = 1Bh turns auto-panning on. Subfunction: AL = 1Eh (read miscellaneous BIOS setup bytes) Input: None Output: AL = Miscellaneous System Setup Flags Miscellaneous System Setup Flags Bit information: bit 0 bit 1 bit 2 bit 3 bit 4 bit 5 bit 6 bit 7
0 = reboot mode, 1 = suspend/resume mode reserved reserved reserved reserved 0 = auto-panning active, 1 = auto-panning inactive reserved 0 = black and white, 1 = gray scale (video)
Subfunction: AL = 23h (video) This routine sets the display to black and white or to 64 gray shades. BL =
00h 01h 02h 03h black and white 1 gray scale (16 shades) black and white 2 return current setting in AL
This function controls how the BIOS maps CGA colors to LCD gray scale. B/W 1 and B/W 2 map all colors to either black on white or white on black to increase viewability for some programs. B/W 1 is faster than B/W 2 but only works on programs which go through the BIOS for video text output. B/W 2 should work on all programs but is less efficient than B/W 1. ❖ Note: This function is applicable only to text mode.
132
Allegro DOS Owner’s Manual
Page 133
Hardware Interrupt Listing The following chart shows the interrupt-level assignments in decreasing priority. Level
Function
Microprocessor NMI Interrupt Controllers CTRL 1 CTRL 2
Parity or I/O Channel Check
IRQ 0 IRQ 1 IRQ 2
Timer Output 0 Keyboard (Output Buffer Full) Interrupt from CTRL 2 IRQ 8 IRQ 9 IRQ 10 IRQ 11 IRQ 12 IRQ 13 IRQ 14 IRQ 15
IRQ 3 IRQ 4 IRQ 5 IRQ 6 IRQ 7
Real Time Clock Interrupt Not Used* Not Used* Expansion Port UART Touchscreen Not Used Not Used* Not Used* Serial Port 2 Serial Port 1 Sound Chip Not Used Not Used*
*PC Card IRQ assigned by Card and Socket Services.
Allegro DOS Owner’s Manual
133
Page 134
I/O Port Mapping Address
Function
080 2F0 - 2F3 2F8 - 2FF 300 - 31F 3D0 - 3DF 3E0 - 3E7 3F8 - 3FF
Diagnostics Port System Control Registers COM2: Internal - Do Not Use CGA Display PC Card Controller COM1:
134
Allegro DOS Owner’s Manual