Welcome, Guest. Please login or register.
Did you miss your activation email?
May 24, 2012, 09:24:13 AM
Home Help Login Register
News: Any Problems or Experience with Industrial Robots ?
Register and place your Question / Answer to worldwide Robotexperts right here !

+  Robotforum | Support for Robotprogrammer and Users
|-+  Industrial Robot Help and Discussion Center
| |-+  Stäubli & Bosch Robot Forum (Moderators: Werner Hampel, Jim Tyrer, Martin H, Fabian Munoz)
| | |-+  Ethernet Socket
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: Ethernet Socket  (Read 1038 times)
PTank
Guest
« on: February 20, 2011, 04:08:41 PM »

Anyone have experience with the ethernet socket commands. I am trying to trigger a barcode reader. Created the socket and it tests OK. I cant seem to get the sioSet command  to write my command to the port. Any ideas?
Logged
TygerDawg
Full Member
***
Offline Offline

Posts: 230


« Reply #1 on: February 25, 2011, 02:46:26 AM »

I checked a previous application and tried to remember the details, here is the setup if I remember correctly:

1.  Assume you call the serial / ethernet port "sioMyPort", an sio variable must be set in the sio data section
2.  Assume you set up a port via the pendant and call it "PortX", with all the correct baud rates etc.  Save the app & transfer it back to your PC...it will now have a new entry in the "io" library.
3.  In a program you must initialize the port & port name declaration with the statement "sioLink(sioMyPort, io:PortX)"
4.  When you want to write a string to the port, is done with the statement "sioMyPort=sMyString"
5.  Receive strings with the statement "sMyString=sioMyPort"
6.  Usually it is necessary to parse through the string to select characters you need using the delete(), toNum(), and toString() functions.  Or you can simply test the string as a whole.

I used freeware TeraTerm to test the comm commands between CS8 Emulator & PC, from there is simple to extend to real workcell.  Method notes:
1.  Start TeraTerm, make New Connection with settings (a) TCP/IP checked ON, (b) Host = whatever is stated at left bottom of CS8 Emulator Window, typically = "127.0.0.1", (c) Service= "other", (d) TCP Port # = 1301 or whatever port is set on Emulator, (e) Protocol = UNSPEC.
2.  You can use TeraTerm to comm to a VAL3 program, send & receive simple commands to verify communications, stop characters, eprogram statements necessary to strip away excess characters (which may be hidden), etc.   All the fun parts of communications programming.
3.  Another useful freeware that I used to verify characters was TCP/IP Builder.  This helped me "see" hidden characters that were embedded in the string.
Logged

TygerDawg
Blue Technik
Virtuoso Robotics Engineering
www.bluetechnik.com
Pages: [1] Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!