Dynamic variables index

This pages documents the dynamic variables available in the Plug & Program firmware loaded on the NetSat1 embedded webserver.

(Source code is here )

an(n)

Purpose: Read an AD converter

Parameters: Analogue channel n (0-15)

Returns : return a raw value (0-1023)

Example : Read raw value of AD channel 1

~an(1)~

es1(x)

Purpose: Read from PNP-ENVSENSE connected to MC32MX64GP.IO3

Parameters:

es1(0) = Ambiant Light

es1(1) = Temperature

es1(2) = Barometric pressure

es1(3) = Relative Humidity

Returns:

es1(0) = an arbitrary light value

es1(1) = Temperature in celcius

es1(2) = Barometric pressure in kPa

es1(3) = Percent relative humidity

Example: Read humidity

~es(3)~

lcdbldim

Purpose :  Read the current backlight dim setting of the PNP-LCD16x2 module

Parameters: None

Returns:

  • 0 (low) to 20 (high)

Example:

~lcdbldim~

lcdblmode

Purpose :  Read the current backlight mode setting  of the PNP-LCD16x2 module

Parameters: None

Returns:

  • 0 – off
  • 1- on
  • 2- use fixed dim setting per ~lcdbldim~
  • 3 – pulse using:
    • max brightness per dim setting ~lcdbldim~
    • cycle speed per ~lcdblspeed~

Example:

~lcdblmode~

lcdbldim

Purpose :  Read the current backlight dim setting of the PNP-LCD16x2 module

Parameters: None

Returns:

  • 0 (fast) to 20 (slow)

Example:

~lcdblspeed~

ledh(x)

Purpose :  Read the current state of high (top row) LED0-7 (modules PNP-LED4L & PNP-LED4R)

Parameters: Target LED 0-7

Returns:

  • 1 (On)
  • 0 (Off)

Example: Read current state of high (top row) LED3

~ledh(3)~

ledl(x)

Purpose :  Read the current state of low (bottom row) LED0-7 (modules PNP-LED4L & PNP-LED4R)

Parameters: Target LED 0-7

Returns:

  • 1 (On)
  • 0 (Off)

Example: Read current state of low (bottom row) LED3

~ledl(3)~

ledsmode

Purpose :  Read the current mode of the PNP-LED4L & PNP-LED4R LED modules

Parameters: None

Returns:

  • 0 – 11

Example:

~ledsmode~

ledmb

Purpose :  Read the current state of the mainboard onboard heartbeat LED

Parameters: None

Returns:

  • 1 (High)
  • 0 (Low)

Example:

~ledmb~

listfiles(x)

Purpose: lists contents of the MPFS2 filesystem image as hyperlinks

Parameters:

listfiles(e) lists contents of MPFS2 file system image stored on external memory

listfiles(i) lists contents of MPFS2 file system image stored on internal MCU ROM

Returns: A table of all files in the targeted MPFS2 file system image as click-able hyper-links

Example: List all files currently in the external memory

~listfiles(e)~

ntpgmt

Purpose: Read the current NTP time (if NTP servers available)

Parameters: None

Returns: Date Time as text

Example:

~ntpgmt~

requestip

Purpose: Get the IP address of the end user requesting this page

Parameters: None

Returns: Ip Address

Example:

~requestip~

version_jquery

Purpose: Get the version of the JQuery library embedded in the firmware

Parameters: None

Returns: JQuery library version

Example:

~version_jquery~

version_jqueryflot

Purpose: Get the version of JQuery FLOT charting library embedded in the firmware

Parameters: None

Returns: JQuery library version

Example:

~version_jqueryflot~

version_jqueryui

Purpose: Get the version of JQueryUI library embedded in the firmware

Parameters: None

Returns: JQuery library version

Example:

~version_jqueryui~

version_microchip

Purpose: Get the version of the Microchip TCPIP Statck used as the starting point for the Plug & Program firmware

Parameters: None

Returns: Base Microchip Application Library TCPIP Stack version

Example:

~version_microchip~

version_firmware

Purpose: Get the version no of the Plug & Program firmware currently running

Parameters: None

Returns: Plug & Program firmware version

Example:

~version_firmware~