Skip to content

Concurrent read/writing of T_O_IOData/O_T_IOData #1

Open
@twoudsma

Description

@twoudsma

Hey!

Is there any plan to make the read/writing of T_O_IOData/O_T_IOData thread-safe? This is not an issue when reading separate bytes, but the Ethernet/IP device I am using also defines Int32 variables (4 bytes). When reading the T_O_IOData array, it might contain both bytes from the previous cycle and the current one resulting in an Int32 that was not actually on the device. The same issue can occur for the output O_T_IOData.

Accessing the T_O_IOData and O_T_IOData arrays through a property with a lock can solve this issue. Also an Array.Copy is probably faster than looping over the elements.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions