550 708 01

Draft

 

PD 662 Service Channel (channel 0)

 

Registers in Service channel.

RegNo

Identifier

Memory type

Read Out

Type

0

NumberOfSWNo

PROM Read only

-------

Record

1

DeviceID

PROM Read only

-------

Record

2

Notification

RAM Read only

Binary

Bit8

3

Reset

RAM Read Write

Decimal

Byte

4

PNETSerialNo

Special function

-------

Record

5

 

 

 

 

6

 

 

 

 

7

FreeRunTimer

RAM Read only

Decimal

LongInteger

8

 

 

 

 

9

EnableNotification

EEPROM RPW

Binary

Bit8

10

 

 

 

 

11

 

 

 

 

12

NetParam

EEPROM RPW

-------

Record

13

WriteEnable

RAM Read Write

Binary

Boolean

14

Guid

PROM Read only

-------

String

15

ChError

RAM Read Write

-------

Record

 

 

RegNo 0: NumberOfSWNo

 

 

NumberOfSWNo:

Integer;

 

 

This constant holds the highest SWNo in the device. It occupies the same memory location as the NumberOfSWNo field in the DeviceID record below, but is declared as an Integer.

 

Record

 

 

NumberOfSWNo:

Word;

 

 

DeviceGUID:

String[22];

 

 

Reserved1:

Byte;

 

 

HardwareGUID:

String[22];

 

 

KeyID:

Byte;

 

 

BootLoaderGUID:

String[22];

 

End;

 

 

 

This record holds the complete identification of the module, including the version number of the hardware and the software. DeviceInfo is used during the procedure when it is required to download updated firmware. The firmware download feature can be selected by right-clicking the module in the VIGO MIB

 

RegNo 1: DeviceID

The purpose of this record is to be able to identify a connected device. The record includes registered manufacturer number, the type number of the device and a string, identifying the manufac­turer.

 

The record is of the following type:

Record

 

(* Factory setting *)

 

DeviceNumber:

Word;

(* 662 *)

 

ProgramVersion:

Word;

(* 100 *)

 

ManufacturerNo:

Word;

(* 1 *)

 

Manufacturer:

String[20];  

(* "PROCES-DATA DK" *)

End;

 

 

 

 

 

RegNo 2: Notification

 

 

Notification:

Bit8;

 

 

A notification is used to inform users of variable values when new values are available. Several conditions can set the notification bit and the conditions can be chosen in ChConfig.Notification / NotificationEnable on each channel. The Notification register is cleared automatically after a read. After a power-up all notification bits are set.

 

7

 

 

 

 

 

 

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0: Service Channel

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1: Redundancy Channel

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

4:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

6:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7:

 

 

 

 

 

 

 

 

 

 

 

 

RegNo 3: Reset

 

 

Reset:

Byte;

 

 

By writing 255 to the Reset variable, the device performs a reset, and ExternalReset in ChError is set TRUE. Any other value than 255 can cause random behaviour.

 

 

 

RegNo 4: PNETSerialNo

This Variable is a record of the following type:

 

Record

 

(* Factory setting *)

 

PNETNo:  

Byte;

(Node Address)(* 0 *)

 

SerialNo:

String[20];

(* "xxxxxxxxPD" *)

End;

 

 

 

The serial number is used for service purposes and as a 'key' to setting the device's P-NET Node address.

A special function is included for identifying a device connected to a network containing many other devices, having the same or unknown node addresses, and to enable a change of the node address via the P-NET.

Setting a new node address via the P-NET is performed by writing the required node address together with the serial number of the device in question, into the PnetSe­rialNo at node address 126 (calling all devices). All devices on the P-NET will receive the message, but only the device with the transmitted serial number will store the P-NET node address.

 

 

RegNo 7: FreeRunTimer

 

 

FreeRunTimer:

LongInteger;

 

 

FreeRunTimer is a timer, to which internal events are sync­hronized. The timer is of type LongInteger in 1/256 Second.

 

 

 

RegNo 9: EnableNotification

 

 

EnableNotification:

Bit8;

(* Factory setting = 0 *)

 

The notification function can be enabled as shown below.

7

 

 

 

 

 

 

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0: Change_in_ChError.Act

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

4:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

6:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7:

 

 

 

 

 

 

 

 

 

 

 

                       

RegNo 12: NetParam

 

Record

 

(* Factory setting *)

 

Baudrate:

LongInteger;

(* 76800 *)

 

Errorcheck:

Boolean;

(* 0 *)

 

Reserved:

Byte;

(* 0 *)

End;

 

 

 

Baudrate:  This variable holds the baud rate for the PD 662. 

 

 

Errorcheck:

False:

P-NET Default Error check (1 byte)

 

True:

P-NET Extended Error check (2 byte)

 

 

 

RegNo 13: WriteEnable

 

 

WriteEnable:

Boolean;

 

 

Write protected variables can only be changed when Write­Enab­le is TRUE. After reset, WriteEnable is set to FALSE.

 

 

 

RegNo 14: Guid

Each channel in an interface device consists of a unique guid.

 

 

Guid:

String[22];

(* PD/550708-XX *)

 

 

 

 

RegNo 15: ChError

 

Record

 

 

 

His:

Bit8;

 

 

Act:

Bit8;

 

End;

 

 

 

There are two sets of error bits, actual and historical. The actual error bits reflect the current situation and will automatically follow the situation.

The historical error bits reflect the history and have the purpose of holding sporadic errors. The historical error bits are set together with the corresponding actual bits, and cleared by the host. Only the bits where the corresponding actual bit is false can be cleared.

The “His data error” bit in the P-NET response is set if any historical bit is true.

The “Act data error” bit in the P-NET response is reflecting the validity of the data in the response. Overload, electrical error or an error in other registers involved in calculating the result gives “Act data error”.


 

7

 

 

 

 

 

 

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0: Program_storage_fault

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1: RAM_storage_fault

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2: InternalReset

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3: ExternalReset

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

4: EEPROM_error_in_PNETSerialNo

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5: EEPROM_error_in_NotificationEnable

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

6: EEPROM_error_in_NetParam

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7:

 

 

 

 

 

 

 

 

 

 

The following bits also appears in ChError in all channels, and will cause Act error in the

P-NET response on access to all variables.

 

Bit 0               Program_storage_ fault is set TRUE if the self-test finds an error in the program memory.

 

Bit 1               RAM_storage_fault is set TRUE if the self-test finds an error in the data memory (RAM).

 

The following bits also appears in ChError in all channels, and will only be set in His.

 

Bit 2               InternalReset is set TRUE if a reset is caused by a power failure, or if the power has been disconnected.

 

Bit 3               ExternalReset is set TRUE if a reset is caused by writing 255 to Reset, via P‑NET.

 

The following bits are set TRUE if the self-test finds an error in the data memory (EEPROM) for the variable.

EEPROM fault is only set at power-up. If the corresponding variable is accessed, Act error in the P-NET response is set.

This error can occur if the power disappears when writing to EEPROM. A rewrite to the variable might solve the problem.

 

Bit 4               EEPROM_error_in_PNETSerialNo.

Bit 5               EEPROM_error_in_NotificationEnable.

Bit 6               EEPROM_error_in_NetParam.