cvt_V812.c File Reference

V812 VME board implementation. More...

#include <memory.h>
#include <string.h>
#include "cvt_V812.h"

Go to the source code of this file.

Functions

BOOL cvt_V812_open (cvt_V812_data *p_data, UINT16 base_address, long vme_handle)
 V812 VME boards data initialization.
BOOL cvt_V812_close (cvt_V812_data *p_data)
 V812 VME boards closing and resource free.
BOOL cvt_V812_set_threshold (cvt_V812_data *p_data, cvt_V812_threshold_id threshold_id, UINT16 value)
 Set the specified discriminator threshold register.
BOOL cvt_V812_set_output_width (cvt_V812_data *p_data, UINT8 value)
 Set the output width register.
BOOL cvt_V812_set_dead_time (cvt_V812_data *p_data, UINT8 value)
 Set the dead time register.
BOOL cvt_V812_set_majority_threshold (cvt_V812_data *p_data, UINT8 value)
 Set the CVT_V812_MAJORITY threshold register.
BOOL cvt_V812_set_pattern_inhibit (cvt_V812_data *p_data, UINT16 value)
 Set the pattern of inhibit register.
BOOL cvt_V812_set_test_pulse (cvt_V812_data *p_data)
 Set the test pulse register.
BOOL cvt_V812_get_fixed_code (cvt_V812_data *p_data, UINT16 *p_value)
 Gets the board fixed code.
BOOL cvt_V812_get_manufacturer_number (cvt_V812_data *p_data, UINT8 *p_value)
 Gets the manufacturer number.
BOOL cvt_V812_get_module_type (cvt_V812_data *p_data, UINT16 *p_value)
 Gets the module type.
BOOL cvt_V812_get_version (cvt_V812_data *p_data, UINT8 *p_value)
 Gets the module version.
BOOL cvt_V812_get_serial_number (cvt_V812_data *p_data, UINT16 *p_value)
 Gets the serial number.


Detailed Description

V812 VME board implementation.

Author:
NDA
Version:
1.0
Date:
03/2006
Provides methods, properties and defines to handle with V812 VME boards

Definition in file cvt_V812.c.


Function Documentation

BOOL cvt_V812_close cvt_V812_data p_data  ) 
 

V812 VME boards closing and resource free.

Provides specific handling for V812 boards closing.

Parameters:
p_data Pointer to board data
Returns:
TRUE: board successfully closed
Note:
Must be called when done with any other board specific API.

Definition at line 95 of file cvt_V812.c.

References cvt_board_close(), FALSE, cvt_V812_data::m_common_data, and TRUE.

BOOL cvt_V812_get_fixed_code cvt_V812_data p_data,
UINT16 p_value
 

Gets the board fixed code.

Reads the fixed code register. It must return CVT_V812_FIXED_CODE_VALUE

Parameters:
p_data Pointer to board data
p_value The value read
Returns:
TRUE: Procedure successfully executed
See also:
CVT_V812_FIXED_CODE_VALUE

Definition at line 255 of file cvt_V812.c.

References cvt_read_reg(), CVT_V812_FIXED_CODE_INDEX, FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_get_manufacturer_number cvt_V812_data p_data,
UINT8 p_value
 

Gets the manufacturer number.

Reads the manufacturer number register. It must return CVT_V812_MANUFACTURER_NUMBER_VALUE

Parameters:
p_data Pointer to board data
p_value The value read
Returns:
TRUE: Procedure successfully executed
See also:
CVT_V812_MANUFACTURER_NUMBER_VALUE

Definition at line 271 of file cvt_V812.c.

References cvt_read_reg(), CVT_V812_MANUFACTURER_INDEX, FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_get_module_type cvt_V812_data p_data,
UINT16 p_value
 

Gets the module type.

Reads the module type register. It must return CVT_V812_MODULE_TYPE_VALUE

Parameters:
p_data Pointer to board data
p_value The value read
Returns:
TRUE: Procedure successfully executed
See also:
CVT_V812_MODULE_TYPE_VALUE

Definition at line 287 of file cvt_V812.c.

References cvt_read_reg(), CVT_V812_MANUFACTURER_INDEX, FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_get_serial_number cvt_V812_data p_data,
UINT16 p_value
 

Gets the serial number.

Reads the serial number register.

