Seite 1 von 1

String comparator ,problem

Verfasst: Samstag 4. April 2015, 21:46
von TOURNEUR
Hello ,

I'm trying to built ,an automatic program in Prflab ,for a bluetooth module.

When the module acknowledge the good protocol of command, it transmit a string "OK"

I 'm arrived to display this string ,but not compare.

I used string comparator with OK in channel A ,and string from port com receive.

I am not arrive to detect this "OK" string

Thank for people ,who can help me

Here, pictures of my problem

Re: String comparator ,problem

Verfasst: Sonntag 5. April 2015, 13:32
von IKT
Hello TOURNEUR,

you might have to put a '$TRIM' in between the 'Selection' & the '$COMP' parts, as in the picture below. (removes any unwanted SPACES from String)
As an alternative check it out with a '$CONST' instead of 'Selection' ...

Re: String comparator ,problem

Verfasst: Sonntag 5. April 2015, 18:05
von TOURNEUR
Good evening , IKT

Thank you for your help ,

I inserted this function between my Hex generator and comparator.
Without any success ...

I have put command on left and right, but nothing more .

Re: String comparator ,problem

Verfasst: Montag 6. April 2015, 12:27
von ankerwolf
Hello,
may be that there are CR LF at the end of the string, coming form the device?

LG Wolfgang

Re: String comparator ,problem

Verfasst: Dienstag 7. April 2015, 14:49
von Mike D
Hei,
try $Position instead of $Comp, then leading or trailing unvisible chars dont bother.
Any number greater than zero means, that $S exist in $M.

If you position the cursor on a connection during the projekt is running, you can see the actual value of the singnal.

Mike