IzoT Examples
Python 3 source code is included with the IzoT SDK for the following four example devices:
Hardware schematics are included for the first three examples. The Multiple DIO example is based on the commercial PiFace Digital I/O board.
Example Web Pages are also included for use with an IzoT Server.
You can run an IzoT example application as a service, or from the command line. The advantage of running applications as a service is that they will automatically restart when you shut down and restart your device. Running from the command line is useful for debugging because you can use the IzoT Framework console interface and you can view application console output in real-time.
The following videos describe how to access the console interface, start an IzoT example application, and create a network with the Multi DIO example application:
- Accessing the IzoT Device Console Interface
- Starting an IzoT Example Application
- Creating a Network with the Multi DIO Example
To see the status of IzoT services, enter the izot_stat command. This command displays the available IzoT services, and shows the status of each.
To start one of the example applications as a service, enter izot_enable <app_name>, where app_name is dio, keypad, led, or sensor.
Once you have enabled an example application as a service, you can disable it so that it is no longer running and will not restart on reboot with the izot_disable <app_name> command.
To run an example application as a service one time so that it does not start on reboot, enter izot_start <app_name>.
To stop an example application that is running as a service, enter izot_stop <app_name>.
To run an example application from the command line, change to the example directory in the izot-sdk/izot/examples directory, and then enter supy <python_app_name> followed by any command line parameters. The command line parameters are described in the following pages:
- Running the Environment Sensor Application
- Running the LED Controller Example
- Running the Touch Keypad Example
- Running the Multi DIO Application
When you run an example from the command line, you can use any of the IzoT Framework console commands described in Adding a Console Menu.
This section consists of the following: