
suresh_
MrPLC Member-
Content count
68 -
Joined
-
Last visited
-
hello Marco, clearly the manual is the reference N.1 however there is some learning curve and may be you need some guidance. As a start you need to know that AI Expansion Units setting has to be done via available OUTPUT channels in your PLC, in the same manner input AI readings shall be done via available INPUT channels. This is the main difference compared with an AI embedded in your PLC. However in your case, I see another Expansion Unit directly attached to the PLC so it will consume its own IO Channels and you have to take it into account when you are programing your AI module. Speaking of Expansion module, please note that they are channel consumer, AI/O or Boolean I/O cahnnel there is not difference, so if you have a module to the left of your AD42 keep in mind that this is consuming channels that you cannot made avaialble for other modules so you should study also this module manual. Finally, when you made your AI avaialble and converted into HEX you need to scale it in engineering units via SCL, SCL2 or APR. Experienced users prefer APR because is BCD free but is just matter or personal preference. Just in case, there is another similar issue in the forum so you may check it out.
-
-
my BCD to BIN CONVERTER View File here sinple logic similar to BIN function. Note:no need of error flag here bcs in case of input error, converted output is set to #0000 (on the contrary BIN function activates error flag bcs is keeping last valid value). Submitter suresh_ Submitted 03/23/22 Category PLC Sample Code
-
Benji000 liked a post in a topic: day counterdown
-
hello Benji, the basic concept is: once you set up your logic, you need to refresh it automatically every 365 days. First you have to set D0 that is control word for DT instruction and get rid of sec, min and hours. After that you have to define your control logic and register it to PLC activating W90.00 ( this can be done during commissioning or by the Client from HMI ) : clearly this has to be done automatically every 365 days. In the example given, today date is frezeed and MOV to D or (better) H register . To specify 365 days requirement you may ADD #100 to D353 (meaning increment 1 Year =365 days ) and compare it with present date in the DT instruction. After 1 year from today date W0.00 will be ON triggering whatever actions you need. After your task is done W90.00 need to be refreshed again so the new date will be freezed for the next cycle. To check your logic you have to start simulation, go to Clock section in the Project workspace, manually increment the date by 1 year ( actually few seconds less) and see, after few seconds, if DT will set ON its output or not. If your logic is different you have to set up BCD data you need and MOV it to register, increment it by 1year and send to DT function as usual: DT function will operate the timer accordingly. I hope it help.
-
Benji000 liked a post in a topic: day counterdown
-
hello Benji,I think you can easily fit this logic to your needs , however you have to decide if your customer should be allowed or not to adjust (or tapering...) Clock settings from HMI. Finally using H register instead of D can preserve your setting in case of persistent power failure.
-
hello Muhammed,the ladder seems fine to me so it is tricky, however may be there is wiring issue or may be the PLC is confused about Expansion AI CH you effectively are using: i.e. if you are using only CIO3 you may try to inform the PLC about this fact like below: MOV #800E 103 MOV #8000 104 You may also recall expansion error word A436 and see if there is an error there I hope it helps
-
Benji000 liked a post in a topic: day counterdown
-
Hello Muahmmad, I have seen your post just now. May be it can be useful for yout to check out my recent reply in this forum about a similar subject.
-
Hello Marco, based on AD041 I am familiar with, you may refer to attached screen shot. After that you may use SCL2 function (noting that numeric example in Omron manual is wrong ) to scaling your AI ND consume it in your program logic. Resolution is 6000 but full scale may change according to your input ( volt / mA) that has to be specified in PLC setting section. I hope it helps.
-
Hello Ben, you may use DT compare function e.g. is listed in the SS that is counting 365 days from today date but you may change it at your convenience. Once scheduled task is done you can refresh and start next cycle.
-
-
[PLC Sample Code] - my EXPONENTIAL INTEGRATOR (1st ORDER SYSTEM WITH LAG)
suresh_ posted a topic in Download Comments
View File my EXPONENTIAL INTEGRATOR (1st ORDER SYSTEM WITH LAG) here integrating function from T=0 to T=2.5 with POWER SERIES and error correction. D250 simulates behaviour of first order system with lag. Submitter suresh_ Submitted 03/16/22 Category PLC Sample Code -
my QUADRATIC SIGNAL INTEGRATOR View File here simple fucntion that calculates TIME integral of a quadratic signal with Coefficient (Real number). Error correction section is provided. Note: Input TIME and COEFFICIENT. Submitter suresh_ Submitted 03/16/22 Category PLC Sample Code
-
-
-
[PLC Sample Code] - my LINEAR SLOPE/TIME INTEGRATING FUNCTION
suresh_ posted a topic in Download Comments
View File my LINEAR SLOPE/TIME INTEGRATING FUNCTION basic integrator provided with error correction section. Inputs are SLOPE * 1000 and TIME *10. No need of PIDAT so it can run on a PC. INTEGRATOR_02.cxp Submitter suresh_ Submitted 03/16/22 Category PLC Sample Code