Help with serial port

VISA; TCP/IP, CAN and similar protocols
Ответить
ryan1234
interested
interested
Сообщения: 3
Зарегистрирован: 19 июл 2010, 18:35
Версия LabVIEW: 7
Контактная информация:

Help with serial port

Сообщение ryan1234 »

Question...

I hooked up a AALBORG command module to my computer and it will not work in labview.

I have installed drivers for it and when I tested it in hyperterminal it worked fine.

When I send commands to it in labview it usually times and sometimes it will send the same message back to me with the word ERROR at the end.

Does anyone have any guesses as to what I'm doing wrong?

BTW I am very new at labview so it's probably something simple.
Аватара пользователя
Eugen Graf

Activity Professionalism Silver Black
guru
guru
Сообщения: 6502
Зарегистрирован: 13 ноя 2007, 02:20
Награды: 4
Версия LabVIEW: 2009
Откуда: Saarbrücken
Контактная информация:

Re: Help with serial port

Сообщение Eugen Graf »

Hi!

Show us the right message (which works over hyperterminal) and your current :labview: block diagramm (as a screenshot).
ryan1234
interested
interested
Сообщения: 3
Зарегистрирован: 19 июл 2010, 18:35
Версия LabVIEW: 7
Контактная информация:

Re: Help with serial port

Сообщение ryan1234 »

Here is what I get when I send commands through hyperterminal
http://www.mediafire.com/?139w2k358zjowrv

Here is my block diagram (it's just one of the examples that came with the program)
http://www.mediafire.com/i/?fdlekyth999i7al

In labview I found that if I send it the same message 5 or 6 times at once it will still give me an error but my command module will respond the way it should.
(I type
VM 1 0
VM 1 0
VM 1 0
VM 1 0
VM 1 0
in the string to wrie box and labview will give me an error but my command module will still close valve 1 (the point of the command))
Аватара пользователя
Eugen Graf

Activity Professionalism Silver Black
guru
guru
Сообщения: 6502
Зарегистрирован: 13 ноя 2007, 02:20
Награды: 4
Версия LabVIEW: 2009
Откуда: Saarbrücken
Контактная информация:

Re: Help with serial port

Сообщение Eugen Graf »

Would you upload your pictures directly to the forum. I don't like advertisement :wink:

Thanks
Аватара пользователя
Eugen Graf

Activity Professionalism Silver Black
guru
guru
Сообщения: 6502
Зарегистрирован: 13 ноя 2007, 02:20
Награды: 4
Версия LabVIEW: 2009
Откуда: Saarbrücken
Контактная информация:

Re: Help with serial port

Сообщение Eugen Graf »

I think the problem here is the termination character, which will be automatically send by VISA Write. So switch them off on the configuration.
ryan1234
interested
interested
Сообщения: 3
Зарегистрирован: 19 июл 2010, 18:35
Версия LabVIEW: 7
Контактная информация:

Re: Help with serial port

Сообщение ryan1234 »

Lol sorry about the advertisements!

As you can probably already tell I'm not very tech savvy, I couldn't figure out how to put an image in my post so I just linked it to that site.

As for the termination character I opened up the configure serial port subVI in the program and set enable termination characters to false, I'm not sure if that's what you meant, but the commands still only work if I send the same one 5 or 6 times.
sudeep
interested
interested
Сообщения: 1
Зарегистрирован: 04 окт 2010, 13:08
Версия LabVIEW: 8.6
Контактная информация:

Re: Help with serial port

Сообщение sudeep »

getting error -107380330.code is attached below please help
Вложения
serial.vi
serial coomn problem
(9.21 КБ) 336 скачиваний
Аватара пользователя
K C
interested
interested
Сообщения: 8
Зарегистрирован: 04 июн 2009, 14:23
Версия LabVIEW: 3 till 2013
Откуда: Apeldoorn / Amersfoort The Netherlands
Контактная информация:

Re: Help with serial port

Сообщение K C »

Hi Sudeep,

Your stopbit setting is invalid. If you create a constant from the input you are sure you have the correct value.
Or use 10, 15 or 20 for 1, 1.5 or 2 stopbits.

Kees
Ответить

Вернуться в «Communcation with devices»