cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Writing data from KEPServerEX to the PLC

DP_11006808
4-Participant

Writing data from KEPServerEX to the PLC

Hello,

     I am sorry for this simple question. I want to know is there any configuration to be made on KEPServerEX or Allen Bradley PLC side to write tag values from KEPServer to the Allen Bradley PLC.

   In my project data is being stored in database from a KEPServer using a Data logger. Some data from the PLC will be read and stored in the Database and some data we need to write from DB to the PLC. I want to the configurations required to write data to the PLC from DB.

 

Thanks, in advance.

ACCEPTED SOLUTION

Accepted Solutions
rajskumar
14-Alexandrite
(To:DP_11006808)

Hello,

 

Once you retrieve data from the database (DB) to Kepware (please note that direct writing from the DB to the PLC is not possible) using the ODBC Client driver, you’ll need a link tag to write values from Kepware to the PLC. In the link tag, the input will be the tag from the DB, and the output will correspond to your actual Allen Bradley PLC tag.

 

Unfortunately, I don’t have any Python code specifically for this task. However, I strongly recommend reaching out to our pre-sales(presales.support@kepware.com) team for a detailed solution. Alternatively, if you have a valid license, you can open a support ticket if you encounter any issues during implementation.

View solution in original post

3 REPLIES 3
rajskumar
14-Alexandrite
(To:DP_11006808)

Hello

Database cannot be a client application directly to Kepware but we still can get data from Database (any ODBC compatible DB) using our ODBC Client driver. Then you can connect to table using ODBC Client driver, and read/write the values of the each cell. In this way we can receive data coming from database.


After setting up the database communication with ODBC Client driver, then you can use Link Tags inside Advanced Tags Plugin to send the value to other devices including Allen Bradley PLC.

ODBC Client driver- https://www.ptc.com/store/-/media/kepware-store/en/manuals/odbc-client-manual.pdf

Advanced tag - https://www.ptc.com/store/-/media/kepware-store/en/manuals/advanced-tags-manual.pdf

We have a dedicated team(Pre Sales) that handles all POC related queries and concerns. You can reach out to them at presales.support@kepware.com 

Thanks,

DP_11006808
4-Participant
(To:rajskumar)

Hi

Thank you for the prompt reply.

I am sorry I am not getting how 'Link tag' will help to write data from DB to PLC tags'. I am aware about setting up an ODBC source as I am logging data to an SQLite database by defining one.

What do I need to set as an Input (under Configuration option) in a 'Link tag' to read the data from the database?

I am thinking of writing values in tag with the help of Python code. Can you please send a sample python code for read/write data to KEPServer.

 

Thanks 

 

rajskumar
14-Alexandrite
(To:DP_11006808)

Hello,

 

Once you retrieve data from the database (DB) to Kepware (please note that direct writing from the DB to the PLC is not possible) using the ODBC Client driver, you’ll need a link tag to write values from Kepware to the PLC. In the link tag, the input will be the tag from the DB, and the output will correspond to your actual Allen Bradley PLC tag.

 

Unfortunately, I don’t have any Python code specifically for this task. However, I strongly recommend reaching out to our pre-sales(presales.support@kepware.com) team for a detailed solution. Alternatively, if you have a valid license, you can open a support ticket if you encounter any issues during implementation.

Announcements


Top Tags