Parameters:
p_data Pointer to board data
p_value The value read
Returns:
TRUE: Procedure successfully executed
See also:
CVT_V812_MODULE_TYPE_VALUE

Definition at line 319 of file cvt_V812.c.

References cvt_read_reg(), CVT_V812_VERSION_INDEX, FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_get_version cvt_V812_data p_data,
UINT8 p_value
 

Gets the module version.

Reads the module version register.

Parameters:
p_data Pointer to board data
p_value The value read
Returns:
TRUE: Procedure successfully executed

Definition at line 303 of file cvt_V812.c.

References cvt_read_reg(), CVT_V812_VERSION_INDEX, FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_open cvt_V812_data p_data,
UINT16  base_address,
long  vme_handle
 

V812 VME boards data initialization.

Provides specific handling for V812 boards opening.

Parameters:
p_data Pointer to board data
base_address The board base address (MSW)
vme_handle The VME handle
Returns:
TRUE: board successfully opened
Note:
Must be called before any other board specific API.

Definition at line 81 of file cvt_V812.c.

References cvt_board_open(), FALSE, cvt_V812_data::m_common_data, and TRUE.

BOOL cvt_V812_set_dead_time cvt_V812_data p_data,
UINT8  value
 

Set the dead time register.

Writes the specified value to the dead time register for channel 0-7 and 8-15.

Parameters:
p_data Pointer to board data
value The value to set
Returns:
TRUE: Procedure successfully executed

Definition at line 190 of file cvt_V812.c.

References CVT_V812_DEAD_TIME_0_7_INDEX, CVT_V812_DEAD_TIME_8_15_INDEX, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_set_majority_threshold cvt_V812_data p_data,
UINT8  value
 

Set the CVT_V812_MAJORITY threshold register.

Writes the specified value to the CVT_V812_MAJORITY threshold register.

Parameters:
p_data Pointer to board data
value The value to set
Returns:
TRUE: Procedure successfully executed

Definition at line 210 of file cvt_V812.c.

References CVT_V812_MAJORITY_INDEX, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_set_output_width cvt_V812_data p_data,
UINT8  value
 

Set the output width register.

Writes the specified value to the output width register for channel 0-7 and 8-15.

Parameters:
p_data Pointer to board data
value The value to set
Returns:
TRUE: Procedure successfully executed

Definition at line 170 of file cvt_V812.c.

References CVT_V812_OUT_WIDTH_0_7_INDEX, CVT_V812_OUT_WIDTH_8_15_INDEX, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_set_pattern_inhibit cvt_V812_data p_data,
UINT16  value
 

Set the pattern of inhibit register.

Writes the specified value to the pattern of inhibit register.

Parameters:
p_data Pointer to board data
value The value to set
Returns:
TRUE: Procedure successfully executed

Definition at line 225 of file cvt_V812.c.

References CVT_V812_PATTERN_INHIBIT_INDEX, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_set_test_pulse cvt_V812_data p_data  ) 
 

Set the test pulse register.

Writes a dummy value to the test pulse register.

Parameters:
p_data Pointer to board data
Returns:
TRUE: Procedure successfully executed

Definition at line 240 of file cvt_V812.c.

References CVT_V812_TEST_PULSE_INDEX, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, TRACE, and TRUE.

BOOL cvt_V812_set_threshold cvt_V812_data p_data,
cvt_V812_threshold_id  threshold_id,
UINT16  value
 

Set the specified discriminator threshold register.

Writes the specified value to the specified discriminator threshold register. If threshold_id is CVT_V812_THRESHOLD_ALL every threshold will be setted to the same value.

Parameters:
p_data Pointer to board data
threshold_id The threshold to set. It must be a cvt_V812_threshold_id valid id.
value The value to set
Returns:
TRUE: Procedure successfully executed
See also:
cvt_V812_threshold_id

Definition at line 118 of file cvt_V812.c.

References CVT_V812_MAX_THRESHOLD, CVT_V812_THRESHOLD_0, CVT_V812_THRESHOLD_0_INDEX, CVT_V812_THRESHOLD_ALL, cvt_write_reg(), FALSE, cvt_V812_data::m_common_data, and TRACE1.


Generated on Wed Oct 18 12:36:56 2006 for CAEVMEToolLib by  doxygen 1.4.6-NO