Questions tagged [plc]

PLC (Programmable logic controller) or programmable controller is a digital computer used for automation of electromechanical processes, such as control of machinery on factory assembly lines, amusement rides, or light fixtures.

1091 questions
7
votes
3 answers

Why Elsif not Else If In PLC programming

Im a PLC programmer and I am wondering why the reserved word elsif (ie without the E ) is used. I know that elseif or any other combination is not used as reserved words. Is there a history to use this in other Languages. If so why? just to save…
mrebus
  • 111
  • 1
  • 8
7
votes
2 answers

C set a bit (bit manipulation)

I'm programming a industrial plc and I have to manipulate bits for a profi-bus communication with a VFD. I get a 2byte status and have to send 2byte commands. For this operations I have to set bits to get the VFD operating. For example: …
Gerald Zehetner
  • 596
  • 4
  • 21
7
votes
12 answers

PLC Programing in C# .NET

Can I Write Programs for PLC Controlling in C#? How?
Hossein Moradinia
  • 6,116
  • 14
  • 59
  • 85
6
votes
3 answers

Any successful profibus communications from .NET?

Has anyone successfully talked profibus from a .NET application? If you did, what device/card did you use to accomplish this, what was the application, and did you use any kind of preexisting or available code?
GEOCHET
  • 21,119
  • 15
  • 74
  • 98
6
votes
1 answer

Reading a JSON structure from a web server page on a Siemens S7 1500 PLC

I've been working with HTML and javascript to create graphical web pages to display data from my Siemens S7 1500 PLC. I've been using a $.getJSON command to successfully read values from the PLC when the web page that requests the information is…
Ryan Y
  • 81
  • 1
  • 5
6
votes
1 answer

Sending a boolean value to a PLC from Android

I was able to make a connection with a PLC to read data from it. Now there's one problem and it is that I have to write a method to modify the data from the PLC. To achieve this, I have to send two values to the PLC: an int value and a boolean…
Marialvy Martínez
  • 286
  • 2
  • 6
  • 19
5
votes
5 answers

Where is a good place to start with making an application in .NET that communicates through OPC?

Where is a good place to start with making an application in .NET that communicates through OPC?
GEOCHET
  • 21,119
  • 15
  • 74
  • 98
5
votes
1 answer

Read/Write S7-1200 bit memory via C#

I am trying to set value on a boolean memory in the S7-1200 CPU, I have used the SNAP7 library but I couldn't get success with it : Result result = new Result(); byte[] Buffer = new byte[26]; Client.DBRead(1, 0, 2, Buffer); result.bArret =…
Erwin Draconis
  • 764
  • 8
  • 20
5
votes
1 answer

How to declare local variable (Allen Bradley studio 5000)

How to declare local variable in structured Text in Allen Bradley studio 5000. I have tried the following which did not work. mnemonic/syntax is not recognized? VAR x: INT; END_VAR global variables do work as, TEST_INPUT and TEST_INPUT_BOOL …
user6235593
  • 95
  • 1
  • 7
5
votes
2 answers

HTTPS Client for Siemens S7

I've a RESTful HTTP API. Now I would like to send HTTPS requests from my S7 PLC to the API. I've contacted Siemens and they said that they don't have a HTTPS client implementation. But there is a tcpClient module in the library. And since TCP is the…
Tobias
  • 4,523
  • 2
  • 20
  • 40
5
votes
4 answers

A Question About PLC Instructions

Can an input X1 change while instruction sequence is still being processed? e.g. LD X1 AND X2 OUT Y1 LD X1 // Can X1 loaded here differ from the previous one? AND X3 OUT Y1 Thanks
Betamoo
  • 14,964
  • 25
  • 75
  • 109
5
votes
2 answers

Pymodbus Read/Write Floats (REAL)

I have modbus mapping setup in my AB Micro820 PLC. I have an array in 40001 for writing, and one in 42001 for reading. Both are 200 elements and REAL type (32-bit float). I can write and read currently, so I know the code works, just incorrectly.…
xinthose
  • 3,213
  • 3
  • 40
  • 59
5
votes
6 answers

Timers in PLC - Structured Text

How do timers work in PLC Structured Text (ST)? How do we declare them? I've been studying a standard of PLC (IEC 61131-3), and they do not speak about timers in ST. I know the great majority of PLC programmers do them in ladder logic, but in this…
Yoanribeiro
  • 135
  • 1
  • 1
  • 10
5
votes
5 answers

PLC Structured text, convert decimal to real(float). Not getting the value I expect. (IEEE-754)

I have a hardware that is communicating with the PLC over Profibus DP, that sends me 4 bytes of data in hex that is "44 79 FF FF" and in the PLC program I have declared a BYTE array for this input data. The problem is in the PLC the data I receive…
hijack
  • 263
  • 2
  • 3
  • 11
5
votes
6 answers

Best IDE for PLC ladder programming

Recently I trying to learn Ladder Logic programming for PLCs, but I want to know if there is any IDE to create Ladder programs better that Step7 or cx-programmer? Is there any plugin for Visual Studio or Netbeans that I can use? Finally, is it…
Ali Foroughi
  • 4,540
  • 7
  • 42
  • 66
1
2
3
72 73