Subsystem


Functions

HPI_HSUBSYS * HPI_SubSysCreate (void)
 HPI Subsystem create.
void HPI_SubSysFree (HPI_HSUBSYS *phSubSys)
 HPI Subsystem free.
HPI_ERR HPI_SubSysGetVersion (HPI_HSUBSYS *phSubSys, HW32 *pdwVersion)
 HPI subsystem get version.
HPI_ERR HPI_SubSysGetVersionEx (HPI_HSUBSYS *phSubSys, HW32 *pdwVersionEx)
 Extended HPI_SubSysGetVersion() that returns Major, Minor and Build versions Returns extended HPI subsystem version that was embedded into the HPI module at compile time.
HPI_ERR HPI_SubSysGetInfo (HPI_HSUBSYS *phSubSys, HW32 *pdwVersion, HW16 *pwNumAdapters, HW16 awAdapterList[], HW16 wListLength)
HPI_ERR HPI_SubSysFindAdapters (HPI_HSUBSYS *phSubSys, HW16 *pwNumAdapters, HW16 awAdapterList[], HW16 wListLength)
 Find all adapters that the HPI subsystem knows about.
HPI_ERR HPI_SubSysGetNumAdapters (HPI_HSUBSYS *phSubSys, int *pnNumAdapters)
 Return the total number of adapters including networked adapters.
HPI_ERR HPI_SubSysGetAdapter (HPI_HSUBSYS *phSubSys, int nIterator, HW32 *pdwAdapterIndex, HW16 *pwAdapterType)
 Extended version of HPI_SubSysFindAdapters() that iterates through all adapters present, returning adapter index and type for each one.
HPI_ERR HPI_SubSysSetHostNetworkInterface (HPI_HSUBSYS *phSubSys, char *szInterface)
 Sets the HPI networking subsystem to use the network interface specified.

Function Documentation

HPI_HSUBSYS* HPI_SubSysCreate void   ) 
 

HPI Subsystem create.

Creates, opens and initializes the audio subsystem. Must be called before other HPI functions are called.

Returns:
Pointer to HPI subsystem handle. Returns NULL on error.

void HPI_SubSysFree HPI_HSUBSYS *  phSubSys  ) 
 

HPI Subsystem free.

Closes the HPI subsystem, freeing any resources allocated. Must be the last HPI function called.

Parameters:
phSubSys  Pointer to HPI subsystem handle.

HPI_ERR HPI_SubSysGetVersion HPI_HSUBSYS *  phSubSys,
HW32 *  pdwVersion
 

HPI subsystem get version.

Returns the HPI subsystem major and minor versions that were embedded into the HPI module at compile time. On a Windows machine this version is embedded in the kernel driver .sys file.

Parameters:
phSubSys Pointer to HPI subsystem handle.
pdwVersion 32 bit word containing version of HPI. Upper 24bits is major version number and lower 8 bits is minor version number, i.e., 0x00000304 is version 3.04.
Returns:
0 on success, or one of the HPI Error codes.

HPI_ERR HPI_SubSysGetVersionEx HPI_HSUBSYS *  phSubSys,
HW32 *  pdwVersionEx
 

Extended HPI_SubSysGetVersion() that returns Major, Minor and Build versions Returns extended HPI subsystem version that was embedded into the HPI module at compile time.

On a Windows machine this version is embedded in the kernel driver .sys file.

Parameters:
phSubSys Pointer to HPI subsystem handle.
pdwVersionEx 32 bit word containing version of HPI.
B23..16 = Major version
B15..8 = Minor version
B7..0 = Build version
i.e. 0x00030402 is version 3.04.02
Returns:
0 on success, or one of the HPI Error codes.

HPI_ERR HPI_SubSysGetInfo HPI_HSUBSYS *  phSubSys,
HW32 *  pdwVersion,
HW16 *  pwNumAdapters,
HW16  awAdapterList[],
HW16  wListLength
 

Deprecated:
Use a combination of HPI_SubSysGetVersionEx() and HPI_SubSysFindAdapters() instead.

HPI_ERR HPI_SubSysFindAdapters HPI_HSUBSYS *  phSubSys,
HW16 *  pwNumAdapters,
HW16  awAdapterList[],
HW16  wListLength
 

Find all adapters that the HPI subsystem knows about.

The type and adapter number of each adapter is returned in an array of HW16 pointed to by awAdapterList. Each position in the array identifies an adapter with an adapter index of the corresponding array index. The value of the array indicates the adapter type. A value of zero indicates that no adapter exists for that adapter number.

For example if awAdapterList had a 6114 in position 0, a 0 in position 1 and a 6514 in position 2, that would indicate an 6114 adapter set to adapter number 1 and a 6514 adapter set to adapter number 3 in the system. Note that the Adapter number (as set on the card/adapter) will be one more than the array index.
Index: 01 23

awAdapterList 0x62440 0x43460

Returns:
0 on success, or one of the HPI Error codes. The return value is the last error that occurred when initializing all the adapters. As there is only one error return, when there are multiple adapters some of the adapters may have initialized correctly and still be usable. This is indicated by wNumAdapters > 0. It is up to the application whether to continue or fail, but the user should be notified of the error in any case. Some possible return values are:
HPI_DUPLICATE_ADAPTER_NUMBER - two adapters have the same jumper setting. Only the first one will be accessible.
HPI_ERROR_DSP_BOOTLOAD - something went wrong with starting the adapter DSP.
HPI_ERROR_DSP_FILE_NOT_FOUND - probably an old driver and a new card, or asidsp.bin is missing.
Other errors in the 900 range are adapter specific.
Parameters:
phSubSys  Pointer to HPI subsystem handle.
pwNumAdapters  Returned number of initialised adapters
awAdapterList  Array of adapter types (see description).
wListLength  Size (in elements) of *pawAdapterList array

HPI_ERR HPI_SubSysGetNumAdapters HPI_HSUBSYS *  phSubSys,
int *  pnNumAdapters
 

Return the total number of adapters including networked adapters.

Returns:
0 on success, or one of the HPI Error codes.
Parameters:
phSubSys  Pointer to HPI subsystem handle.
pnNumAdapters  total number of adapters including local and networked.

HPI_ERR HPI_SubSysGetAdapter HPI_HSUBSYS *  phSubSys,
int  nIterator,
HW32 *  pdwAdapterIndex,
HW16 *  pwAdapterType
 

Extended version of HPI_SubSysFindAdapters() that iterates through all adapters present, returning adapter index and type for each one.

Returns:
0 on success, or one of the HPI Error codes.
Parameters:
phSubSys  Pointer to HPI subsystem handle.
nIterator  Adapter iterator {0 .. total number of adapters - 1}.
pdwAdapterIndex  Index of adapter.
pwAdapterType  Type of adapter.

HPI_ERR HPI_SubSysSetHostNetworkInterface HPI_HSUBSYS *  phSubSys,
char *  szInterface
 

Sets the HPI networking subsystem to use the network interface specified.

This is a required call before UDP messaging will work to interface with an ASI2416.

Returns:
0 on success, or one of the HPI Error codes.
Parameters:
phSubSys  Pointer to HPI subsystem handle.
szInterface  String containing network interface information. On Windows this is the IP address of the network adapter, ie "192.168.1.11".


Generated on Tue Nov 18 12:59:30 2008 for AudioScience HPI by  doxygen 1.4.6-NO