Topic : TOS - The Operating System
Author :
Version : tos.hyp (December 19, 2008)
Subject : Programmieren/Atari
Nodes : 3010
Index Size : 93790
HCP-Version : 5
Compiled on : Atari
@charset : atarist
@lang :
@default : Title
@help :
@options : +g -i -s +x +zz -t4
@width : 70
View Ref-File4.16.1 Bconmap TOS Name: »Select serial port« - Select a default port.
Opcode: 44
Syntax: int32_t Bconmap( int16_t devno );
Description: The XBIOS routine Bconmap selects one of the serial
ports for Bios output. In addition one can inquire for
a pointer to the BCONMAP structure, with which one can
query for the highest BIOS device number and also
install new device drivers. devno can assume the
following values:
devno Meaning
-402 Remove device / RSVF list (HSMODA)
-401 Append entry (HSMODA)
-400 Overwrite selected entry (HSMODA)
-2 Return pointer to BCONMAP structure
-1 Only inquire current channel
0 Test whether Bconmap is present
6 ST-compatible RS-232 port
7 SCC Channel B
8 TTMFP RS-232 port
9 SCC Channel A
>10 Own driver
The function affects both the BIOS vector table in the
system variables, as well as the behaviour of the
functions Rsconf and Iorec.
HSMODA These functions are only present if the HSMODA package
is installed.
int32_t Bconmap((int16_t)-400, (int16_t)dev_nr,
(int32_t)ptr_to_6_longs) The constant MAPT_OVE is defined as -400. This function
serves for overwriting already existing MAPTAB entries.
dev_nr is a device number from 6 upwards that already
has to exist in MAPTAB, otherwise the error-code -15
EUNDEV will be returned. ptr_to_6_longs points to a
structure that corresponds to a MAPTAB entry. This
structure will be copied to the corresponding place in
the MAPTAB. If the addressed device is the one
currently set by Bconmap for AUX, then the newly
hooked-in routines will also be copied to xco* and into
the current Rsconf and Iorec cells. This function
serves only for hooking in MagiC-friendly routines. If
successful, the device number to which the entry refers
will be returned, i.e. dev_nr. To install devices on the BIOS numbers that are
permanently assigned to a computer, one should always
use MAPT_OVE. For the ST this pertains for instance to
number 6, for a MegaSTE to numbers 6 to 8 and for a
TT030 to numbers 6 to 9.
int32_t Bconmap((int16_t)-401, (int32_t)ptr_to_6_longs) The constant MAPT_APP is defined as -401. This function
serves for appending a channel to the MAPTAB or for
writing to an empty channel. ptr_to_6_longs points to a
structure that corresponds to a MAPTAB entry. The
return is either the channel number selected by this
function for the entry, or the error-code -12 EGENRL if
there is no room for a MAPTAB augmentation. Here it
cannot happen that the vectors are transferred
immediately to xco*, as a previously absent channel, or
one in use, can not have been set as AUX.
MAPT_APP searches for the first free channel after
those BIOS numbers that are permanently assigned to a
computer and can therefore only be used for installing
additional devices.
int32_t Bconmap((int16_t)-402, (int16_t) dev_nr,
(int32_t)ptr_to_listentry) The constant MAPT_DEL is defined as -402. This function
serves for deleting a device from the MAPTAB and for
unhooking a RSVF list from the RSVF daisy chain.
dev_nr is either the BIOS channel number of the device
to be removed from the MAPTAB, or -1 for doing nothing.
The corresponding MAPTAB entry is cleared by entering
special dummy-routine pointers that point to the
assembler command RTS. The Iorec pointer entry is set
to 0. If the deleted channel was also set as the BIOS
AUX device, then BIOS AUX will be reset as number 6,
even if number 6 has just been deleted.
ptr_to_listentry is either the pointer to the RSVF list
to be unhooked, or 0 for doing nothing. The pointer
must refer to the start of a list, which is then
removed completely, even if it contains more than one
interface object and end or daisy-chain object.
MAPT_DEL returns 1 if successful, or -1 in case of
error.
Return value: Bconmap returns the old setting. If devno equals -2,
then the function returns a pointer to BCONMAP.
Availability: According to Atari one should test one's TOS version
for the presence of Bconmap in the following manner:
WORD has_bconmap ( VOID )
{
return (0L == Bconmap (0));
}
Group: Interface programming See also: BindingBconoutBconinBcostatBconstatIorecRsconf