Hennes
I have looked and found nothing yet. Is there an easy way to access the I/Os of one or two printer ports via the PLC server on the same machine? On Linux this is not so unusual, there are several Python modules, LinuxCNC, ClassicLadder that do this.
Quote 0 0
thiagoralves
Hi Hennes, this is just a matter of writing a driver (hardware layer) that can control those pins. Since PCs with parallel port nowadays are vintage rarities I never thought about writing a driver for this. However it should be quite straightforward if you take one of the drivers as a guide (for example, the Raspberry Pi driver at OpenPLC_v3/webserver/core/hardware_layers/raspberry_pi.cpp)
Quote 0 0
Hennes
Thank you, I have already answered the question myself in a similar way. Yes, I know, it's the question about a suitable driver.
But it is only straightforward to adapt one if you are a good C/C++ programmer, and I am not. But I will have a look at raspberry_pi.cpp anyway.
I want to disagree with you about parallel ports. The printers may be vintage rarities but not the interface on the PC, especially on Linux.
Most LinuxCNC users with their hobby milling machines prefer to use the parallel port for direct control of stepper motors, and there are quite a few.
Even an RTAI kernel is maintained for this (worst case on my dedicated machine 16 µs jitter).
Quote 0 0