Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

problem with loop and data converstion

Hi,

      I am in the process of displaying addresses in dropdown list(hex values). I can communicate with 0 to 64 devices. I am struggling with three problems. Please help me from these problems.

 

1) i know i have three addresses are available i.e.10,1F and 20(in future it may increase). if i write these three hex values with array constant, then i am getting reply as some indication tells devices are available at these addresses. So, in that case i want to display the writing address(who got some indication at read visa) to drop list and now i have done some coding in my VI for this but it is displaying some other characters not what exactly i am writing. You can see in below picture "untitle".

 

2) As i said above and its totally not good in case to search with 0 to 64 addresses. So, for that i have taken for loop and connected the index terminal to number to hex string finction. though, in that case, the read visa is not giving any intimation as before for three hex values. I don;t undestand whta is the difference, in both cases i am wirting hex string and why it is not replying in the case loop.

 

3) Actuvally, i want to search upto 0 to 64(hex) and for this I need to do for loop upto 0 to 100 but after 50 iterations timeout error is encounterd and total labview is structed.

 

Please some one help me?

Download All
0 Kudos
Message 1 of 2
(2,938 Views)

Am i doing it wrong way. You can see the following vi. As in my case, i am getting reply when I writes with array constant to write visa and when taken loop count to write visa then i am not getting any reply. I found it now that in other cases, Space is there infront of the character, I sense it is the root of problem. How I can slove this. Please some one suggest me.

 

Also, why it is resulting same in case of only one typecast and in other case with more converstion functions with typecast.

Download All
0 Kudos
Message 2 of 2
(2,930 Views)