Skip to content

Creating Your Own Webpages

If instead of modifying the existing pages, you would like to create your own pages, you can do so easily by placing your source files in the /http/ directory of the filesystem. You will need to create the directory first.

Any HTML file placed there will be served at the root of the web server. That is, if you create a file called /http/test.html, it will be seen at address:

http://<ip-address-of-xPico-gateway>/test.html

Accessing Configuration and Status

To access gateway configuration and status from your own custom web pages, you can use the Web API with Javascript transactions to get the XML data (XCR for configuration, XSR for status). With the Web API you can:

  • View current configuration
  • Upload new configuration
  • View current status
  • Take status actions (such as toggling GPIO, sending data to serial ports, etc.)

See WebAPI Reference for more details and Javascript examples.

JavaScript Library

The xPico Wi-Fi Web API Javascript Library also applies to xPico 600 devices. This library makes it easy to use the xPico 600's Web API to access the hardware features of the device. The library takes care of all the HTTP transactions and XML building and parsing for you.

See the xPico Wi-Fi Web API JavaScript Library on GitHub.