Sign in to follow this  
Followers 0
jagg

io scanning

13 posts in this topic

hello looking for some info on setting up io scan between 2 plc's first plc -proworxnxt noe card installed second plc-unity pro 4.0 noe card installed need some info on setting up the i/o in the unity plc ie; what are the input and output numbers 40000 register do i look at using %I and %Q not clear on this. proworx plc i more or less have the proworx plc setup, with the i/o i will be using for the info being READ from the unity processor. now i also have the i/o setup in the proworx plc that i want the UNITY PROCESSOR TO READ. unity plc so now i need to setup the unity processor i/o for the PROWORX TO READ. and also the i/o to use for the READS FROM the proworx plc if anyone has some info or help please reply appreciate it iam still fairly new with the unity software have worked on this particular system of ours once before and did ok but now have this to setup.

Share this post


Link to post
Share on other sites
with I/O scanning utility you are able to read and write only holding registers (4x). So in the old application just copy the table of register 4x, written by the Unity PLC, where you need, and all the data, needed to be read by the Unity PLC, into another table of registers 4x. In Unity configure a new ethernet communication (i.e. Ethernet_1), enable I/O Scanning. Open the I/O Scanning window, set IP address of old PLC, configure the read and write tables. It is better to configure read and write tables separately (one line read table, another line write table). That's because of the modbus code 23 could be not accepted. The RD/WR master object are the holding register of the Unity PLC, the RD/WR slave object are in the old PLC.

Share this post


Link to post
Share on other sites
thanks for reply ok iam looking into this next day or so guess the question whichh i need clarification is to do with the unity plc setup. now thinking i need to find what %MW registers are avaiable for use also the %I/%Q -discreet input/outputs now i assume i can look at the used memory page or table in unity? now when i ioscan the 40xx reg from proworx which will be a table of outputs stored in the 4xxx to transfer over. i would need to transfer the holding reg. table to each its respective %i/%Q-I/O these each need to be setup in the data table first as a variable? this is the part i been thinking about iam sure iam making more of this then i should but this is what i could use help in. thanks for any help by the way the help file in unity not helping me have d/l the manual also

Share this post


Link to post
Share on other sites
Example: You have a PLC 984 or old Quantum communicating with a Quantum Unity via ethernet In 984 you have to exchange sixteen input 10001-10016 and sixteen output 00001-00016 First copy inputs in a holding register i.e. 40001 Second copy an holding register i.e. 40002 to the outputs (of course only if you need to write them from PLC Unity) In Quantum Unity or M340 (you just talk of NOE but there's no matter) configure the I/O Scanning i.e. first line for reading objects (IP) 1.0.0.1 (ID)255 (Time-out)1500 (Rep.)64 (RD Master)%MW1 (RD Slave)0 (RD Length)1 (WR Master)%MW1 (WR Slave)0 (WR Length)0 and a second line for writing (IP) 1.0.0.1 (ID)255 (Time-out)1500 (Rep.)64 (RD Master)%MW1 (RD Slave)0 (RD Length)0 (WR Master)%MW2 (WR Slave)1 (WR Length)1 Further in PLC Unity you could copy %MW1 to 16 outputs %Q and copy 16 inputs %I to %MW2 Now if 10015 was =1 also %Q1.6.2 would be =1 (I suppose to have an output card on slot 6) Again if %I1.4.1 was =1 also 00016 would be =1 (I suppose to have an input card on slot 4) You might begin from this example and develop it

Share this post


Link to post
Share on other sites
thanks aggattapauer for reply i started on the project today was able to use array to setup required bits and then moved this array to int. this enabled me to read the register %MWxx to my 4xxxxx register in proworx. seems to be working fine then did the revers for of this for my read from proworx 4xxxx register to a %MWxx register in unity, then moved the int to a array this also seems to be working ok. so ill continue on see if things work as wel as did this

Share this post


Link to post
Share on other sites
hello have the ioscan working fine but i would like to give each bit in the array i make individual variable names. right now they follow the variable name given to the array variable i make. ie: array= ioscan_read now the 16 bits in the array are ioscan_read[1] ioscan_read[2] and so on .....to 16 maybe i need to use something diff. not sure. iam doing some reading up on this right now but have not found what i want any help appreciated thanks

Share this post


Link to post
Share on other sites
if you declare a variable as an array of bool you could modify only the comment of each bool: ioscan_read[1] | 'run' ioscan_read[2] | 'stop' .... ... One question: if you want each element of the array different, why do you use the array?? The array is useful because with one name it is possible to manage a big amount of same variables... You could create all your variables one by one... In this case you should see and study about DDT structure of variable (derivate data type). Anyway let me know what are you doing so I might understand more...

Share this post


Link to post
Share on other sites
ok the plan is to simply transfer 32 bits of info 16 bits to one sys. unity the other 16 to a sys. proworx this will eliminate the hardwire required for these these bits are transfering info such as you stated run start stopped extending retracting home position fully extended few display alarms permissives that are required to enable operation these will be continuously transfered thru ioscanner and the rest is me learning and asking questions thanks

Share this post


Link to post
Share on other sites
You can create a variable structure (DDT) so yiu can use it without loosing time. I.e. create the ddt named 'motor' with the following structure run = BOOL start = BOOL stopped = BOOL extending = BOOL retracting = BOOL home = BOOL extended = BOOL alarms = BOOL permissives = BOOL Now you can create all variables you need structured as motor I.e. create a new variable named robot1 - type = motor you will have created as many bool as motor structure so: robot1.run robot1.start .... ... You understand that if you had 10 robots you need only to create 1 structure and 10 variables rather than 9x10 = 90 variables Back to I/O Scanning. You could program your own DFB for copying I/O Scanning words to your robot variables. So you could save all your DFB and use it for other application. I.e. input = words from I/O Scanning output = robot1 (or 2 or 3 etc.) in the DFB you have to program the copying. There are many many way to reach the same scope!! What I have tried to describe are only some simple way... Good job!

Share this post


Link to post
Share on other sites
ok have made ddt and am able to give specific names to each as i wanted nice now have been trying to work with a specific address given too the ddt name ie robot but when i try it uses the adress ie %mw180 for 2 of the bool variables inside my structured ddt so this is what i have tried under the ddt tab created a ddt named "robot" with type "structure" looks good now still in ddt tab i click the + to start adding my specifc names under robot i want, looks good ie start run stop extend etc.... now i goto the variables tab now and create a variable called robot_ddt this comes up with all my variable names i gave earlier good again so now i would like to manipulate these to work with a single address ie "%MW185" so all my bits inside the variable name "robot_ddt" can be sent over ioscan as a single "int" address but when i attempt to give a address to the robot variable it uses addresses %mw185 for first 2 variables inside my robot variable %mw186 for the next 2 %mw187 for the following 2 etc...... so iam somewhat stalled here thanks for any help

Share this post


Link to post
Share on other sites
I was sure that you would have find this kind of problem!! In order to copy an array of bool into a word you have to program your own DFB because there are two kind of problem: 1 the DDT type doesn't accept EBOOL topology 2 you can't assign an address %M to any BOOL topology So in the variable screen you could assign the address %M (and not %MW) to your DDT variable but %M is an EBOOL and DDT only BOOL so nothing to do!!! Create your simple DFB and save it in the user's library: i.e. Configure a new DFB with input parameter same as your DDT structure and output parameter INT topology. NewDFB +input inputbool 1 type Motor +output outputINT 1 type INT Open the DFB section and program something like: outputINT.0:=inputbool.run; outputINT.1:=inputbool.start; outputINT.2:=inputbool.stop; .... ... Create a new instance of NewDFB (default FB something..) named ie. CVT_B_to_I (convert Bool to INT). In the MAST or SR, up to you, call the DFB CVT_B_to_I (inputbool := motor, outputINT => %mw100); You made your own convertion that you could use in the future in all application.....

Share this post


Link to post
Share on other sites
ok aggattapauer you are big help with this but iam somewhat at a stall setting up a robot_dfb and setting up the parameters, again thanks for your help

Share this post


Link to post
Share on other sites
ok think i have it am going to test it out see if iam on the right track

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0