Control a robot motion via 5 Boolean Switches

Hi All
I have a vi that i want to control the motion of a robot ( Forward, Backward, Right, Left, and Stop) Which are five states.
I need these states via Boolean switches (It looks like a cross in the front panel).
When
the user presses the right button the robot will move to the right
according to the program I already amde to dael with robot.
When
the user presses the left button the robot will leave the right state
and go to the left state, so the robot will turn left.. and so on
Only one swithch can be pressed a time.
I
need some body to help me to get the core ( I think state machine) that
will do the transfer between the states with the given condition is met
(only one switch selected from the five switches) to perform only one
task from the five tasks
Best regards
Mido(Please send the solution as LabVIEW 8.5 vi)

Well, that doesn't sound too hard. What kind of hardware do you actually have? What are the switches actually controlling? Or, is the robot controlled via a communication protocol? You said "according to the program I already made to deal with robot." What program? Is this a LabVIEW program? If so, are you trying to modify this program or write a new one? Have you looked at the KB articles? How about the examples?
http://search.ni.com/nisearch/app/main/p/y/0/q/application%20design%20patterns/x/0/

Similar Messages

  • Simple boolean switch question

    I'm quite new at using structures (while loops, etc) in LabVIEW, so here's a very oversimplified question (hypothetical, but I think will help me understand what I'm doing). I have 2 on/off boolean switches, each one controls 2 identical LEDs which display if switch is on or off. One set of 2 LEDs (one from one switch, one from the other) should update every 1s, the other set of 2 updated every 5s. How do I accomplish this most efficiently?
    I attached a picture of my first try, this lets me time the udpates individually but of course it's wrong since I then learned each while loop only takes the input when you first click run, and doesn't keep checking the input after that point. Thanks!
    Attachments:
    booleanquestion.JPG ‏26 KB

    You only need a single loop and you don't need any local variables.
    Place all controls inside the loop and spin the loop every 1000ms.
    Update one set of controls at every iteration and the other set of controls every 5 iterations using a case structure.
    Message Edited by altenbach on 06-09-2008 01:25 AM
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    update1&5seconds.png ‏14 KB

  • Boolean switch until released using an event structure

    I am using a boolean control with the mechanical action set to switch until released, I want the button to go back to the original state.
    I am using it in an event structure set to trigger on a value change. The action of pushing the button is generating two events, one of the on state and one for when it returns to the off state.
    How do I control this so that only one event is triggered and the second event that is queued up is ignored, I would like the button to go back to the original state and not execute code twice.
    Thanks
    Jim
    Solved!
    Go to Solution.

    You can use the value from OldVal or NewVal in the event case and a conditional structure to mask it off.  Do you really need switch until released functionality?  That's intended to give you two events, as the click and release are different actions.  Switch when released might be a better fit for you if you only want one event.
    --Using LV8.2, 8.6, 2009, 2012--

  • Control a micro-controller via usb

    Hi,
    I'm looking for a way to control a micro-controller via usb using a java program. The micro-controller is used as an on/off switch. Is there a micro-controller that has a java driver provided?
    thanks

    The environment for Arduino is programmed in Java ( http://www.arduino.cc/en/Main/Software ) and you can use Java serial comms to communicate with it ( http://www.csc.kth.se/utbildning/kth/kurser/DH2400/interak06/6-Comm.html ).
    Mine hasn't arrived yet, but I'm planning to play with one.
    Pete

  • How to detect the correct sequence of boolean switches pushed

    Hello
    My program does everything I want it too. However, I need to have the boolean switches (digital inputs when wired to hardware) be detected in the right sequence. There are 16 switches on a hardware board. The test subject is shown 3 colours before hand and the sequence of buttons to be pushed when prompted on the screen with one of the colours, each colour pertains to a specific sequence of 4 switches being pushed  out of the 16 as quickly as possible. The sequence of buttons always stays the same according to the hree colours red, yellow, blue.
    In the program that is 99% working correctly I tried using a flat sequence. It will give me a true if i hit the switches correctly - but will also give a true if I hit them backwards etc... I thought a flat sequence was read left to right?
    Then I messed around using a structured event - index the array of switches pushed and compare to an array control of values. I understand how it works, but the correct code is elusive.
    I attached an image from the program I have done but missing the correct sequence. (Flat Sequence)
    I attached the code for the structured event that i messed with. Don't laugh - I was just experimenting - I never used a structured sequence setup before.
    Hope someone can help me.
    Ned
    Solved!
    Go to Solution.
    Attachments:
    Clipboard01.jpg ‏96 KB
    Button Sequence Example 9-1.vi ‏37 KB

    Hi Ned,
      Your Producer-Consumer model is actually very close to working.  In the original screen-captured version it looks like you're trying to use the sequence structure to capture the order, but in reality you will only capture the logical AND of all 4 buttons with no information about the order in which they were pressed.  The sequence structure does not by itself wait for an event to occur inside the frame, which means all 4 frames will be read as fast as the processor gets around to reading them - which will be very fast.
      I made some changes to your VI and renamed it Rev 1.  See if that makes a little more sense with the notes I made on the front panel.  I also did a different version with a single loop and some added functionality (-kb), just in case your'e interested in another way to look at it.
    Kurt
    Attachments:
    Button Sequence Example 9-1 Rev 1.vi ‏38 KB
    Button Sequence Example 9-1-kb.vi ‏46 KB

  • BMP on a boolean switch

    I have placed a bmp picture on a boolean switch in editor, when I come to use the switch I can only activate it by pressing the outside border and not in the middle. There must be a simple solution to this.

    > I have placed a bmp picture on a boolean switch in editor, when I come
    > to use the switch I can only activate it by pressing the outside
    > border and not in the middle. There must be a simple solution to this.
    Popup on a Boolean and choose Advanced>>Customize. This takes the
    Boolean into the control editor. In the control editor, you have
    additional popup options such as importing an image into different parts
    of the Boolean. What you want to do is import the image as a Decal.
    This will now be clickable and will be pasted on the button in all
    states, like a decal.
    Greg McKaskle

  • Using network shared variables in two computers connected via a network switch

    let me start by saying im a rookie to the programming environment but i have used Labview a couple of times to understand the basics,  i have a computer and a laptop (both using vista), both of them with Labview Full development System (Student ed. with Mathscript) installed, so what im tryin to do is to use the built in microphone located in the laptop to aquire sound and then use a Shared Variable to transfere the sound signal from the laptop to the computer, the laptop and the computer are connected to a network via a network switch and ethernet cables,  so far i nothing worked, i can manage to create the shared variable in the laptop and use it there but it doesnt appear in the computer, im not sure whats the problem i have even disabled firewalls in both systems, help from anyone wil be appreciated.....

    Hi Lukie,
    This KB should be of some assistance to you.
    Trouble shooting network published shared variables
    Also the following link gives some instructions on the use of shared variables.
    http://zone.ni.com/reference/en-XX/help/371361B-01/lvhowto/bind_to_source/
    I hope this is of some assistance, let me know if you have any more problems.
    All the best,
    Message Edited by mickeyw on 08-05-2008 12:29 PM
    Mike W
    Applications Engineer
    National Instruments UK&Ireland

  • Can I control the system output via Logic Pro?

    I know how to record system output in Logic Pro (CH 13&14), but in order to do that, the tracks in Logic Pro must be muted to avoid feedback.
    What I'm wondering is if I can control overall system output via a track/tracks in Logic Pro. I've got a Plextor PVR set up so that I can watch tv on my Mac, but when I connect my digital cable box to it the volume is down at around a faint -24 dB. I'd like to be able to boost the gain with Logic.
    Thanks in advance for any help!

    Never mind. I found a cool app called Audio Hijack Pro that works perfectly for this.

  • Imitate boolean switch behavior using an event structure on a front panel indicator

    Hi,
    I am looking for a possibility to imitate the bevhavior of a boolean switch with an event structure. To be more precise, I want a boolean value to change each time I click on the front panel indicator and then remain constant until I click again. I have not worked with shift registers in a while loop yet, but could this be a way to find a solution?

    LordSnow wrote:
    Okay, I figured it out, BUT I still have a problem. Before I first trigger a mouse event on the front panel indicator, I already need the case structure to be executed once. Therefore I assume that I need some kind of default value, but since the event structure does not create any output at first, I have no idea how to do that.
    Are you talking about the shift register you just created?  You can while in a default value on the left shift register ndoe.  It is wired outside of the loop.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • Using ps3 control on Ps vita via blutooth

    As far as I remember reading, the Bluetooth is only for audio? - so headphones etc, not controllers (at present) - I maybe wrong though... But since there's no TV out for he console (at present) they may not think there's a need for it on a hand held?

    Chrisobsession wrote:
    are you god or something where you KNOW these answers ? you sound very arrogant saying "it's NEVER going to happen" anything is possible just cause the console has all these features there are some out there that would prefer to use a controller bluetooth ...  the customer is always right so if this idea is in demand by many, then sony will eventually patch this and add it to a firmware update .. and if they dont ... then some dev's will leak there ways on how they did it  don't give people false information if you DON'T know I think you need to get off your high horse. If I were you I'd think twice before flaming or insulting other people or accusing people of something when it's not true. It happens to be my opinion based on historically how Sony's stance has been on the subject, what they have said in the past and and what their focus is regards the Vita. You can think what you want and make yourself believe it will happen but it's not going to happen. You obviously have no clue as to what Sony are trying to do with the Vita or what direction they are going in. They aren't even providing remote play for PS3 games you seriously think they are going to enable PS3 control on the Vita via Bluetooth.

  • Boolean Switch timed on

    I have an array of Boolean switches being read by a FOR loop and sending out serial commands. I would like to have the switches be TRUE for an adjustable (10 - 1000 ms) amount of time and return to FALSE. I've tried a few things without luck. The problem I'm having is returning the array of Boolean switches to FALSE using timers.
    Thanks,

    Hello,
    If you right click on your swicth button, you can set the "mechanical action". If you want your boolean to switch back to off just afterthe true value has been read, set the mechanical value to "latch when..."
    Does this trick match your needs or is it out of sense ?
    When my feet touch the ground each morning the devil thinks "bloody hell... He's up again!"

  • Sun Cluster 3.x connecting to SE3510 via Network Fibre Switch

    Sun Cluster 3.x connecting to SE3510 via Network Fibre Switch
    Hi,
    Currently the customer have 3 nodes clusters that are connected to the SE3510 via to the Sun StorEdge[TM] Network Fibre Channel Switch(SAN_Box Manager) and running SUN Cluster 3.X with Disk-Set.The customer want to decommised the system but want to access the 3510 data on the NEW system.
    Initially, I remove one of the HBA card from one the cluster nodes and insert it into the NEW System and is able to detect the 2 LUNS from the SE3150 but not able to mount the file system.After some checking, I decided follow the steps from SunSolve Info ID:85842 as show below:
    1.Turn off all resources groups
    2.Turn off all device groups
    3.Disable all configured resources
    4.remove all resources
    5.remove all resources groups
    6.metaset �s < setname> -C purge
    7.boot to non cluster node, boot �sx
    8.Remove all the reservations from the shared disks
    9.Shutdown all the system
    Now, I am not able to see the two luns from the NEW system from the format command.cfgadm �al shows as below:
    Ap_Id Type Receptacle Occupant Condition
    C4 fc-fabric connected configured
    Unknown
    1.Is it possible to get back the data and mount back accordingly?
    2.Any configuration need to done on the SE3150 or the SAN_Manager?

    First, you will probably need to change the LUN masking on the SE3510 and probably the zoning on the switches to make the LUN available to another system. You'll have to check the manual for this as I don't have these commands committed to memory!
    Once you can see the LUNs on the new machine, you will need to re-create the metaset using the commands that you used to create it on the Sun Cluster. As long as the partitioning hasn't changed from the default, you should get your data back intact. I assume you have a backup if things go wrong?!
    Tim
    ---

  • How to use a joystick on the local side to control a robot remotely connected by FP2000 .

    Hi All,
    Does anyone know how to use a joystick to teleoperate a robot on the remote side.
    The robot is connected to the Field point FP2000 RT module and hooked to the internet.
    I can use web publish to publish the control to the local side and control the robot by
    changing the control value on the picture.  Howerer, I have no idea about how to connect the
    joystick on the local compurer to the remote FP rt system. It seems I need to initionalized a communication
    between them. Does any one have the same  experiences??
    Ta. Shih  

    What you will probably need to do is write a seperate program which will run on the PC and send commands to the program running on the FP.
    You can read the joystick data with the VIs in the Advanced>>Input palette and you can communicate with your program by using a simple protocol over a TCP connection. You can find some examples in the example finder (Help>>Find Examples) by searching for TCP.  You can also find an example here and here. The protocol itself is up to you and can probably be fairly simple.
    Message Edited by tst on 02-15-2006 08:20 PM
    Try to take over the world!

  • Controlling ESP 300 motion controller via Labview

    Hi all,
    It's for the first time I try to communicate with other devices using Labview. I made a VI (07_rs232.vi) to send commands to ESP 300 motion controller via RS232. This VI should make zig-zig move using two axis (2 and 3). When I'm running this VI slowly (Highlighted execution) or with smaller count of iterations (4x4) everything works fine. But when iteration count is higher error on the device occurs ("command does not exist"). Does it have connection with the memory of the ESP 300? Am I writing too many commands to its memory? I have no experience with this. I appreciate any kind of help.Message Edited by ceties on 09-18-2006 09:34 AM
    LV 2011, Win7
    Attachments:
    Temp.zip ‏83 KB

    Hi,
    For some reason, the link you gave doesn't work ...
    Sory I forgot the subVIs... here is the dll with everything. I didn't use the VIs from NewPort because the code was quite poor.
    You can use th subVIs to :
     - read axis position or informations
     - send command to be executed
     - send "question" and read the "answer"
    It's quite easy to use because the VISA session will be help in the FGV (blue VI), use it to open the session at the beginning of your process, use it for controlling your axis and use it also at the end to close the VISA session.
    Hope thi help
    BTW : aboute the "\r" well yes it is required as an end of message character
    When my feet touch the ground each morning the devil thinks "bloody hell... He's up again!"
    Attachments:
    ESP.llb ‏132 KB

  • How can I use one motion controller to control two robotic independently?

    the help document says :
    Note  Configuring and clearing buffers is a processor-intensive operation on the motion controller that requires the allocation and deallocation of memory. You should configure and clear buffers only when motors are not moving and onboard programs are not running. For example, if you wish to execute three simultaneous contouring operations on axis 1, axis 2, and vector space 1 (with axes 3 and 4), you should first configure all three buffers before starting any of the operations. You can start the contour operations independently, and at different times, but should wait until all operations are complete before clearing any of the buffers.
    and i tried to conduct two contouring operation on two vector space. and tried to clear or configuring buffer for one vector when another one is still moving. so that i can start or end the movement at any time i want,and  it is ok.no error. but when i tried add a buffer  breakpoint output along with each vector movement. the bp doesn't work if the other vector is running . is there anyway to solve this problem.

    I think you've misunderstood what the dns attribute is for. The dns attribute returns the hostname of the client accessing your website, not the hostname of the website that linked to your website.
    For example, when someone using the Comcast ISP goes to a malicious website at example.com that loads images from your website at www.amigoo.net, the dns attribute will be something like "c-1-2-3-4.ca.comcast.net", not "example.com". ACLs are used for authentication and authorization of clients (not the websites those clients chose to visit), and they don't provide the functionality you're looking for.
    If I understand correctly, you want to prevent websites other than amigoo.net from linking to files in your d:/webserver/imat/pics_upload directory. You can achieve this adding the following lines to your obj.conf configuration file:
    <Object ppath="d:/webserver/imat/pics_upload/*">
    <Client referer="*~*amigoo.net">
    PathCheck fn="deny-existence"
    </Client>
    </Object>

Maybe you are looking for

  • Windows xp not detecting airport

    I've tried a lot of different things to get my Airport Express to work with this PC (Piece of Crap) running Windows XP.  It's like pulling teeth to get these two devices to work together!  I'm no newby to these technical issues, either.  I am very te

  • How to remove target node if source field value is empty SAP PI Mapping

    Hello, how to remove target node if source field value is empty in graphical Mapping. Like if MIddle name in source filed is empty, I would like to eliminate target field from out put XML. Thank you John

  • Very Basic:  Can I install OEM 12c in a 'Database Control' style?

    Environment: Oracle 11.2.0.3 EE on Solaris 5.10 u10 No experience with OEM, yet ... I would like to set up OEM 12c for one (1) Test database but want to make the installation as easy as possible and without as much of the 'Cloud' control 'stuff' for

  • Is it possible to send SMS through java

    Hi all I m a student and as a part of my project I need to create an SMS server(SMS gateway). Can we send SMS through Java and if yes then send me the code for the same . Also on which GSM Modem will it Work , I've heard about Nokia GSM Modem N32. Ki

  • Crystal reports - how to identify a sequence gap within a column

    I am working on a project which requires the ability to identify gaps in numeric sequence within a column. Does anyone have any thoughts on what a formula such as this? It can be done in excel using the formula columns in screen shot columns I and J.