[Etherlab-users] User mode "Register" access methods

Moebius, Volker Volker.Moebius at baader.com
Wed Apr 22 16:16:24 CEST 2026


Hello everyone,

The `ethercat` CLI tool implements the "Register Access" functions `reg_read` and `reg_write`. These functions are using EC_IOCTL_SLAVE_REG_READ and EC_IOCTL_SLAVE_REG_WRITE to execute these methods. (lines 433ff of tool/MasterDevice.cpp<https://gitlab.com/etherlab.org/ethercat/-/blob/stable-1.6/tool/MasterDevice.cpp?ref_type=heads#L433>)

Is there a reason why possibly corresponding methods for "Register Read" and "Register Write" aren't implemented in the "normal" user mode C API (include/ecrt.h)? Don't these methods make sense for controlling EtherCAT slaves?

I'm unfortunately not an EtherCAT expert and I'm confused about the different data objects and communication objects. Are the functions `ecrt_slave_config_create_reg_request`, `ecrt_reg_request_data`, `ecrt_reg_request_state`, `ecrt_reg_request_write` and `ecrt_reg_request_read` related to the same "Register Access" ("Slave Registers") as implemented by the CLI? Or do they manage a different kind of registers?

.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.etherlab.org/pipermail/etherlab-users/attachments/20260422/82669402/attachment.htm>


More information about the Etherlab-users mailing list