No announcement yet.

Logging some tags on time base with others on event base?

  • Filter
  • Time
  • Show
Clear All
new posts

  • Logging some tags on time base with others on event base?


    I have a couple dozen tags that I'm logging every 5 seconds, I have another large set of tags that I only want to log on a button press. I was originally going to just log all the tags every 5 seconds, but this second set of tags that I only need to log on a button press will make the files ~5x larger.... is there a way I can have 1 log file running on a time basis and another log file of a completely separate list of tags log to a separate CSV file on a rising edge NO contact?

    I also have a c-more panel connected if I need to utilize that - however, the only data logging options I see don't seem to be compatible with all of the data types I'm using (mostly strings).


  • #2
    I dont believe it is possible, since Productivity has a whole data window where you set up logging and you choose either event based or time based. It may be possible to hack your way around this with ladder code, but it would be really gimmicky. I havent tried this, but perhaps if you choose to log an array in the datalogging window you could populate that array with tag data that you want to log every 5 seconds. When you push a "log button" you could have that populate the array with all the other tag data you want to log. After it gets logged, stop populating the array with those tags.
    IDK if that will work, but it may be worth a try even if the logged data wont be very legible.

    I gave up on Productivity logging long ago. It is too cumbersome and far too many limitations. Anytime I need to log, I use a BRX:
    Connect it to the Productivity with Ethernet and use Modbus TCP or EtherNet/IP to read any tags you want logged into the BRX. Set up your logging in the BRX unit however you want, such as timer based every 5 seconds and with button press. You use a "FILELOG" instruction to log whatever data you want, however you want. You can even save the different groups of tags as different files. You can also save it to internal RAM so you dont wear out an SD card's write capability. Email the logs to yourself nightly if you want to, or push the log files from RAM to the SD card every so often and once your done purge them from RAM to keep the space available. The BRX is far superior to Productivity in this area.


    • #3
      Another choice is to use a computer software package.
      AdvancedHMI is a free package that was written in VB.Net and runs on visual studio. All of the drivers are written to display (HMI) your data and communicate to the PLC via Modbus TCP or RTU.
      Writing to a text file within VB.Net is easily done.
      You could also write to a database file.

      The advantage of the database is multiple users. You can still be logging to the file and other people can be viewing the information. Viewing can be done via excel or other software.
      ACC Automation
      Connect with us on Facebook: