You are not registered yet. Please click here to register!


 
 
plc storereviewsdownloads
This board is for PLC Related Q&A ONLY. Please DON'T use it for advertising, etc.
 
Try our online PLC Simulator- FREE.  Click here now to try it.

New Here? Please read this important info!!!


Go Back   PLCS.net - Interactive Q & A > PLCS.net - Interactive Q & A > LIVE PLC Questions And Answers

Reply
 
Thread Tools Display Modes
Old April 5th, 2021, 08:12 AM   #61
drbitboy
Lifetime Supporting Member
United States

drbitboy is online now
 
drbitboy's Avatar
 
Join Date: Dec 2019
Location: Rochester, NY
Posts: 2,602
Quote:
Originally Posted by I_Automation View Post
...( I know I have to have at least a dozen in my house but still have to search when I need one)

I keep one in my fanny pack . One time I even used it to break into my car when I had locked myself out.
  Reply With Quote
Old April 5th, 2021, 08:23 AM   #62
geniusintraining
Lifetime Supporting Member + Moderator
United States

geniusintraining is online now
 
geniusintraining's Avatar
 
Join Date: Jun 2005
Location: SC
Posts: 7,437
Quote:
Originally Posted by drbitboy View Post
fanny pack
WOW, really, you had to go there.... not sure why these had to go away, I loved my fanny pack, I thought about a murse but

The great thing about a fanny pack my compact 9 was really easy to get out and it could hold a couple clips
__________________
www.PLCCable.com PLC Communication Cables, PLC Trainers, MicroLogix, ControlLogix, Siemens, Allen Bradley and more...OEM and aftermarket supplies... Aftermarket 1784-U2DHP Allen Bradley USB to DH+, new USB to 485 modbus
  Reply With Quote
Old April 5th, 2021, 10:42 AM   #63
greenlantern
Member
United States

greenlantern is offline
 
Join Date: Apr 2021
Location: tx
Posts: 4
Not yet waiting on them to reply.

Not yet waiting on them to reply.
  Reply With Quote
Old April 5th, 2021, 01:30 PM   #64
travispedley
Member
United States

travispedley is offline
 
Join Date: May 2012
Location: Sanford, NC
Posts: 136
Fellas, this was a wild ride. Write what you know, outside of some rare instructions, you can accomplish your task with any of the languages, so pick the one you can write the cleanest. I had the pleasure of looking at one of the first robot programs I wrote years ago, and I was amazed at how much I've learned since then. That kid had promise, but he didn't code for ****.
  Reply With Quote
Old April 5th, 2021, 08:31 PM   #65
Geoff White
Member
Australia

Geoff White is offline
 
Join Date: Oct 2005
Location: Brisbane
Posts: 441
I came into work one time, sick as a dog and heavily medicated. Worked on a machine for half a day and then was somehow at home with no recollection of having travelled.

The next day I had a look at the code in the machine. I had no idea how it worked but it was working well. So I backed away and never touched it again.
  Reply With Quote
Old April 5th, 2021, 09:00 PM   #66
drbitboy
Lifetime Supporting Member
United States

drbitboy is online now
 
drbitboy's Avatar
 
Join Date: Dec 2019
Location: Rochester, NY
Posts: 2,602
Quote:
Originally Posted by Geoff White View Post
I came into work one time, sick as a dog and heavily medicated. Worked on a machine for half a day and then was somehow at home with no recollection of having travelled.

The next day I had a look at the code in the machine. I had no idea how it worked but it was working well. So I backed away and never touched it again.



  Reply With Quote
Old April 5th, 2021, 10:17 PM   #67
kalabdel
Member
Canada

kalabdel is offline
 
Join Date: Feb 2015
Location: Ontario
Posts: 720
Quote:
Originally Posted by jhenson29 View Post
For the record, it’s not supposed to support recursive functions. But if you use an FB with a method, the method can call itself if you pass it’s own FB pointer to it. TwinCAT can’t stop what it doesn’t know about...

And it also supports recursive data definitions using pointers (no special trickery there) which is nice for tree structures (especially with runtime memory).
This post is just loaded with question marks.


Let me phrase it this way, how serious is the role of industry standards like IEC 61131-3 and PLCOpen and how strictly should we adhere to them?



They are pretty much designed to protect us (and those who maybe harmed by us) from ourselves. Which brings up another question, do advanced programming features lead to bad code?
  Reply With Quote
Old April 5th, 2021, 11:01 PM   #68
Peter Nachtwey
Member
United States

Peter Nachtwey is offline
 
Peter Nachtwey's Avatar
 
Join Date: Apr 2002
Location: United Welfare States of America
Posts: 7,407
Quote:
Originally Posted by travispedley View Post
Write what you know, outside of some rare instructions, you can accomplish your task with any of the languages, so pick the one you can write the cleanest.
This is closer to being correct now but back when most PLCs or micro controllers didn't have floating point there were somethings that were extremely difficult to do.
For instance multiplying by PI or my close approximation 355/113.
The problem was that 355 times a number could exceed what would fit in a 16 number. Most CPUs could multiply a 16 x 16 bit number and get a 32 bit result. One had to use assembly language to divide a 32 bit by 16 bit number to get a result. The remainder then had to be converted to a fraction of 65536.
__________________
"Living is easy with eyes closed, misunderstanding all you see...." Strawberry Fields Forever, John Lennon
  Reply With Quote
Old April 5th, 2021, 11:11 PM   #69
drbitboy
Lifetime Supporting Member
United States

drbitboy is online now
 
drbitboy's Avatar
 
Join Date: Dec 2019
Location: Rochester, NY
Posts: 2,602
Quote:
Originally Posted by kalabdel View Post
Let me phrase it this way, how serious is the role of industry standards like IEC 61131-3 and PLCOpen and how strictly should we adhere to them?



Let me phrase it this way: does adherence to IEC 61131-3 protect us, and those who may be harmed by us, or does it only protect the former from lawsuits because it is considered to imply due diligence?
  Reply With Quote
Old April 6th, 2021, 01:35 AM   #70
kalabdel
Member
Canada

kalabdel is offline
 
Join Date: Feb 2015
Location: Ontario
Posts: 720
Quote:
Originally Posted by drbitboy View Post
Let me phrase it this way: does adherence to IEC 61131-3 protect us, and those who may be harmed by us, or does it only protect the former from lawsuits because it is considered to imply due diligence?
Let's take out harm to others out if the question to avoid this being a legal arguments.


The purpose of the standards is to improve code quality; troubleshooting, reusability and reliability(error free). Mostly they're guidelines and it's up to us to follow and few are either restricted or generate a warning by the compiler.
Should there be more restriction to insure higher code quality or should they leave it up to us to innovate? Give us more features and we can be responsible users.
  Reply With Quote
Old April 6th, 2021, 07:37 AM   #71
drbitboy
Lifetime Supporting Member
United States

drbitboy is online now
 
drbitboy's Avatar
 
Join Date: Dec 2019
Location: Rochester, NY
Posts: 2,602
Quote:
Originally Posted by kalabdel View Post
The purpose of the standards is to improve code quality; troubleshooting, reusability and reliability(error free). Mostly they're guidelines and it's up to us to follow
Personally I think that first sentence is a canard, because the second is universally true. There is no such thing as a structured programming language; there are only structured programmers.

P.S. I am not referring to ST specifically here, but to all "structured" languages. One can write good and ugly program in ST, in LAD, in Java, whatever. The language itself is a tool and irrelevant; there is only the convenience, familiarity, knowledge and discipline of the coder.

[sorry, I keep expanding this post]

TL;DR - Random thoughts, possibly OT.
  • There is at least one amusing thread on this forum about various "temporary" hacks that were never replaced by a permanent solution, even after decades.
  • One of the forum members has a signature something like "There is never enough money to do it right, but there is always enough to do it twice."
  • Standards only work if people follow them, and if something deemed "necessary" cannot be accomplished within the standards, what do we expect is going to happen?
  • Does IEC 61131-3 define byte order in a REAL?
  • LAD is part of the IEC 61131-3 standard

Last edited by drbitboy; April 6th, 2021 at 08:04 AM.
  Reply With Quote
Old April 6th, 2021, 09:01 AM   #72
JesperMP
Lifetime Supporting Member + Moderator
Denmark

JesperMP is offline
 
JesperMP's Avatar
 
