Page 1 of 1

Codesys hat keine IO Kontrolle und kann config.rsc nicht schreiben

Posted: 25 Jun 2026, 15:41
by wilbersl
Hi,

Ich habe einen RevPi Connect 5 mit Bookworm, keine ausstehenden Updates. Jetzt wollte ich meine ersten Gehversuche mit Codesys machen. Ich nutze IO Treiber Version 3.0.0 habe aber auch schon 2.5.0 ausprobiert.

codesyscontrol.log zeigt mir anfangs:

Code: Select all

ErrorCode: 9, CDIOCTL Failed! wConnectorTYPE: 40202, uiPImoduleOffset: 0, dwParameterID: 203, dParameter: 0
ErrorCode: 8193, Write to config.rsc failed!
ErrorCode: 8193, open in ACCESS_MODE.AM_WRITE_PLUS failed for config.rsc
Access to path /dev/piControl0 not allowed. Add /dev/piControl0 to permitted paths in configuration file if required
Io-Config not possible in Application
SysEthernetLinuxXdpInit: failed to open libxdp.so, no XDP support
mittlerweile bekomme ich noch:

Code: Select all

ErrorCode: 9, CDIOCTL Failed! wConnectorTYPE: 40202, uiPImoduleOffset: 0, dwParameterID: 203, dParameter: 0
ErrorCode: 8193, Write to config.rsc failed!
ErrorCode: 8193, open in ACCESS_MODE.AM_WRITE_PLUS failed for config.rsc
SysEthernetLinuxXdpInit: failed to open libxdp.so, no XDP support
nachdem ich in /etc/codesyscontrol/CODESYSControl_User.cfg

Code: Select all

PermittedPath.3=/dev/piControl0
eingefügt habe.

Ich habe auch

Code: Select all

[SysFile]
PlaceholderFilePath.2=/etc/revpi, $configrsc$
schon ausprobiert, das hat aber nichts geändert...

Ich wäre schon zufrieden, wenn die LEDs blinken https://revolutionpi.com/de/tutorial/overview ;)

Re: Codesys hat keine IO Kontrolle und kann config.rsc nicht schreiben

Posted: 26 Jun 2026, 09:21
by wilbersl
I was able to make it work, with running codesyscontrol as root. But that can't be the preferred solution, or is it?

Re: Codesys hat keine IO Kontrolle und kann config.rsc nicht schreiben

Posted: 26 Jun 2026, 12:29
by nicolaiB
Hi

CODESYS changed with a recent update of their runtime the behaviour and now runs as a service user (which I appreciate). Unfortunately this means, that the service users needs to be member of some extra groups in order to access the RevPi resources it could access before:

- piControl (for driver access)
- www-data (for writing the configuration file)
- dialout (if access to the serial interfaces like RS485 is needed)

Nicolai

Re: Codesys hat keine IO Kontrolle und kann config.rsc nicht schreiben

Posted: 26 Jun 2026, 13:04
by wilbersl
Hi Nicolai,

thank you for the input. I found that the group www-data had no write access on /var/www/revpi/pictory/projects/_config.rsc so I fixed that with

Code: Select all

sudo chmod 664 /var/www/revpi/pictory/projects/_config.rsc
Maybe that could be included in the Revpi OS Image. Other than that it worked :) .

Quick recap:
- Add PermittedPath.3=/dev/piControl0 to /etc/codesyscontrol/CODESYSControl_User.cfg
- Give www-data Group write access to /var/www/revpi/pictory/projects/_config.rsc
- Add piControl and www_data Group to codesyscontrol user

With this I can finally let some LEDs blink, without giving codesys root access :lol: