Jump to content

ORSO2001

Privileged Member
  • Posts

    305
  • Joined

  • Last visited

  • Days Won

    11

Everything posted by ORSO2001

  1. Dear All, I am starting for the first time to work with DB in a server PC using SQL (SQL server) query. I am using the SQL example...all works fine...I do the connection...I create the table...I am able to insert, update, get and cancel the "info" with this DB...what I saw and I don't understood is that if I send a query to have some information refered at a specific ID (...WHERE employeID =?) and this ID is not present in the DB the query result, BIT about query success, is turned as "1" ...I was expecting that the "fail BIT" arise !? Maybe this is correct, sorry I don't know deeply this matter...can someone confirm? thanks
  2. Hi Shaun, if you are "online" with your PLC you can only modify the value of the tags (set/reset bit, insert a number or change a string)...not the ladder flow/logic. to modify the ladder flow/logic you must be "offline" and after you have to download the program...if you modify only logic and not HMI you can select the "download logic only"...after the compilation of the program the system, berfore the phisically download, will ask about a reset or not of the actual value of the tags(retained or not is the same)...I never do this with a system in working mode, I have always set the system in "off", so I don't know what really happen with the phisical output.
  3. Hi Marco, I am not sure about what you need...but you can use a second variable to store the value, afer that you done all that you need, or previously, then you will have an ActualValue and an OldValue
  4. Agree... couldn't agree more... obviously...me too
  5. dears...sorry if I am wasting your time...but I have an update...seems that they (second supplier) have found what they were doing wrong...I don't know what exactly they have do but from yesteday the system is working without problems...and I am happy! thanks
  6. hi dierkens, thanks again for your answer...now I have 5 minute of "relax" to try to explain better what I have. to be clear ...when the phisical installation was started my PLC was ready, program done, test field simulation etc, to be connected with the master...obviously I wrote a data exchange document with all explanation...also a step by step example... was who had to program the master side that was not ready...and develloped the program at customer site! at the time I have connect the PLC with the PC where I created an easy program in C# to test...to show at the end customer that all work fine...and it was. after a few the second supplier told me that they were having problem because they never used Modbus protocol (but was the agreement from the beginning!?)...I explained again what they had to do...after a few they told me "now is ok"....great I thoug...but now they come back telling me that sometimes the command is not catch...in my PLC I have a "debug page" where I can see the amount of the "success" and "failed" about the TCP side...the fail are always "0" and the "success" increased every time. in their PLC they don't manage the exception or the data send error or don't check "my" registers about alarms or wrongs commands....I know because the customer user don't found these when the system seems not working...and they (second supplier) are not telling me how they are creating the data string that are sending... yes I can use something like a "sniffer" but I was thinking if the buffer of the data entry was available!?
  7. hi dierkens thanks for answer....maybe my explanation was not clear...my PLC works as a slave...i create some registers (read, write) for a master (that is not mine)...who has created the master program is saying me that the comunications is not working...but if i use a program test to check my registers all works fine...i need to know what they are passing me.
  8. Hi All, I'm using the UniStream as a slave connected by Modbus TCP. Is there a way to know/check the forwarded data, by the Master, byte to byte? thanks
  9. Hi JotaPey, have you tried the Find Substring function block?....field A the string where you want navigate; field B the substring to search; field C the starting point to search in the main string; field D the result....for this last a positive result means that the substring was found....negative result means that the primary string doesn't contain the secondary string...you can navigate in your DTI until find what you want.
  10. ok..what I were doing was a control of the "expected bytes in input" in the same row using to function block "equal" and "not equal" then a ramification of the row...if equal i checked the buffer[5] if not equal I did a store as 8 (because 8 byte is alwayse the lenght of the function 0x03)....I splited these in two individual rows...and now works.
  11. Hi Ausman, no delay ...what I done is check the amount of incomming bytes and every 8 bytes, that are in the RS485, using an EQUAL block, pass at an buffer array using the COM RX function...store this last buffer array in a struct that has the same buffer and store in a DTI...increase the row where I store and restart; this works (the communication between master and slave start and stop on my command)...I repeat that if I check, passed, store this every 8 byte all works fine...but I want to split row by row the request and the answer...what is not working is the "store" of a part of buffer in a tag...I have had an idea about the next test that I can do...later I will try and I will update the topic.
  12. hi camillende, yes...that I know is the only way.
  13. Dear All, I am having a strange issue...I try to explain, I am checking the serial communication between a master and a slave (modbus rtu...like a sniffer) and I am using the Unistream to catch the exchanged data...at the beginning, as first test, I record every 10 bytes and save the buffer in a DTI...and all has works fine...now I want to take the exact request/answer between master and slave....then the first record is checking the 8 bytes...the data will be, for example, 1-3-0-216-0-3-134-56 (the CRC is not calculated...I wrote only as example)...then I want check the position 5 in the buffer (3) to know how many bytes will be the answer...in this case will be (3 *2)+2 =11 bytes...I am using the function block buffer to tag to store the buffer[5] and do the calculation...I tried to save the specific buffer position to a single tag and all the buffer in an array...both UINT8 and UINT16 but...but this never works....in the position C of the function block is wrote that if the end tag has not enough space the function will not execute...but I don't think that is the problem...what cna be the cause? What I am wrong?
  14. Hi camillende, that I know is not possible; let me say that also if could be possible I still prefere check the program with a real PLC and I/O modules...in this way you will have not surprise during the real installation. Let me add that the unistream software is free...other brands don't share free software and you have to pay for this...the cost of a unitronics PLC+HMI+I/O modules is less than the cost of other software... this is what I done when I started to learn how a PLC works (checked what the markert offer as PLCs and for each PLC what was available) ... I found Unitronics that has free software, great forum, excellent service support (I tried this after)...and to be honest I still be sadisfied...I still have on my desk the first PLC that I bought (is become one of the family)...and every job that I done, when installed at customer site, had has no surprise for me. Said this...can I have an extra discount !? 😀
  15. I know what you mean...however...good to hear that you fix this.
  16. hi, times ago I have had problem with the DTI store but was the SD card faulty...replaced the SD all start to works...I don't remember which error I had. However...put some immage about the status of your command after that this is start...to check the value of the variables...
  17. hi Moran, with error -31 seams that you are trying to save "0" (zero) rows in the file...or maybe more than how many are in theDTI...you have to check the value of the "D" variable in the "Store DTI ti File" function. usually at teh first start up of my programs, when I check if a file is already present, to load the file in the DTI, and the file is not created yet, I have alarm -4...then Icreate the files where I will store DTI....then seams that you are trying to read a file that don't exist...or maybe you have insert a wrong "number" of rows to trasfer...check teh "B", "D", "E" variable in the function.
  18. Dear JotaPey, one of the attributes is called "actions", first in the attributes list, if you select this a small window will appear...in this window you can select many actions (set or reset BIT, load screen etc)...maybe you have added one action but without coupling the specific BIT to set or other...please check.
  19. hello Marko, are you sure that the variable that are you using to set the pad is "retained" type?...othewise at each reboot of the PLC this will take the start value set in its reference.
  20. Hi PLCsLOL when you add a module like analog input all its references (input value, status registers etc) are available in the "IO" menu than you can find in the bottom part of the window also where are available the menu: Global, Timers, Struct etc if you select this menu (IO) will show the list of the added modules; select what you want and all references will appear. when you add the module in hardware configurator its properties and references will be available for the ladder function as others tags...I think that the inputs and reference status of these modules will return or a INT16 or INT32 ...then for example...if you insert a comparison element one of its field can be filled with an input of the analogic input... for each of these input you can set an "alias" name....this can be done by the IO menu on the bottom...select input...and a column of alias name is present.
  21. Hi Andrew, exist many arduino library to use modbus RTU or TCP protocol..both master and slave...then how do the sketch depends on which library you will choose. each library include examples and someone also a manual...pay attention that Arduino MEGA doesn't has a native RS485 or ethernet port then you will need some extra board (usually cheap).
  22. Hi All, I am trying to send some mails and, for some of these, I have this "error message" (not from PLC but from the mail server): Reporting-MTA: dns; santino.mail.tiscali.it [xxx.xxx.xxx.xxx] Received-From-MTA: dns; Unistream [xxx.xxx.xxx.xxx] Arrival-Date: Fri, 28 Sep 2018 20:06:13 +0000 Final-recipient: rfc822; xxx.xxx@libero.it (but also xxx.xxx@gmail.com) Action: failed Status: 5.1.1 Diagnostic-Code: smtp; 552 This message is not RFC 2822 compliant [smtp-22.iol.local; LIB_670] Last-attempt-Date: Fri, 28 Sep 2018 20:06:13 +0000 the mail send works with other like "tiscali" mail, also with "email" ...I don't tried others. I looked for this in internet...seems that is my server "tiscali" that don't forwarded the mail...but I don't understood why...if I send directly with my mail service these works...then is something coupled at the PLC request...but what? thanks
  23. Hi Ofir, thanks for the answer; I know that I can set a BIT using a button in a web server page; also I know that I can dinamicaly pass a String to an hyper link object...and I already tougth ( I have to test this) a way to drive/force the user in some action to be sure that one at time can insert/modify a parameter. Thanks again
  24. Hi Saragani, I found the cause of the problem (obviously my fault); I have wrongly insert one more set of one of these bits, that I use to recall French language, in a wrongly place. I removed this and all works fine. In my previously checks I didn' see it. Sorry if I waste your time.
  25. Hi Giovanny, what you mean?...sorry I don't understood.
×
×
  • Create New...