cancelar
Mostrando los resultados de 
Buscar en lugar de 
Quiere decir: 

Connecting 2 cases

¡Resuelto!
Ir a solución

Im creating an automated door that will open when the passcode is correct .

Im stuck at where i enter the wrong passcode , the door is still working

What I expect is the door will only work when the passcode is correct.

Can anyone here help me to achieve that

0 kudos
Mensaje 1 de 22
4.330 Vistas

You really should only have 1 loop here and I think you would really benefit from learning to use a State Machine.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 kudos
Mensaje 2 de 22
4.312 Vistas

this is hard for me . Whai i need is the connection when only the passcode (123) is correct , then the door part work . Can you help me connect that with my VI ? Im spending hours figure it out how to connect and im lost now 😞

0 kudos
Mensaje 3 de 22
4.307 Vistas

@mrspaceman wrote:

Im creating an automated door that will open when the passcode is correct .

Im stuck at where i enter the wrong passcode , the door is still working

What I expect is the door will only work when the passcode is correct.

Can anyone here help me to achieve that


If you are new to LabVIEW Please go through LabVIEW Basics and  State Machine Architecture.

Few Queries and Suggestions to existing Code.

 

Use Shift Register Insted of Feed Back Node,

Based on what does the for Loop executes for 100 Times

Single Loop Itself will satisfy your Requirement

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 kudos
Mensaje 4 de 22
4.304 Vistas

@mrspaceman wrote:

this is hard for me . Whai i need is the connection when only the passcode (123) is correct , then the door part work . Can you help me connect that with my VI ? Im spending hours figure it out how to connect and im lost now 😞


Share your requirements in steps as a pseudo code or with some high level diagram

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 kudos
Mensaje 5 de 22
4.302 Vistas

I dont know how to connect between these 2 to get the door only work when the passcode is correct . Any hints ?

0 kudos
Mensaje 6 de 22
4.295 Vistas

it is impossible to write a program the way you are doing this here. You have events for 10 buttons, but the buttons have no labels so they all look the same on the diagram and the event definitions is unreadable. Never delete the labels, you can always just hide them on the front panel.

 

Then you have that second loop with weird dependencies. For example if the lock button is true, the state of the unlock button seems irrelevant. What are the valid states of these switches? How is the VI supposed to be used? What is the point of the outer FOR loop???

 

If you would wire the display indicator to the right of the event structure, you would not need the local variable. What is the point of the timeout case? Seems useless, because the lenght of the string can only occur in the other event, so you could just check there. No timeout event needed.

0 kudos
Mensaje 7 de 22
4.283 Vistas

@mrspaceman wrote:

I dont know how to connect between these 2 to get the door only work when the passcode is correct . Any hints ?



1.Remove the Upper Loop, Transfer the Logical Implementation to Lower Loop inside the TimeOut

2.If For loop has No value Remove the For Loop.

3.Create a Boolean Shif Register with False as a initial Value.

4.In the Button Value Change Event Decide the shift Register value as True/ false Based Password Correct/InCorrect.

5.Use Labels for Buttons.

 

 

Attached the Snap Shot of sample Impelmentation "Hope this works for you" but its not the best way of implementaion. its designed in such a way to use your own code to match your Requirement

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
Descargar todos
0 kudos
Mensaje 8 de 22
4.279 Vistas

can u send me the code ?

0 kudos
Mensaje 9 de 22
4.268 Vistas

@mrspaceman wrote:

can u send me the code ?


Modified in LV2014.

If you dont have the Latest Version try to Rebuild using the SnapShot shared

----------------------------------------------------------------------------------------------------------------
Palanivel Thiruvenkadam | பழனிவேல் திருவெங்கடம்
LabVIEW™ Champion |Certified LabVIEW™ Architect |Certified TestStand Developer

Kidlin's Law -If you can write the problem down clearly then the matter is half solved.
-----------------------------------------------------------------------------------------------------------------
0 kudos
Mensaje 10 de 22
4.259 Vistas