551 214 02

 

Keyboard channel

 

Registers in Keyboard channel:

RegNo

Identifier

Memory type

Read Out

Type

0

KeyboardBuffer

RAM Read Write

-------

Buffer

1

 

 

 

 

2

 

 

 

 

3

 

 

 

 

4

 

 

 

 

5

 

 

 

 

6

 

 

 

 

7

 

 

 

 

8

 

 

 

 

9

ChConfig

EEPROM RPW

-------

Record

10

 

 

 

 

11

 

 

 

 

12

 

 

 

 

13

 

 

 

 

14

Guid

PROM Read only

-------

String

15

ChError

RAM Read Write

Binary

Record

 

 

RegNo 0: KeyboardBuffer

 

 

KeyboardBuffer:

Buffer[10] Of Byte;

 

 

The keyboard is scanned and the key number (1-28) is placed in the KeyboardBuffer.

If a key is pressed when another key is already being pressed, the 'Second Key' bit is set (bit 6). If a key is pressed for more than 1 sec., the repeat bit is set (bit 7) and a new scan code is inserted in the buffer every 0.25 sec.

 

RegNo 9: ChConfig

The ChConfig variable is a record of the following type:

 

Record

 

 

Enablebit:

Bit8;

 

 

Functions:

Byte;

 

 

EnableNotification:

Bit8;

 

 

User:

Byte;

 

End;

 

 

 

Enablebit

Not used.

 

Functions

Not used.

 

EnableNotification

7

 

 

 

 

 

 

0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

0: Change_in_ChError.Act

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

2:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

3:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

4:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

6:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7: New data in KeyboardBuffer

 

 

 

 

 

 

 

 

 

 

Default value: 0 (no notification). When notification is selected, the NotificationOnCh_1 will be set in the Service Channel RegNo2 in two different cases: When data is actually added to the KeyboardBuffer, and when attempting to add data to a full buffer.

 

Bit 0:  Change_in_ChError.Act.

 

Bit 7:  New data in KeyboardBuffer

 

User

This field is available for the user. Default value: 0

 

 

RegNo 14: Guid

Each channel type in an interface device consists of a unique Guid.

 

Guid:

String[22];

(*"xxxxxxxxxxxxxxxxxxxxxx"*)

 

 

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 any change.

The historical error bits reflect past situations and have the job of holding sporadic errors. The historical error bits are set together with the corresponding actual bits. They remain set after a read, so each individual bit must be cleared by setting it to FALSE. 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 reflects 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: Bufferfull

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5: EEPROM_error_in_ChConfig.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

6: Not used

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7: Not used

 

 

 

 

 

 

 

 

 

 

 

The following two bits 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).

 

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

 

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

 

Bit 4            This Error bit it set to true when the Keyboardbuffer is full. If additional keys are pressed, these will not be added to the Keyboardbuffer. The KeyboardBuffer can be emptied via P-NET by reading out the elements, element by element.

 

 

The following bit is 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, so a rewrite to the

variable could possibly solve the problem.

 

Bit 5:           EEPROM_error_in_ChConfig.