GLAST/LAT > DAQ and FSW > FSW > Doxygen Index > GNAT / V2-0-0

Constituent: gnat_cio     Tag: linux-gcc


Interface   Data Structures   File List   Data Fields   Globals  

ginit.h File Reference

Defines the creation and initialization methods for the gnat driver. More...

#include "GNAT/gnat.h"
#include "GNAT/info.h"

Include dependency graph for ginit.h:

Include dependency graph

This graph shows which files directly or indirectly include this file:

Included by dependency graph

Functions

unsigned int gSizeOfGh (void)
 Hides the private implemenation of the gnat registers. Allows user to allocate memory.

int gInitDrv (void)
 Driver wide initialization: allocate memory, semaphores, etc...

int gInitDev (void)
 Device initialization: flush buffers, init registers, etc...

int gOpen (gnatHandle gh, unsigned int physAddr)
 maps the physical address to an instance of the driver object

int gClose (gnatHandle gh)
 shuts down the device attached to handle

int gGetDriverInfo (DriverInfo *di)
 fills in driver info struct

int gGetHardwareInfo (gnatHandle gh, HardwareInfo *hi)
 fills in hardware info struct

int gGetLogicalAddr (gnatHandle gh, unsigned int *addr)
 returns the logical address attached to handle

int gGetPhysAddr (gnatHandle gh, unsigned int *addr)
 returns the physical address attached to handle


Detailed Description

Defines the creation and initialization methods for the gnat driver.

Author:
Curt Brune -- curt@slac.stanford.edu

Function Documentation

int gClose gnatHandle  gh  ) 
 

shuts down the device attached to handle

Parameters:
gh handle of device to close
Returns:
OK if close successful
See also:
gOpen()

int gGetDriverInfo DriverInfo di  ) 
 

fills in driver info struct

Parameters:
di pointer to storage to hold driver info
Returns:
G_OK on successs

int gGetHardwareInfo gnatHandle  gh,
HardwareInfo hi
 

fills in hardware info struct

Parameters:
gh handle of device
hi pointer to storage to hold hardware info
Returns:
G_OK on successs

Here is the call graph for this function:

int gGetLogicalAddr gnatHandle  gh,
unsigned int *  addr
 

returns the logical address attached to handle

Parameters:
gh handle of device to close
addr pointer to storage for holding logical address
Returns:
G_OK on successs
See also:
gOpen()

int gGetPhysAddr gnatHandle  gh,
unsigned int *  addr
 

returns the physical address attached to handle

Parameters:
gh handle of device to close
addr pointer to storage for holding physical address
Returns:
G_OK on successs
See also:
gOpen()

int gInitDev void   ) 
 

Device initialization: flush buffers, init registers, etc...

Returns:
G_OK on success
See also:
gInitDev()

int gInitDrv void   ) 
 

Driver wide initialization: allocate memory, semaphores, etc...

Returns:
G_OK on success
See also:
gInitDev()

int gOpen gnatHandle  gh,
unsigned int  physAddr
 

maps the physical address to an instance of the driver object

Parameters:
gh gnat driver handle previously allocated
physAddr the physical address of the comm IO board
Returns:
OK for success
See also:
gClose()
Attempts to map physAddr into a local (logical) address. If successful it binds the physical and logical address to the driver object refered to by handle. If unsucessful it clears both the physical and local address for handle and returns ERROR.

Here is the call graph for this function:

unsigned int gSizeOfGh void   ) 
 

Hides the private implemenation of the gnat registers. Allows user to allocate memory.

Returns:
the size of struct _gnat
See also:
gOpen()


Generated on Thu Oct 21 08:24:26 2004 by doxygen 1.3.3