accLoggerStart (Function)

Top  Previous  Next

Architecture:

X32 / NX32 / NX32L

Device support:

CX1, SX1, MX2 turbo/encore/warp, NX-200, NX-900, LX2, LX5

Firmware version:

2.40 / 1.40.00


This function will start (or resume) logging.

The logger must first have been configured with accLoggerSetConfig.

 

 

Inputs:

Reset : BOOL (Default FALSE)

If TRUE, then all previous stored values will be removed before start.

 

Returns: INT

0

- Success.

- 1

- General error.

- 2

- Interface not open (see accOpen).

- 3

- Logger not configured.

- 4

- Logger already started.

 

Declaration:

FUNCTION accLoggerStart : INT;
VAR_INPUT
  Reset : BOOL := FALSE;
END_VAR;

 

Example:

INCLUDE rtcu.inc
 
PROGRAM example;
VAR
  buf : ARRAY [1..500] OF DINT;
END_VAR;
accOpen();
accLoggerSetConfig(buffer := ADDR(buf), size := SIZEOF(buf));
...
BEGIN
accLoggerStart(reset := TRUE);
 ...
accLoggerStop();
END;
END_PROGRAM;