SgxParameterWrite (FB)

FUNCTION_BLOCK SgxParameterWrite EXTENDS AbbLConC3

SgxParameterWrite function block is employed to write the internal parameter from either RAM or EEPROM

“ParameterID” represents the byte offset from the base address to the parameter block to be accessed

“Eeprom” is selectable between temporary storage and non-volatile data retention

A new write cycle is initiated by the rising edge of “Execute” signal

InOut:

Scope

Name

Type

Initial

Comment

Inherited from

Input

Enable

BOOL

FALSE

A rising edge (Enable = TRUE) starts the operation, the output Busy goes to TRUE. All other inputs are read and considered continuously. Execution will continue forever until a falling edge (Enable = FALSE) aborts the operation. During Aborting the Busy is still TRUE. Afterward all outputs are reset.

AbbLConC3

Output

Busy

BOOL

FALSE

Operation is running (while output Error is FALSE)

AbbLConC3

Error

BOOL

FALSE

Operation is stopped with error (while output Busy is FALSE). This output is TRUE for at least one cycle or until Enable is set to FALSE. The output ErrorID gives more details about the error.

AbbLConC3

Input

Set

BOOL

FALSE

A rising edge starts a single operation of parameter write

Eeprom

BOOL

FALSE

TRUE => write parameter data into both data RAM and flash memory, FALSE => write parameter data into RAM only

DigitalOutput

BOOL

FALSE

Imaged digital output field when “general digital output” is configured

ParameterID

WORD

0

Index number or address of parameter block

ParameterData

SgxParameterData

Parameter data to be writen to strain gauge channel

Channel

POINTER TO SgxChannelIo

Instance of strain gauge channel to be connected

Output

CarryOut

BOOL

FALSE

0 => parameter write in progress; 1 => parameter write is carried out

ErrorID

ERROR_ID

ERROR_ID.NO_ERROR

Error code returned

StateReturn

WORD

0

State of parameter write cycle returned,[0] => digital output state;[1] => DONE; [8] => fixed 0; [11] => EEPROM; [12:15] => fixed function code = 3

ParameterIDReturn

WORD

0

Parameter ID returned

ParameterDataReturn

SgxParameterData

Parameter data returned