Skip to content

Waiting to read for all R/W operations to complete, logging on loop #17

Description

@jatin-03-afk

When does this occur:

When PLC is disconnected and reconnected physically

Image

Expected behaviour

Reconnect to the PLC, read and return values

Behaviour in WSL

This works as expected in WSL environment where removing the PLC rj45 connector starts the console log
Waiting to read all R/W operations to complete. Will re-trigger readAllItems in 100ms ( on a loop )
Meanwhile the read data is empty
After connecting the PLC the loop stops in a few seconds and read data is sent correctly

Behaviour on Windows

Removing the RJ45 connector brings up a bunch of different logs

Unable to read when not connected. Return bad values.
READ TIMEOUT on sequence number

After connecting the PLC it attempts to connect shows TCP connection is successful on host:port

And then there's a loop of
Waiting to read all R/W operations to complete. Will re-trigger readAllItems in 100ms ( on a loop )
Overall the behaviour is a little unpredictable

The reason it's happening is because it's triggering this

Image

Some futile efforts to make it work included:

Image

Started off by resetting a few things then added more to experiment, either readAllItems doesn't have addresses it needs ( in which case there's no read ) or it goes back to the stale data and goes into the isWaiting loop

Please share your thoughts and also if there's any information you need do let me know

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