Re: serial communication

This is a discussion on Re: serial communication within the labview forums in Programming Languages category; Can you post the code? Create indicators out of the "String to Write" control and your build functions.  Look at them in terms of /codes and hex.  Compare them to each other to see if they are the same.  If the code has run once, you can do a right click, create constant on the wire to create a constant of the data.  You can copy them to a blank VI if it helps do the string comparisons. Are you sure you are ending the string with the came characters?  Perhaps one is carriage return/line feed and the other is ...

Go Back   Application Development Forum > Programming Languages > labview

Object Mix

Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 01-08-2008, 05:10 PM
Ravens Fan
Guest
 
Default Re: serial communication

Can you post the code?
Create indicators out of the "String to Write" control and your build functions.  Look at them in terms of /codes and hex.  Compare them to each other to see if they are the same.  If the code has run once, you can do a right click, create constant on the wire to create a constant of the data.  You can copy them to a blank VI if it helps do the string comparisons.
Are you sure you are ending the string with the came characters?  Perhaps one is carriage return/line feed and the other is not?
Reply With Quote
  #2  
Old 01-08-2008, 06:10 PM
Ravens Fan
Guest
 
Default Re: serial communication

When the control is in the normal display, the terminator characters of carriage return and line feed are still there.  They just aren't visible because they are non-printing characters.:smileywink:
In your non-working code, you have a string constant "\r\n".  Is that constant in normal display or \ code display?  Everything else looks okay, so I suspect you are getting the codes mixed up.  If that \r\n is in normal display, then you are sending 4 characters, a slash, an r, another slash, an n.  This is NOT the same as \r\n in \code display which is two characters of \r (carriage return) and \n (line feed).  If you look at that constant in hex display, it should show up as 0D 0A.
There is also a special CR/LF primitive on the string pallette that you could drop on the block diagram to wire to the concatenation rather than dealing with \r \n.
Reply With Quote
Reply


Thread Tools
Display Modes


All times are GMT -5. The time now is 08:01 PM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
vB Ad Management by =RedTyger=

In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.