LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Drop-down menu

Solved!
Go to solution

Hi,

 

I have to communicate in modbus with a machine which is in ASCII, so I want to create a drop-down menu within all the ASCII command. 

 

Any Idea ?

 

thanks

Peter.

Labview 2010
0 Kudos
Message 1 of 13
(4,781 Views)

You can take all the commands into Ring control and pass the values using the property nodes.

-----

The best solution is the one you find it by yourself
0 Kudos
Message 2 of 13
(4,778 Views)

Hi Peter,

 

"Any Idea ?"

Yes: take a dropdown menu (aka Ring) and input all your "ASCII command"...

 

What answer do you expect? Just create the menu!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 3 of 13
(4,777 Views)

I don't really know,

 

In fact, in the drop down menu I want to put the instruction (example : Move to the first position) and when this case is chosen we send the ASCII code of this instruction to the machine..

Peter.

Labview 2010
0 Kudos
Message 4 of 13
(4,771 Views)

If that is a big instruction then you can go for Enum so what ever you want the desciption of the command put it into Enum so correspondingly in case structure you can send the command.

-----

The best solution is the one you find it by yourself
Message 5 of 13
(4,767 Views)
Solution
Accepted by Peter Saraiva

Hi Peter,

 

"when this case is chosen we send the ASCII code"

Well, that sounds like the perfect use for a case structure, don't you think?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 6 of 13
(4,766 Views)

Yes of course I'll use a case structure.

but in what kind of variable should I put my string command ? and where can I find that ? knowing that the command are in ASCII

 

Regards

Peter.

Labview 2010
0 Kudos
Message 7 of 13
(4,761 Views)

Hi Peter,

 

- LabVIEW doesn't work with variables...

- when you need "ASCII commands" I would use a string constant...

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 8 of 13
(4,756 Views)

Ok, sorry I'm a new user of labview lol Smiley Embarassed  

 

 

Thank you for your help;

 

Peter.

Labview 2010
0 Kudos
Message 9 of 13
(4,753 Views)

Actually-  This sounds like a great use for a combo box.  They are a littel under used but can very easilly map a pairs of strings.  Display "Human readable" and value in ASCII.


"Should be" isn't "Is" -Jay
0 Kudos
Message 10 of 13
(4,742 Views)