Need Python 3.7 or higher. Install from here https://www.python.org/downloads/
Install the needed libraries:
pip install -r .\requirements.txt
Run the OPC-UA server with default config from a shell:
python opcua_server.py
Edit the file opcua-client.py to apply the scope id and group SAS key for your IoT Central application:
Add scope-id and group SAS key to lines 22 and 23 of opcua-client.py
scope_id = "<Put your scope id here from IoT Central Administration -> Device connection>"
group_symmetric_key = "<Put your group SAS primary key here from IoT Central Administration -> Device Connection -> SAS-IoT-Devices>"
Run the OPC-UA client from a shell:
python opcua_client.py
Ctrl-C the python processes in there respective shells. This is no glamour code!
To export the list of nodes to a JSON file in a compatible format for the IoTC Industrial ADT tool (https://github.com/iot-for-all/iotc-industrial-adt) run the OPC-UA client in this way:
python opcua_client.py --dump <FILE_PATH>
This will not run the client process and exits immediately after producing dump file.