Project

General

Profile

Front-end Framework

Our current front-end framework is implemented using the "soft real-time" language, Erlang, and runs on Linux-based systems. We have instructions to set-up an Erlang environment for your system.

Writing device drivers

There are two ways a device driver can be written. Each has advantages/disadvantages, so you have to decide which is the most appropriate for your situation.

Native Erlang Driver

We have an article describing how to write a native Erlang driver using our Erlang Driver API.

Debugging a Front-end

Native drivers should be used when the hardware is accessed over the network because it's very easy to do network communications using Erlang.

C++ driver

We also provide a C++ Driver API so drivers can be written in C++.

Supported Drivers

These are the various drivers that have been written for the framework. We encourage pure Erlang drivers, but there are cases where a C/C++ driver is necessary. In those cases, the cdev API is used to interface with the Erlang framework.

Undocumented

ACSYS Facility Code

We plan to create a new ACNET facility code so the ACSys framework will have its own set of ACNET status value. The following table contains the proposed codes1.

Warnings
Status Description
ALARM_CONDITION_IGNORE Conditions mean alarm limits are ignored (no alarms raised)
NO_RECENT_DATA No recent data of this type was found.
OPERATION_DISABLED The requested operation is presently disabled.
Errors
Status Description
NO_SUCH_OID This OID is not defined. An attempt was made to fulfill a method for an undefined OID. Most likely this is a problem with the database entry. Please, contact the front end maintainer.
BAD_FTD Bad Frequency Time Descriptor (FTD).
BAD_SET_PARAMS Bad setting parameters.
BAD_OFFSET Invalid offset. Offsets are, typically, a multiple of the device's atomic size. Most likely this is a database entry problem.
BAD_LENGTH Invalid length. Lengths are, typically, a multiple of the device's atomic size. Most likely this is a database entry problem.
BAD_OFFSET_LENGTH Bad offset plus length. In this case, the length and offset both appear to be valid, but their combined values exceed the size of the device. Most likely this is a database entry problem.
SET_TMO Setting timeout
BAD_CHANNEL This channel number is not supported by this device. Most likely this is a database entry problem.
BAD_BASIC_CONTROL Unsupported basic control word. Most likely this is a database entry problem.
DEV_NOT_UPDATING The associated hardware is no longer updating. This could be due to something as simple as the device being disabled or in local mode. Or it could mean the hardware is failing. Contact the front-end maintainer.
HARDWARE_FAULT The associated hardware is in a fault state. Various reasons will cause hardware to go into a faulted state. Sometimes the BASIC STATUS indicates the cause. Contact the front-end maintainer.
NO_ALARM An attempt was made to read an alarm block that hasn't been downloaded.
CANNOT_FTP This property is not supported by the current FTP support. See what property you are specifying for plotting. The allowed ones are reading, reading the setting, and basic status.
EVENT_OVERLAP This event overlapped with the previous one. Data collection was not done.
ALARM_BAD_TYPE Bad type value in an analog alarm block. The type value is in the third byte of the 6-byte long subsystem data area. It and the Q field of the flags word completely specify the type of the the parameter being scanned.
ALARM_BAD_Q Bad Q field value in an alarm block. Either the Q value is invalid (e.g. 3), or is not valid for the given type (e.g. 0 or 1 for a float).
ALARM_NO_TYPE No type specified in an analog alarm block, and the front end does not know the type either.
DEVICE_ERROR The Device Accessor can't fulfill this request (generic error).
READ_TIMEOUT This reading has timed out. It probably is due to an event not occurring.
SETS_DISABLED Settings to this device are presently disabled. This can be enabled by issuing an enable to the device.
DRIVER_FAILED The device driver failed.

1 The list was initially taken from the MOOC facility. We then removed non-framework codes (i.e. errors for SWICs, PLCs, etc.) which created our base set of statuses.