Writing to PLC - AB SLC505 help me... PLEASE

not124get

Member
Join Date
Jan 2004
Posts
6
Hello,

First, let me start by letting you know that i am not a PLC programmer, nor am i a PLC user, in fact the first time i even heard of their existence was 1 week ago...

However, I am a developer and in desperate need of help. I am running with Allen Bradley SLC-505 and RSLinx lite (but i have the authority to buy a larger package which i think i will have to do given that i have 22 PLCs that i need to see)

I need to write 1 integer and 1 float to a memory location on the PLC, the PLC's IP is static and i can have whatever memory block(s) address I want (so says the PLC technician). I have been reading almost every topic that is in this forum and I believe i can write to the address block using Excel macros.

So before i begin the what seems to be an ugly ugly learning experience...:
1) is there an easier way for me to write those two pieces of information to the PLC?

2) is there any piece of information that you think would be critical for me to read and understand?

Thank you all in advance for any guidance, wisdom, and information you could provide,

Matt
 
What you need is a license for RSLinx OEM or RSLinx Professional. Both of those licensed versions of RSLinx support DDE connections to other Microsoft programs, including Excel.

For each SLC-5/05 you need to access, you will configure a DDE Topic inside RSLinx. That DDE Topic becomes your reference point and method for reads and writes to the controller from Excel, VB, or any other DDE-capable application.

What environment do you "develop" in ? It's entirely possible that another 3rd party ActiveX or similar component is available to accomplish what you need to do. Maybe you're familiar with OPC, and can use that method to communicate between your application and the SLC-5/05 controllers.
 
Thanks for the quick reply,

Currently i have NO development platforms... I am capable of working in VB and VC++, but this company does not currently have licences.

I'm actually working with their intranet, specifically with an Apache, PHP, and an oracle. The two pieces of data i need to pass are a quantity and a length... i'm in a production facility of a larger company that is still trying to go 100% paperless, and i'm trying to eliminate as much user-error as i can (in this case a technician punching in the two values into a panelview).

My current plan is to grab the data from my oracle (offsite somewhere in the states) organize within php, send the (reorganized) data to the Excel spreadsheet, run the macro to send the data to the specific PLC where my technician says his ladder program on each PLC can grab the data from the memory block and be on its way to produce the items.

I am familiar with OPC but still a rookie... if u think it's the best root then i'll force myself to become more familiar than a rookie... I already have the Matricon free stuff... but i want a plan before i start playing the mad scientist...

thanks for your input thus far, it's already been a great help in narrowing my research.
 
I would say go with OPC. You are allready a bit familiar with it. And OPC is possibly the way to go in the future.
If you are on a budget, you should consider RSLinx "Single node". It is approx half price of RSLinx OEM, but will allow only one connection at a time.

For Ethernet to SLC, there is another alternative: ActiveX drivers from either Automated Solutions or Ingear. The advantage is that they are runtime free (no licenses).
 
What you want to do sounds like it could be a good fit for RSSQL (a Rockwell Software product) or if it is more complex there is a more capable product called I/Gear.

Basically what it sounds like what you want to do is filter some data between a database and a PLC. The only issue I have with custom code for that common & what usually becomes critical task is the maintenance of the code after the programmer leaves or moves to another division. Also the quick and dirty solutions are usually harder to trouble shoot when something fails.

For RSSql: http://www.software.rockwell.com/rssql/

For I/Gear: http://www.igearonline.com/

Darren
 
Thanks for the responses.

It just seems like those solutions are a little overkill for what i want to do. i really only need to put one float value into the memory, the other data he can store locally on the PLC and grabbed based on the one value entered.

I understand that OPC is the way of the future (saw the flash demo/tutorial that they put out) and will allow for more applications in the future... The Igear and RSSql are wayyyy more than this company needs for at least the next couple of years, and the active-x solutions would be great... if i could use VB or VC...

The PLC programmer uses RSLogix 500 to make everything if that helps...

and what about the webpages that are on the PLC locally, they grab information from the PLC, so is there a way that i can use those pages to put data into the PLC? Is there not a simple way to write straight to a memory location?
 
not124get said:
Thanks for the responses.

It just seems like those solutions are a little overkill for what i want to do. i really only need to put one float value into the memory, the other data he can store locally on the PLC and grabbed based on the one value entered.

I understand that OPC is the way of the future (saw the flash demo/tutorial that they put out) and will allow for more applications in the future... The Igear and RSSql are wayyyy more than this company needs for at least the next couple of years, and the active-x solutions would be great... if i could use VB or VC...

The PLC programmer uses RSLogix 500 to make everything if that helps...

and what about the webpages that are on the PLC locally, they grab information from the PLC, so is there a way that i can use those pages to put data into the PLC? Is there not a simple way to write straight to a memory location?
 
Hi not124get,

You're trying to do what I've done.

I don't know if you guys have ERP system in place. let me tell you what I did regardless:

The platform I'm using is .NET Framework C# and ASP.NET. I divided the system into sub-systems:

1. OPC Client Application. (Windows Application)
2. FileReader (Windows Service)
3. BaaN Integrator (Windows Service)
4. Web Publisher (Web Application)
5. Reports Generator (Windows Service)
6. Integration Business Service. (Web Service)
7. Integration Data Service. (Web Service)

