Jump to content

hotwires

Members
  • Posts

    203
  • Joined

  • Last visited

  • Days Won

    19

Everything posted by hotwires

  1. I had a crash course in UniLogic string to num conversions (formatting/handling). You have to remove leading spaces and trailing non numeric characters if I recall correctly. The Visilogic string to num FB is more flexible as to what it will convert. If your ASCII string is purely numeric characters you should be Okay. If you need a subroutine to strip off other characters let me know. I could share a snippet of code I used.
  2. An ohmmeter with an RS232 port would be the most logical approach in my mind. VOM talks ASCII to V570 via serial port then comparisons/decisions could drive outputs/actions.
  3. By filter the float values you mean extract for use elsewhere (separate from the rest of the telegram)? I have done something similar but on a smaller scale using find in substring and remove from string FB's. It would be a more complex construct for what you're doing, doable none the less. I agree with NahumS, need to see it in context, give an example of the extracted floats? A table, CSV, loaded into an array?
  4. The only reason I caught it so fast it that I've done it myself a few times. Only other advice most of the forum guru's would give is to break up the three lines in rung 1 into individual nets. I'm sure it works fine as coded but in some cases line stacking in a single rung (net) can give unexpected results. Something to do with the compiler, not sure... I'm loosely re quoting others. Glad you got it working to your satisfaction.
  5. As long as the wireless side of the bridge connects the ethernet side doesn’t know (or care) what it is connected to. In theory it should work with any ethernet enabled device using the standard TCP/IP protocol. I use Ubiquiti wireless networking devices for PtP and PtMP links. Almost all of their devices can be configured in bridge mode (WLAN:LAN).
  6. I recently setup two Unistream 5” pro to receive serial ASCII strings from two Ohaus scales, eventually got it working as desired. You are correct on the lack of help file content on the SERIAL Com RX function. I have kindly suggested content be added for that function. In rung two, the second object from left, top branch, tag “ComRx”; is that supoosed to be a coil or a contact? The (P) is a coil. This seems out of context. Try -|P|- positive transition contact. These two are close together on shortcut bar and ambigitouis sometimes. See if that helps and please advise. The way it stands now as a coil it would pass thru a true every scan that “logging” is true. Happy coding Sir. Hotwires
  7. UPDATE: FOR REFERENCE.... I took the time to see how a Vision V430 handles ACSII to INTEGER conversions: Visilogic will convert ASCII strings with: -leading zeros -leading spaces -trailing spaces -trailing letters It will not accept: -leading non numeric characters Unilogic will only convert strings with: -leading zeros *Leading and trailing non numeric characters must be removed before conversion.
  8. When you’re all out of fuses but have plenty of ammo. Photo credit to Paul on the facebook “Emergency Lights and Sirens Enthusiasts” group.
  9. Doesn't Visilogic support dynamic Slave ID? I was thinking I had a test program setup (once upon a time) where I could use entry keypad to set MODBUS slave ID, may have had to PTC the configure block in conjunction with new ID assignment. I recall it all working as expected. Everyone gets tired of hearing this from me (I'm quite sure), but here it goes again: "Why can't UniLogic have all the features of Visilogic and have all the new features of UniLogic"? A good share of Unistream sales (SURELY) is to Samba/Vision users who are upgrading hardware or at minimum very accustomed to Visilogic and it's feature set. It was a suprise to me as I slowly discovered the missing features. I know, I know... I want to have my cake and eat it to. Doesn't stop me from wishing
  10. @NoamM Was the VNC connections counter bug ever fixed?
  11. It’s not “pre coded”. Fairly simple to construct however. Link display element ( touch feild) to a memory bit (MB1), in ladder use NO contact to drive timer coil, second net: use a PTC (positive transistional contact) to drive a reset integer function —[R]— MB1 T1 ——| |————————( )—— T1 C1 (or T) —-|P|————————[R]—— alternatively I believe timer can "self one shot" but would repeat cyclically if button was held longer than usual: MB1 T1 T1 ——| |———|/|———( )—— T1 C1 (or T) —--| |————————[R]——
  12. Thanks for the help everyone Has given me in my "head scratching" moments. I try to pay it forward when I can. Here's to 2019 and the many successes Unitronics solutions will give us. I've had some bumps in the road but the support from @Joe Tauser, Unitronics US, Unitronics Israel, and this forum has been amazing (and free). Kudos to all.
  13. Happy New Year to Aus and the rest!!
  14. Unistream panels have VNC client/server capability that would be the "perfect" solution to your requirements. back to Vision, the MODBUS mixed R/W FB may simplify ladder for data exchange amongst PLC's. Otherwise you have to do MODBUS READ and WRITE commands separately.
  15. If you have an example of code and Unilogic software version, I could try to help. I have a Unistream 15.6" with 01RSC talking MODBUS to an RS-232 radio modem in a SCADA system. I wrote the code and it all works fine. Curious as to what is preventing setup from working for you.
  16. I'm managed to figure out UniLogics: "string to num", "replace", and "find in substring" on my own through trial and error. "String to num" will not interpret spaces (20h) in place of leading zeros in an ASCII string that you want converted to an integer. This presented me a dilemma since my device would send: ASCII "123.45 g", " 23.45 g", " 3.45 g", or " 0.45 g". The only assured zero place is the ONES digit. Using an iteration of "find in string" I got a count on the number of spaces left of the decimal point, used that to drive "times to remove" in "remove from string" only then could I rely on "string to number" to function regardless of tens and hundreds places being blank (spaces).
  17. Sounding buzzer logic solved after a phone call with tech support. The “start buzzer” and “stop buzzer” when triggered by a bit/coil MUST have set coils “-(S)-“ for OS to trigger and NO associated RESET coil is needed (they self reset). This was counterintuitive to me, but when applied it works.
  18. Thanks Joe, that is some meat and potatoes. Maybe I can equivicate in UniL and get same result with less FB’s than I am currently using. Trying to get out of the over kill programming habits, sure it works but less is more in ladder. Make it simple for the next Guy. UPDATE: Now I'm curious how Visilogic handles to the ASCII TO NUM conversion. @Joe TauserWere your ASCII strings padded with leading zeros left of the decimal? I.e.: 0123.45, 0010.41, 0007.26 in units of weight?
  19. Where can I find detailed help or an example of the "Remove from String" function?
  20. Joe: Please elaborate. Scale returns x.xx, xx.xx precision. By virtual decimal place you mean "10.41=1041"? This is what I did on AB 5/05 proof of concept program. I have to strip the ASCII decimal character and join the tens/ones characters with tenths/hundredths characters (concatenation?). I had the notion maybe the message parser could pull what I wanted out of the ASCII's rear end. It's weird that the STRING to NUMBER block won't convert double number ASCII bytes that don't include a digit (null) in the tens place. RSLogix didn't care about the tens place, would convert D#10, D#7, D# .41, etc. Parsing out tens and ones individually got me around the road block. Maybe I'm missing something there? The INT to REAL command actually works with simplicity (something not as simple in RSLogix). The null ASCII tens place caught me by surprise a bit (actually a byte to be exact). I am hoping to ditch the MULTIPLY and ADD FB's.
  21. I have an Ohaus scale with a serial printer port connected to a Unistream 5" pro. A part is place on scale and a comparison is made to a valid weight range. I finally have a working model for getting weight ASCII string into a REAL but it's very clunky. There has to be a better way. The biggest issue with my conversion rung (before using mul & add FB's) is if I weight in a part at 10.39 grams and the REAL displays as such and the next weight is 7.43 grams (THE TENS PLACE IS A NULL ((BLANK)) CHARACTER) the real displays as 0.43 grams. The tenths and hundredths always read out okay because the zeros present regardless of fractional weight. Is there a cleaner way to take " 10.39 g" ASCII, narrow to "10.39" ASCII and convert to REAL D#10.39? Next issue, I want the buzzer (more of a beeper) to sound for a short burst when a valid weight is received. In Vision there was a simple SB bit that would sound buzzer for any duration the OTE was true. I have tried several constructs with the BUZZER START AND BUZZER STOP actions but always end up with a continuous buzzer or a chatter. Please and thank you for any assistance. Please see "WEIGH IN" subroutine for example of the code I have that works but could stand to be simpler. JorachoPressNewScale12-20-18e.ulpr
  22. It was my understanding that the AB SLC 5/05 does not have native MODBUS capability. Additional hardware like a Prosoft MCM-3150 would be required? Sounds like the answer to the question "Is there a simple way to make a Unistream panel communicate with an AB SLC5/05" is.... NO.
  23. I have several SLC500 w/ 5/05 CPU’s on ethernet to PanelViews and Wonderware; is there a way to replace panel views with UNISTREAM panels as HMI’s. I would like to keep program and I/O intact. Thanks
×
×
  • Create New...