LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Combo box to code

Thanks Mike! So I just have to delete the close Visa block when the device starts measuring?

Can you explain me this a little bit more the "state mashine architecture"?

What about of my 2nd question?
0 Kudos
Message 21 of 62
(1,287 Views)
To have a grater idea of what I'm up to see the whole block diagram. One of the things trouble me is that every message must be sent to the VI ONCE. It is important to me to give me your opinion.
0 Kudos
Message 22 of 62
(1,281 Views)

Hi treadagon,

can you please explain the entire project? You have many event structures in your code. I think only one/FP is enough. Smiley Happy

Mike

Message 23 of 62
(1,279 Views)
Gladly!!! I have a device that measures the blood pressure through a cuff (placed around the brachium).

1)You can select mode: Adult ot Neonatal.
2)You can select starting pressure (depending on the mode you selected previously)
3)You can select every how many minutes you want to make a measurement.
4)In the end you can reboot the device.
(For 2,3 steps I needed these combo box advices did you see them?  :-D)

If you ignore these steps and press "start" it will start measuring with some defaults.

When you press the start button the device sends back several strings during the measurement.

When the measurement is finished it sends back the string "\02999\03". That string triggers a command that is requesting the measurements the device took. The device sends a large string which contains the measurements. I have succeed split the measurements with the String Subset block.

What I want is:

1)To confirm that the block diagram is correct
2)To confirm that every command will be sent ONLY ONCE to the deveice (I've encountered some problems in the past with this one. For this all the buttons are in "switch until released" mode.
3)The measurements appear on the screen and STAY there until a button (that I've not designed yet) clear the indicators.
0 Kudos
Message 24 of 62
(1,274 Views)

Hi treadagon,

the point is, your loop runs only one time. If you use an event structure in your loop, then every iteration an event has to occur. Did you try to stop the loop at the beginning? It do not work now, because the loop is first over if all code was execute. I recommand to rewrite your code. Is it important in which order the commands will be send to your device? Create only one event structure with an event for all buttons and comboboxes you need. Use shift registers to store your values and to decide if a command can be send or if another command has to be send before.

Mike

0 Kudos
Message 25 of 62
(1,265 Views)

Hi treadagon,

attached you will find an example, how i mean it can run. You can insert some property nodes to disable controls if they are not important.
Hope it helps.

Mike

0 Kudos
Message 26 of 62
(1,257 Views)


treadagon wrote:
I hope you're not too mad at me with my several questions... (If you are I sincerely  apologize) Smiley Sad


Dont worry much... Smiley Happy
 
Mike has to pass 2000 posts asap. Smiley Wink
- Partha ( CLD until Oct 2027 🙂 )
0 Kudos
Message 27 of 62
(1,252 Views)


parthabe wrote:


treadagon wrote:
I hope you're not too mad at me with my several questions... (If you are I sincerely  apologize) Smiley Sad


Dont worry much... Smiley Happy
 
Mike has to pass 2000 posts asap. Smiley Wink



Hi Partha,

i don´t think so.

Mike

0 Kudos
Message 28 of 62
(1,246 Views)

Why Mike ?! Smiley Indifferent

I think & strongly hope that you can & you will pass 2K well before this June 27th... Smiley Happy

- Partha ( CLD until Oct 2027 🙂 )
Message 29 of 62
(1,206 Views)
WOW!!!!!!! THANKS!!!!!! Well it certain communicates with the device! But I don't see absolutely nothing in the indicators. All the settings (modes, cycle, starting pressure) must be sent BEFORE the start command (no matter the order you send them) . During a measurement nothing of the settings must change. When I press the Start button it takes 2 times measurement. And it doesn't repeat the measurement in the cycle mode.

What are the shift registers and what is their use?
Why you used a for loop?
Why you used the timeout event structure while reading?
What is the array you build in the start event structure?
Why the empty string?

Neither I nor my supervisor know ANYTHING about LabView. So I'm fully allowed by him to ask questions at the forum. But in the end I'm about to explain him what I did. My graduation project is to control through Labview 3 medical devices (I'm studying biomedical engineering). Thanks again for your personal work


Message Edited by treadagon on 06-10-2008 02:25 AM
0 Kudos
Message 30 of 62
(1,196 Views)