LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Problem with array and rs232

Hi!

I should test different channels with rs232.

I have an array in which I can choose my rx and tx ports.
If I write a value in my stingfield, click on start, I only get the values in my first array field of the choosen rx and tx.

What could be the problem?


vi is 7.1.1
~~~~
Regards
Sarah

LV 7.1.1
0 Kudos
Message 1 of 6
(2,530 Views)
Hmmm, I have problems to attache something :-s
~~~~
Regards
Sarah

LV 7.1.1
0 Kudos
Message 2 of 6
(2,524 Views)
Actually, your serial code seems to work fine, since you're getting data, so there's probably a problem in the way you build the data to be sent, but there's no way to really be able to tell without your code. Make sure you don't preview your post before attaching, or you lose the attachment.

___________________
Try to take over the world!
0 Kudos
Message 3 of 6
(2,516 Views)
Hmmm, I only click on submit post...

[Attachment Removed - MPK]

Message Edited by Support on 05-11-2005 07:31 AM

~~~~
Regards
Sarah

LV 7.1.1
0 Kudos
Message 4 of 6
(2,512 Views)
I can't run your code and I'm not entirely sure what your problem is, but if I understand your code correctly, the values are sent from all of the write ports to just the first read port. This is becuase the Index Array VI takes only the first VISA reference from the array. If this is your problem, you should enable indexing on the other array as well and get rid of the index array VI. Keep in mind that the arrays should be the same size. If they're not, you'll need another for loop inside the one you have, and you should index one of the arrays through that one.
Also, your code is hard to read. Try to avoid overlapping structures and wires and don't use a property node to read or write a value. The preferable way is to use a wire and if you can't, use a local variable. I suggest you search the site for "style guide". It should have some tips for good programming techniques.
If this didn't help, feel free to elaborate more on your problem.

___________________
Try to take over the world!
0 Kudos
Message 5 of 6
(2,504 Views)
Maybe you must cut out the Arinc and Synchro parts. This could be the reason why it won't run.

Hmm, I thougt I have done this indexing in the "test" case. The index values are everytime 12.
But the number of testing ports can switch between 12, 3 and 4 (option field on the left).

I'm sorry for the hard readable code, it is my first vi and I never worked with lv before.
Thanks for the style guide information!
~~~~
Regards
Sarah

LV 7.1.1
0 Kudos
Message 6 of 6
(2,495 Views)