Main Page | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

detect.c File Reference

Shared library / DLL for accessing the driver. More...

#include "debug.h"
#include <stdlib.h>
#include "opencbm.h"
#include "archlib.h"

Go to the source code of this file.

Defines

#define DBG_USERMODE
#define DBG_PROGNAME   "OPENCBM.DLL"
#define DLL
 mark: We are building the DLL */

Functions

int CBMAPIDECL cbm_identify (CBM_FILE HandleDevice, __u_char DeviceAddress, enum cbm_device_type_e *CbmDeviceType, const char **CbmDeviceString)
 Identify the connected floppy drive.


Detailed Description

Shared library / DLL for accessing the driver.

**************************************************************

Author:
Michael Klein, Spiro Trikaliotis
Version:
Id
detect.c,v 1.2 2006/02/24 12:01:11 trikalio Exp


Definition in file detect.c.


Define Documentation

#define DBG_PROGNAME   "OPENCBM.DLL"
 

The name of the executable

Definition at line 25 of file detect.c.

#define DBG_USERMODE
 

Mark: We are in user-space (for debug.h)

Definition at line 22 of file detect.c.


Function Documentation

int CBMAPIDECL cbm_identify CBM_FILE  HandleDevice,
__u_char  DeviceAddress,
enum cbm_device_type_e CbmDeviceType,
const char **  CbmDeviceString
 

Identify the connected floppy drive.

This function tries to identify a connected floppy drive. For this, it performs some M-R operations.

Parameters:
HandleDevice A CBM_FILE which contains the file handle of the driver.
DeviceAddress The address of the device on the IEC serial bus. This is known as primary address, too.
CbmDeviceType Pointer to an enum which will hold the type of the device.
CbmDeviceString Pointer to a pointer which will point on a string which tells the name of the device.
Returns:
0 if the drive could be contacted. It does not mean that the device could be identified.
If cbm_driver_open() did not succeed, it is illegal to call this function.

Definition at line 65 of file detect.c.

References cbm_dt_cbm1541, cbm_dt_cbm1570, cbm_dt_cbm1571, cbm_dt_cbm1581, cbm_dt_unknown, cbm_exec_command(), cbmarch_raw_read(), cbmarch_talk(), cbmarch_untalk(), FUNC_ENTER, and FUNC_LEAVE_INT.

Referenced by cbm_identify_xp1541(), and vdd_identify().


Generated on Sun Apr 30 18:46:06 2006 for opencbm by  doxygen 1.4.2