AIO all channels loopback

 1'''
 2AIO - AIO_all_channels_loopback.py.
 3
 4This example demonstrates the process of AIO loopback across all channels.
 5It involves using AO pins to send signals and AI pins to receive signals on a single device, commonly referred to as "loopback".
 6The AI and AO pins are connected using a wire.
 7The AO range is -10 to 10 V.
 8
 9First, it reads AI data and displays its corresponding values.
10Following that, it writes digital signals to the AO pins and reads AI on demand data once again.
11
12For other examples please check:
13    https://github.com/WPC-Systems-Ltd/WPC_Stand-alone_Python_release/tree/main/examples
14
15Copyright (c) 2024 WPC Systems Ltd.
16All rights reserved.
17'''
18
19## WPC
20import pywpc
21
22## Read data acquisition
23ai_data = pywpc.AI_readOnDemand()
24print(ai_data)
25
26## Write AO value simultaneously
27voltage_list = [-10, -7.5, -5, -2.5, 3.5, 5.5, 7.5, 10]
28status = pywpc.AO_writeAllChannels(voltage_list)
29print("AO_writeAllChannels status: ", status)
30
31## Read data acquisition
32ai_data = pywpc.AI_readOnDemand()
33print(ai_data)