An Input is a physical pin (e.g., GPIO input) on an Octave edge device from which data can be read. After you configure an input pin for a device, a corresponding Resource will be available for that pin through which Octave can read the pin's value.
This section provides a simple tutorial for configuring and checking the value of a Resource for a GPIO input pin that has already been enabled.
For this tutorial you will need an Octave edge device that has been configured with a GPIO input pin in Octave.
Follow the steps below to enable the input Resource and view its input value:
- Navigate to Build > Device > Resources
- Locate and expand
- Locate and expand the input pin resource configured in the previous section.
- Ensure that the enable property is set to true.
- Click the Configured value column for the period property, set the value to 5, and click Set. This sets the polling period to five seconds.
- Click Apply and wait for the polling period configured in step 5 to elapse ensuring that the input pin is connected or bridged.
- Verify that the Value column for the input pin's value property toggles from true to false or vice versa for a digital input, or the value reported is as expected for an analog input. This indicates that the input pin is working correctly and that it has been configured correctly in Octave.
You should verify that a digital or analog input pin, configured in the previous sections, is receiving values and that they are being reflected correctly in Octave via the pin's Resource. Input values can be driven by either connecting the input pin to the output of your asset or by simply bridging the input pin to an output pin that is producing voltage.
Updated about 1 year ago