===================================================================== = API-AIO(LNX) Additional Sample Programs = = In Range Out Range = = Ver.1.00 = = CONTEC Co., Ltd. = ===================================================================== - Introduction ======================= This package is the additional sample programs to show usage examples that are not presented in the sample programs of the development environment for API-AIO(LNX). Please use it as a reference when using the API-AIO(LNX) development environment. - Specification ======================= [Supported driver] API-AIO(LNX) [Supported development languages] gcc (C, C++) Python (3.12) [Supported devices] Devices equipped with In Range and Out Range function - About this sample ======================= This is a sample program that sets start condition and stop condition to In Range or Out Range and performs sampling. In this sample program, start condition and stop condition can be specified in any value. =================================================================================================================== Sampling conditions |Setting sampling conditions |How to change * =================================================================================================================== Input method |Single-end input |Source code Input range |+/- 10[V] |Source code Memory type |FIFO |Source code (Change notice) Clock type |Internal clock |Source code Sampling clock |1000[usec] |Source code Start condition |Any value |Console Start condition comparison channel |0 |Source code (Change notice) Start condition upper limit |Any value |Console Start condition lower limit |Any value |Console Start condition state-holding times|Any value |Console Stop condition |Any value |Console Stop condition comparison channel |0 |Source code (Change notice) Stop condition upper limit |Any value |Console Stop condition lower limit |Any value |Console Stop condition state-holding times |Any value |Console Number of channels |1 |Source code Event factor |Event that AD conversion start |Source code (Change notice) |Event that device operation end |Source code (Change notice) |Event that the specified number of data are stored|Source code (Change notice) =================================================================================================================== * How to change Source code : Conditions can be changed in the source code. Source code (Change notice) : Conditions can be changed in the source code, but please note that it may not work. Console : Any value can be set from the console. - Glossary ======================= [In Range] It is a condition to be set as the sampling start condition or sampling stop condition. The condition is satisfied when the input value of the specified channel is within the range of the upper limit value and the lower limit value, and sampling has been performed for the number of state-holding times. [Out Range] It is a condition to be set as the sampling start condition or sampling stop condition. The condition is satisfied when the input value of the specified channel is outside the range of the upper limit value and the lower limit value, and sampling has been performed for the number of state-holding times. - Usage ======================= 1. Initialization - Select the command [1 : Device Init] to specify the device name. - Sampling conditions are set in the [Device Init]. If you want to change the sampling conditions, change the value of the setting you want to change. 2. Start Condition Setting - Select the command [2 : Start Condition Setting] to specify the start conditions. 3. Stop Condition Setting - Select the command [3 : Stop Condition Setting] to specify the stop conditions. 4. Sampling Start - Select the command [4 : Sampling Start] to start sampling. 5. Sampling Complete - When the stop condition is satisfied, sampling ends. - After the sampling is completed, the start sampling data and stop sampling data will be output to a file. - Select the command [5 : Sampling Stop] to stop sampling regardless of the stop conditions. 6. Exit handling of device - Select the command [6 : Device Exit] to perform the exit handling of device. - Version History ======================= Ver.1.00 (Web Release 2024.09) ---------------------------------------- - First release