Table of Contents

sys_get

FW >= 1300

Get a system parameter

Description

int sys_get ( string $parameter )

This function will get an internal function parameter and return the value.

Parameters

$parameter: The parameter must be one of the following:

Parameter Description
disk_write_counter Get the number of writes
disk_read_counter Get the number of disk reads
disk_write_errors Get disk write error count
MODBUS_TCP_CONNECTION_COUNT Get the number of Modbus TCP Connections possible
DEVICE_ID Get the micro controller type ID
MODBUS_2_ENABLED Get status of Modbus channel 2
MODBUS_TCP_ENABLED Get the status of Modbus TCP
FLASH_STATUS Status (1=not mounted, 2=No disk, 4 = protected)
FLASH_ID Get the Flash JDEC ID
FLASH_SIZE Get the Flash size in MB

Note

The parameters are case sensitive - not all parameters will be available, depending on the hardware (i.e. Flash may not be onboard).

Return Values

int: Parameter value

Examples

<pre><?
  print("Your flash chip is ".sys_get("FLASH_SIZE")."\r\n"));
?></pre>