1

I am using libnodave 0.8.4.4 library to connect to a S7 PLC and what I would like to know if how can I detect if a bit (e.g. DB100.DBX8.0) in PLC DB changes its value. What I did is to read this bit within a while loop but I would like to create an event on value changed on this bit and launch a task when it happens.

Willy
  • 9,848
  • 22
  • 141
  • 284

1 Answers1

1

There is no default event available with libnodave or any other libraries like S7.net.

Either you need to use OPCor write your own function which will read the set of bits set on time and notify to the main program.

Olivarsham
  • 1,701
  • 5
  • 25
  • 51
  • 1
    I use libnodave with Delphi and in my app I need to know if a bit is on in order to read the PLC data. I've used a timer for this task. Every second (I nedd to test the bit every second) it fire a funcion that read the bit I need and if it is on I read the data from the PLC. – Eros May 09 '16 at 20:29