Join Date: Feb 2003
Location: Copenhagen.
Posts: 14,708
Not too late to join this ...
Quote:
Originally Posted by swedeleaner View Post
I were schooled in LAD and switched..
But please, tell me when LAD is the best alternative.
LAD is 100% graphical.
FBD is only 50% graphical.
How do I argue that ? ..
By the fact that you have to combine the "≥" and the "&" with the boxes inside your head to interpret the logical result. Remove the "≥" and the "&" and you dont know what these boxes do.
Ladder is so easy to follow, in particular when being online and observing logic that changes rapidly.

I started with FBD (way back with Siemens S5), was forced to work with LAD (because of changing to AB PLC5), and had to admit that LAD is just better.
__________________
Jesper
See my profile interests for Q&A
  Reply With Quote
Old April 6th, 2021, 11:41 AM   #73
jhenson29
Member
United States

jhenson29 is offline
 
Join Date: Mar 2021
Location: St. Louis, MO
Posts: 59
Quote:
Originally Posted by JesperMP View Post
Not too late to join this ...
LAD is 100% graphical.
FBD is only 50% graphical.
How do I argue that ? ..
By the fact that you have to combine the "≥" and the "&" with the boxes inside your head to interpret the logical result. Remove the "≥" and the "&" and you dont know what these boxes do.
Ladder is so easy to follow, in particular when being online and observing logic that changes rapidly.

I started with FBD (way back with Siemens S5), was forced to work with LAD (because of changing to AB PLC5), and had to admit that LAD is just better.
FBD is graphical. You have to read LEQ and ADD in LAD just the same. You still have to read variable names in either. Theyre both graphical. No sense in assigning values to it.
  Reply With Quote
Old April 6th, 2021, 12:00 PM   #74
swedeleaner
Member
Sweden

swedeleaner is offline
 
Join Date: Dec 2013
Location: Gteborg
Posts: 104
Quote:
Originally Posted by JesperMP View Post
Not too late to join this ...
LAD is 100% graphical.
FBD is only 50% graphical.
How do I argue that ? ..
By the fact that you have to combine the "≥" and the "&" with the boxes inside your head to interpret the logical result. Remove the "≥" and the "&" and you dont know what these boxes do.
Ladder is so easy to follow, in particular when being online and observing logic that changes rapidly.

I started with FBD (way back with Siemens S5), was forced to work with LAD (because of changing to AB PLC5), and had to admit that LAD is just better.
Agree to disagree then Jesper..

Ladder tends to get messy Quick, with that said Ive also seen really messy FBD-editors (ABB Control Builder).
Will probably get punished for this, but if you have a hard time to grasp AND,OR,NOT and the states TRUE and FALSE and needing virtual contacts & coils instead you should probably stick to your screwdrivers & multimeters.
  Reply With Quote
Old April 6th, 2021, 01:35 PM   #75
TurpoUrpo
Lifetime Supporting Member
Finland

TurpoUrpo is offline
 
Join Date: May 2008
Location: Switzerland
Posts: 1,508
Quote:
Originally Posted by JesperMP View Post
Not too late to join this ...
LAD is 100% graphical.
FBD is only 50% graphical.
How do I argue that ? ..
By the fact that you have to combine the "≥" and the "&" with the boxes inside your head to interpret the logical result. Remove the "≥" and the "&" and you dont know what these boxes do.
Ladder is so easy to follow, in particular when being online and observing logic that changes rapidly.

I started with FBD (way back with Siemens S5), was forced to work with LAD (because of changing to AB PLC5), and had to admit that LAD is just better.
Yes, Ladder is much better than FBD, if you can't make a good LAD network, you are trying to fit too much in one network anyway.

FBD is horrible, even more horrible than STL.


ST naturally trumps those all for almost everything when written with proper naming.
  Reply With Quote
Reply
Jump to Live PLC Question and Answer Forum

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Topics
Thread Thread Starter Forum Replies Last Post
PLC basic question Karoly LIVE PLC Questions And Answers 2 June 2nd, 2012 11:16 PM
MPI comunication Manuel Raposo LIVE PLC Questions And Answers 22 July 16th, 2007 07:24 AM
[S5-155U CPU948]About PLC Communication Question. apple LIVE PLC Questions And Answers 2 July 20th, 2006 06:07 AM
plc5 with AB 1771-DB basic module, its urgent plz help me nileshsurya LIVE PLC Questions And Answers 6 July 20th, 2005 02:45 AM
Question re:PLC to PLC interaction. c0met LIVE PLC Questions And Answers 5 March 22nd, 2004 12:16 PM


All times are GMT -4. The time now is 01:29 PM.


.