The OPC Client Application is a simple Windows application that's develeoped in C#. It interacts with the PLC and does whatever the operator wants. A file will be generated whenver a task is accomplished. Also, it reads files sent to the import directory.

The FileReader Windows Service is developed in C# and it reads all files generated by the OPC Client and store their contents into the DB (SQL 2k)

The Integration Data Service is a Web Service that only reads data from the Database.

Teh Integration Business Service is a Web Service that implement the business logic. (e.g create files and send them to the Import Directory of the OPC Client, etc.)

Web Publisher is a Web Application that contains all Reports and authorized users can control the plant. For safty reasons, operator has to start remote jobs.

Reports Generator is a Windows Service that sends daily production e-mail to the president and top managment.

BaaN Integrator is a Web Service that gets data from DB and insert them into our ERP system.

Do you want me to explain further?
 
Thanks for the extensive detail... but it is and it isn't what i'm trying to do. What you did is where i think the project should go, BUT unfortunately that's not where it will be anytime soon.

I just want to send in a product size so the PLC can decide whether or not it should change itself over to be able to produce the size.

The application that comes before writing the product size is a very simple production line chooser written as a web-app (a bunch of combo boxes). i have a list of orders that come from an oracle, the lead-hand/material-handler/etc. decides which of our production lines will make the order... I pass the product size (based on the order) to the specific PLC... that's all i have to accomplish... the only thing that i need to output from the PLC is that the order has been completed.

Thank you for the input though, it's much appreciated
 
Hi not124get,

Ok, in your case you only need to do the following (Simple Solution):

1. Purchase an OPC Server.
2. You need a dll library to add to your Web Application to communicated with the OPC Server. Usually you need to purchase an OPC Client to do that. Type of OPC Client depends on the langauage you're using to develop the Web Application. For example, if you want to develop your application in C#, you gotta go for OPC.ClientX.NET and so on.

From my experience, try to divide your solution into tiers. Each one should work perfectly on its own.

If I'm supposed to develope this system, I'd do the following:

1. Purchase an OPC Server.
2. Develop a Web Service (Business Logic) so that it can be accessed by remote application(s) to read or write to the PLC through the OPC Server (client dll library is registered in here).
3. Develop a Web Service (Data Access). It mainly gives me a chance to read and write to the Databases (.... in Oracle)
4. Develop My Web Application.

If you go for this solution, then see what you can do:

1. You can now develop the Data Access Web Service and the Web Application. That's before you purchase the OPC Client/Server.
2. When you buy the OPC Client/Server develop your Business Logic Web Service. However, it's a good approach to implement some methods in the Business Service to allow the Web Application communicates with the Data Access Web Service. You can however let the Web Application communicates directly with the Data Service but it's not a good approach.
 
Data To SLC

Hello

1. Go buy RSlinx "Single Node".

2. Make a "DDE/OPC Topic Configuration"

3. Use the "Copy DDE Link To Clipboard" utillity in RSlinx

4. "Paste" it into Excel. Here is your Data.

5. Now do some VBA code to work with that data

Have you tried to look in RSlinx "Help", there is a lot af informations on the DDE Topic.

Best Regard

Jesper

beerchug
 
What lauu suggest seems to be the cheapest way to do it.

not124get, you said "My current plan is to grab the data from my oracle (offsite somewhere in the states)".
Matrikon has an OPC Client for Oracle. I would check if it could access your Oracle directly. Then you would have no programming whatsoever, and you could cut out a few steps of your previously planned setup (Apache, PHP, Excel, VBA).

Anyhow, it is certainly possible to use VB or VC, there must be lots of programming examples for you to start with.
 
Hi Jesper,

if he's planning to read/write from/to Oracle Database, then there ain't no need to buy any software to accompish this task. He can do that through his application (VB, C++,etc.).
 
Hi naserals,

I understand that, but I just wanted to tell him about the possible options.
He has to consider the cost for a shrinkwrapped product over the time he has to spend to make a roll-your-own.

If he is going to spend more than one week for doing it himself, then I dont recommend it. For a reasonable sum he gets a finished debugged product with support.
And if everything goes wrong he has somebody else to blame ;)
 
That's true Jesper.

What I understood from his posts that he wants to do some readings and writings. He also wants to automate the whole procedure. The reason for that is that he wants to control the plant through his Web Application. Also, he wants to display results to the user. Therefore, he has to find a component to allow him read and write to the PLC. Also, he has to develop a Web Application to communicate with this component.
 

Similar Topics

I'm currently a senior in college working on a senior design project involving PLCs and Raspberry Pi. We have data taken using the PLC that we...
Replies
14
Views
4,068
Hello, I am looking for help writing to PLC tags from Excel. I am using Factory Talk Gateway as an OPC server and Excel VBA to write out to an...
Replies
5
Views
3,101
Hello, i am currently trying to create a plc programme from my Tia portal v16 for a package filling machine. But i am kinda new to the plc stuff...
Replies
48
Views
17,308
i am new to these things. I have no intention of using this in a commercial way whatsoever. I wanted to write a small plc programme for myself. We...
Replies
18
Views
7,864
HI all, I have a CP1L PLC programmed with Omron CX-one and I need to adjust the internal real time clock externally, i.e get my PLC code to set...
Replies
1
Views
1,667
Back
Top Bottom