Cascade Driver for Hilscher Fieldbus CIF Cards: Version 4.1
Prev |  | Next

# defineStatusPoint

defineStatusPoint -- names a driver status point.

## Synopsis

    (defineStatusPoint point_name)

## Parameters

`point_name`

  Name of the status point to be created.

## Returns

`OK` or `(error)`

## Description

This command names a special point that the driver publishes to the Cascade DataHub containing the overall status of the driver. Clients may monitor this point to determine the overall health of the driver. A value of `0` indicates no errors are being detected.

The status point is a 32-bit integer, segmented as 1 byte for each of the CIF cards that have been initialized (up to 4, see cardInit). Card `0` corresponds to the low byte; card `3` to the high byte.

card3 | card2 | card1 | card0
--- | --- | --- | ---
high byte |  |  | low byte

Within each byte (card), each bit indicates the following information:

Bit | Value | Meaning
--- | --- | ---
0 | `0x01 CIF_STATUS_NOTREADY` | Power-up initialization unsuccessful.
1 | `0x02 CIF_STATUS_NOTRUNNING` | Card not fully operational.
2 | `0x04 CIF_STATUS_NOCOMM` | Fieldbus exchange inactive/error.
3 | `0x08 CIF_STATUS_ERROR` | Error detected.
4 | none | none
5 | none | none
6 | none | none
7 | none | none

If this command is specified more than once, the name of the status point will be the one provided by the last command. Previous status point names will not be deleted from the datahub, but they will not be updated when the status data changes.

## Example

        (defineStatusPoint drv_status)

Prev | Home | Next
defineSegment | Up | describeBuffer

Copyright 1995-2002 by Cogent Real-Time Systems, Inc.