grant (Customer) asked a question.

Can the Productivity PLC(s) READ a file from the SD card?

Hello All

 

I have a P1-550 and I have an array of 2000 float values. This array is a pre-calculated table of set points for the PID. I knew from early on the P1-550 could log data to the SD card.. My plan was to populate that array with the values from a CSV file. So I just *assumed* it would read data from the SC card. Well I just got to that point of coding, and realized there is NO file READ option!?! And I did not see any FTP option either.

 

So I started searching youtube for vidoes, found a few about WRITING (Logging) to an SD card but nothing on READING a CSV file from an SD card.

 

So is it safe to assume the Productivity PLCs can NOT READ files?

 

If they CAN, PLEASE point me in that direction!

If they CANNOT, what would be a work around?

 

One possible work around I found, but, not sure of is using the "RECIPE" option of the CMore HMI? I saw a video by by Gary (ACC) and Automation Direct on the "RECIPE" option.. Where the RECIPE can be used to send values from the CMore to the PLC.

 

It mentioned a limit of I think "90" tags..

 

But what about "1" tag with 2000 values?

 

Any info would be great!!

 

Last but not least, if the P1000 can NOT, can the P2000 or P3000?

 

Grant


  • RBPLC (Customer)

    "if the P1000 can NOT, can the P2000 or P3000?"

    NO

     

    "If they CANNOT, what would be a work around?"

    Depending on your programming acumen and available resources, you could use something like PyModbus to read the CSV and transfer the values to the controller.

    Selected as Best
  • ADC Community_02 (Automationdirect.com)

    Question: So is it safe to assume the Productivity PLCs can NOT READ files?

    Answer: Correct. None of the Productivity CPU's can read from the memory device. 

     

    Will these values need to be updated or stay constant? You could import the tag values into your project and then transfer to the CPU.

    • grant (Customer)

      They will need to be updated..

       

  • RBPLC (Customer)

    "if the P1000 can NOT, can the P2000 or P3000?"

    NO

     

    "If they CANNOT, what would be a work around?"

    Depending on your programming acumen and available resources, you could use something like PyModbus to read the CSV and transfer the values to the controller.

    Selected as Best
  • Garry (Customer)

    Node-RED is another option to communicate to the Productivity series.

    https://accautomation.ca/series/node-red-iot-enabling-software/

    This flow series example will show communicating with the controller using the Modbus TCP protocol. Information is then stored in an SQLite database and shared with a spreadsheet.

    Regards,

    Garry

    ACC Automation

    Expand Post
    • grant (Customer)

      Gary!

       

      Thank you sir!

       

      I remember seeing your node-red video awhile back and thinking that is pretty neat and would come in handy! Thanks so much Gary, Your videos have help me alot over the past few years working with the Productivity PLCs

      Expand Post
  • PouchesInc (Customer)

    Node-red and pymodbus will need some sort of computer on the same network as the PLC. This is probably fine as most networks do have this already, but if for some reason you do not have a computer available for this use or you do not want a PC involved then you can use a BRX PLC to do your file reads and writes to get around the Productivity line file limitations. Either by doing the entire project in the BRX as a replacement to the P1k, or by just using the BRX as basically a filesystem controller for your PLCs. Productivity is severely lacking in filesystem instructions, and the BRX is great at that. I also make use of the built-in ram in the BRX, to read and write temp data that is stored and then only write final numbers to the SD card to keep the flash writes down. Having a BRX for this purpose is nice because you can use its advanced functionality with any of your PLCs by simply pulling data over to it. You don't need 1 per machine just for logging, use a single central BRX and grab logging data from a bunch of PLCs

    Expand Post
    • grant (Customer)

      Thanks PouchesInc!

       

      Yeah we have PCs on the network.. But I am really trying to move away from using PCs for any aspects of control anymore.. I am loving the whole PLC and CMore way of doing things I use to do with a PC.. I like the BRX idea.. But I am currently thinking of dumping the whole 2000 pre compiled lookup table/array method! The setpoint profile(s) are pretty simple/basic.. And now that I have seen some example of what can be done with the CMore RECIPE stuff.. I am thinking about simply doing a poly fit of the data and using the RECIPE stuff to load the poly fit coefficients! i.e.

       

      y = a*x^2 + b*x + c

       

      I can use the RECIPE to load the a, b and c and than simply call the function! This also eliminates the need to match the array index to the current time from my timer.. Where at T0 I start a timer, and the plan was at each scan read the timer, use the count to index the array.. Now I just use the timer count as the "x" input (convert the count to the correct units first) and wala I got my profile! A profile that the operators can adjust via the a,b,c from the CMore HMI

       

      Wish me luck! ;)

       

      Grant

      Expand Post