Super basic Qt application with an embedded console to interact with TwinCAT ADS.
This is made with pyads, PySide6 and qtconsole.
- Use the
plcvariable for the local ADS connection. - Returned symbols are patched with respect to the
pyadsdefault: there is a__getattr__implementation to automatically retrieve child symbols.
E.g.:var = plc.get_symbol("GVL_Main.fbBlock") sub_var = va.fOutput # The PLC field `fOutput` must exist sub_var.read() # Ends up reading "GVL_Main.fbBlock.fOutput"
Perform a user-wide install with pipx through:
pipx install git+https://github.com/RobertoRoos/pyads-console@main
Or clone and then install with uv (preferred over Pip):
uv sync
Or with Pip directly:
pip install .
Start the application through uv (which will automatically handle dependencies):
uv run pyads-console
Or start the application from Python with:
python -m pyads_console
Or use the executable directly:
pyads-console.exe
