OpenEtherCATsociety / SOES

Simple Open Source EtherCAT Slave
Other
566 stars 247 forks source link

Add support for input- or output only slaves #119

Closed nakarlsson closed 2 years ago

nakarlsson commented 2 years ago

Seperate validation of SM configuration that depend on size of tx/rx pdo.

Add disable of SM3 when input only slave reports error in OP.

Don't enable SM3 on start input if no inputs

Don't enable SM2 on start outputs if no outputs

fix #113

nakarlsson commented 2 years ago

Sample applications that pass CTT.

xmc48_ecatslv_output_only.zip xmc48_ecatslv_input_only.zip

ArthurKetels commented 2 years ago

Except for typo, good to go. I also like the new logic, much easier to understand.

hefloryd commented 2 years ago

Looks good. I believe this also fixes #112 so perhaps mention that in the commit message as well?

nakarlsson commented 2 years ago

@hefloryd , slave editor needs to be update to handle outputs- inputs only slaves. SM objects still needs to be defined in ESI and OD. Eg. 0-elements 1C12 or 1C13 arrays.

Currently slave editor remove the SM object not used.

I manually created the samples in this PR. https://github.com/OpenEtherCATsociety/SOES/pull/119#issuecomment-1155618604