I2C + class motor from examples of robotic controller

I try to combine (i.e. to use together in the same project) the motor controller class used in "Starter Kit 2.0 Custom FPGA" with I2C of "Communication I2C - sbRIO" in the examples of the Robotics module.

I have already combined the FPGA code in a single FPGA VI and have tested the two individually.  When I go to use them together, I can't use the same FPGA VI reference because one is designed using a FPGA VI reference in dynamic mode (engines) and the other uses an FPGA VI reference that isn't in dynamic mode (I2C).

So, what should I do?  I was going to try to convert the I2C in dynamic mode, but the only way I'd be able to do is to open the FPGA reference in each Subvi (since I can't bind to a type in the dynamic mode definition).  It also looks like trying to convert each other would be a nightmare because it would require to change the classes also (which is a mystery to me).

P.S. I have sbRIO-9632 (Starter to be transferred to a large robot Kit)

Nathan_B. . I met the same problem, when I mixed the two codes.

And the only way I found to resolve this problem, configure the device "FPGA" in dynamic mode, then create a control and change of the Subvi in relation to the 'I2C Protocol', with this command (replace the input and output of the 'Sub - VI' - reference fpga). In this way, I realize the work programme. (see attachment).

Tags: NI Hardware

Similar Questions

  • Read the motor current by using the controller PXI-7350 and MID-7604

    I use the PXI-7350 controller and MID-7604 drive to run a motor drive.  I would like to be able to measure the motor current while moving the engines.  This measurement is possible?  If so, what commands are required to read the motor current?

    Hi Casey,.

    the 7604 can limit the current to a value that is selectable by the user and you can activate the current reduction if the axis is stopped, but there is no way to read the current engine. If you want to measure the motor current, you must do it with an external device, but due to the current chopping and multiphase, motor control stepper motors is not a trivial task. Micro step mode the current phase looks like a rough sinus with lots of harmonics signal, so you will need to do a true measure requiring RMS of expensive measurement equipment.

    Anyway. If you need to know the temperature of the motor you should better measure the temperature directly. The most inexpensive device OR do is the NI USB-TC01, but there are many other options available.

    Kind regards

    Jochen

  • Class derived from LabelField with custom font color, but when focus not only

    Hello

    I have some problems with the LabelField-derived class. I want it has customized color background and police, but only when it does not have focus.

    I tried to do the following:

    protected void paint(Graphics g) {
        if (isFocus()) {
            super.paint(g);
        }
        else {
            final int bgColor = g.getBackgroundColor();
            final int fgColor = g.getColor();
    
            g.setBackgroundColor(backgroundColor);  // from member
            g.setColor(fontColor);  // from member
    
            super.paint(g);
    
            g.setColor(fgColor);
            g.setBackgroundColor(bgColor);
        }
    }
    

    but the final effect is that this field has the custom until the first focus/unfocus font color. When I do not check the isFocus(), police have custom color when the field has focus too.

    Similar do in drawFocus (Graphics g, boolean on) does not solve the problem either.

    I target BB > = 4.6.0.

    Do you know how to do properly without calls drawText custom?

    Kind regards

    Piotr

    What happens if you replace

    If (isFocus())

    with

    If (g.isDrawingStyleSet (Graphics.DRAWSTYLE_FOCUS))

    and (maybe - I'm totally guessing here) substitute drawFocus doing nothing?

    BlackBerry GUI has many peculiarities, so you never know what path is right.

    A word of caution: most likely, you will have also to invalidate() field when it changes its "focused" State Don't do this in onFocus() / onUnfocus()! Those (especially the onUnfocus()) are not always correctly called (BB frame problem). Make your field implement FocusChangeListener and make these invalidations in the method focusChanged() (using setFocusListener (this) somewhere in the constructor).

  • Blue screen after conversion to type from SCSI to IDE controller

    Hello

    No idea how to convert IDE controller SCSI controller in Windows xp (32-bit) OS?

    This virtual machine has a single main drive.

    I followed this article, but it leads to the blue screen error

    http://KB.VMware.com/selfservice/microsites/search.do?language=en_US & cmd = displayKC & externalId = 1016192

    Even I tried with free, but nothing works.

    No idea how to solve the problem or how to convert the type of IDE controller type of SCSI controller without error on blue screen?

    Now you can do it.

    The important thing is your scsi boot disk should be scsi 0000 - this way the second disc 0001 - otherwise she would try to boot from your empty disk.

    After that, you can of course remove the extra drive.

    Reg

    Christian

  • To access the properties of the class one from another

    Hello

    I have two clips on the stage at frame 1 and frame 2. Both are instances of classes. (They are not created dynamically, just their affair is set to their class names)

    I created soundChannel and sound objects in class 1 and I want to access it from class 2. (I want to stop the sound chain that was started in class 1)

    Is it possible to do this? If so, this will be true for other properties also?

    Thanking you,

    Chinmaya

    You want to stop the sound of the previous movieclip, right?

    You can do this by using SoundMixer.stopAll ();

    It stops all sounds in your SWF file. You can also start any sound later.

    The second approach is to do your "musicChannel' a global variable.

    To do that he report on a new layer which is empty and avialbale throughout the main time line and without pictures keys are there [with the exception of the first presence].

    now to access this variable, you can use a statement like below:

    (stage as MovieClip).musicChannel.stop ();

    If that also does not solve your problem then paste the code for the two classes, I'll look into it.

  • Class selector from numbers?

    Hi friends,

    Can we have a class selector that starts from numbers (0-9)?

    Like as shown below:

    {.3BD}

    margin: 0;

    }

    Thank you

    That is right. You cannot start with a digit, a class name.

    --
    Murray - ICQ 71997575
    Adobe Community Expert
    (If you * MUST * write me, don't don't LAUGH when you do!)
    ==================
    http://www.dreamweavermx-templates.com - template Triage!
    http://www.projectseven.com/go - DW FAQs, tutorials & resources
    http://www.dwfaq.com - DW FAQs, tutorials & resources
    http://www.macromedia.com/support/search/ - Macromedia (MM) Technotes
    ==================

    "Mohammed Arif" wrote in message
    News:e78ubn$8EQ$1@forums. Macromedia.com...
    > Thanks for your reply Murray.
    >
    > But in IE 6.0 and even Firefox 1.5, it does not work.
    >
    > So where I'm wrong?
    >
    > When I change as shown below:
    >
    > . ENW
    > {
    > width: 120px;
    > fonts: 98% Tahoma, Arial, Helvetica, without serif.
    > border: 1px solid #bab8b8;
    > text-align: left;
    > color: #4c4c4d;
    > }
    >
    > It works but...
    >
    > .4FN
    > {
    > width: 120px;
    > fonts: 98% Tahoma, Arial, Helvetica, without serif.
    > border: 1px solid #bab8b8;
    > text-align: left;
    > color: #4c4c4d;
    > }
    >
    > in this case it doesn't.
    >

  • MsoNormal class import from word 2010 even if deleted formatted

    Why is this happening? It never happened in previous versions because as far as I know. How can I prevent it?

    (No, we are not upgraded to 2015 and yes I know that I can out band via Notepad, sometimes you want things like hyperlinks to import.)

    Make sure this text, structure, basic formatting (bold, italic) is selected in the menu dropdown formatting.

  • GroupDataModel in an active Frame (aka Cover)?

    Hey guys,.

    I have an active frame for my application that uses a simple ActiveFrame class (derived from examples on the ' net).  He received an ImageView and a label.  in my main.qml I connect the signal of thumbnail() to an onThumbnail() function and send the text to the ActiveFrame class to update the label by a Q_INVOKABLE update() method.   Everything works beautifully.

    I would replace the label with a ListItemView that is attached to a GroupDataModel in my main class (a class of client Manager 'work').

    How can I go on the passage of the GroupDataModel to the SceneCover?

    the job manager and the scene covers both are exposed to QML via setContextProperty.

    Can I put a GroupDataModel as a property on my SceneCover and set it with a Set accessor method?

    is there a better way to do it?

    EDIT: update, I tried simply adding a ListItemView to the SceneCover.qml page and some properties Label.text of binding to the property of the presentation object workManager representing the GroupDataModel, but the ListItemView on the SceneCover is empty.

    Thank you!

    J

    OK, solved it myself.

    First of all, in the applicationui.cpp file, I put the parent to my WorkManager object and the SceneCover object:

        // Create a WorkManager
        WorkManager * workManager = new WorkManager(this);
        qml->setContextProperty("workManager", workManager);
    
        // Active Frame
        ActiveFrame * activeFrame = new ActiveFrame(this);
        Application::instance()->setCover(activeFrame);
        qml->setContextProperty("activeFrame", activeFrame);
    

    Then, in the constructor for the class ActiveFrame, I find the WorkManager and define a context property.

        qDebug() << "ActiveFrame;:ActiveFrame(), my parent is " << parent;
        wm = parent->findChild("myWorkManager");    QmlDocument *qml = QmlDocument::create("asset:///SceneCover.qml")
                .parent(parent);
        Container *mainContainer = qml->createRootObject();
        setContent(mainContainer);    qml->setContextProperty("myWorkMgr", wm);
    

    After having done that, I can access properties, in particular, the GroupDataModel property of the WorkManager.

    not sure if it's the "right" way to do it, but it seems to work reliably.

    see you soon,

    J

  • motor continuous: what are the step to build a controller

    Hello

    I hava a motor continuous with sensor position and data acquisition

    I want to control '' position' ' of this method of dc motor using state space in labview

    can someone give me the step what can I do to implement this controller?

    I wheel a lot of article but I'm confude of where to start

    Best regards

    Magnin

    See answer in:

    http://forums.NI.com/T5/LabVIEW/DC-motor-speed-control-using-LQR-controller/m-p/2359316#M735694

  • Application of the example of credentials of dynamic JDBC from Steve Muench

    My apologies for this newbie... question but I will try to understand the example of dynamic credentials of Steve Muench JDBC application:

    http://radio.weblogs.com/0118231/stories/2004/09/23/notYetDocumentedAdfSampleApplications.html#14

    I think I understand most of it, but a little, I do not understand is why she customizes the ADF Page Lifecycle (DynamicJDBCADFPhaseListener, DynamicJDBCPageLifecycle, DynamicJDBCPageLifecycleContext).

    Can someone explain to a developer of ex-formes why is this code?

    I also try to rework a way for the session to be invalidated when the user connections

    for example a user names, it does not use the logout function, but uses the back button back to the login page. When newspapers he in there with a different set of credentials, would be a start of a new session, or as I suspect, it would use the initial credentials?

    Thank you

    You can ignore these three classes in the example. They are not related to the solution of dynamic identification and must have been left by some other examples I've evolved into what you see. Sorry to have cluttered the implementation with stuff that is not really contribute to the actual solution. DOH!

  • delegate method calls to the members of a class

    Hello

    I'm new to LabView and using the 2013 version.

    I am familiar with the concepts of object-oriented programming.

    situation/goal

    I have a controller that controls axes. The controller said communication happens via plain text messages.

    I want to control the two axes with orders abstract (moving, stop, speed change, etc.) of LabView.

    That's why I created a class of axis with several parameters. (although)

    The controller communication is established via an ActiveX reference.

    I created a controller class that holds said reference in addition to the two axes.

    My goal here is to create a controller object, which past its ActiveX reference for the two axis.

    To add lines to the controller I dragged the class axis from the window of the class controller twice overall project.

    I created some accessors to all members of the class of the axis, including its ActiveX reference.

    problem

    In the Set accessor method for the controller class ActiveX reference, I would like to call the setters for the return of the two axes objects that contains the ActiveX controller.

    I can separate the controller to see the two axes, but I can neither unbundle either of the axes nor can I add a method node to them.

    It is logical that the separation is not possible to ensure encapsulation, but why can't I just call a method?

    Am I still add references to objects when you drag the axis class?

    Or is what adds the class itself?

    If this adds the class, how can I add a reference to an object of a certain class as a member of another class?

    I've attached a screenshot of the controller class.

    Thank you for your help.

    Hello

    The object Oriented Design is rater hard. Encapsulation banned, as you said, the data from your classes are defined outside their class.

    In your case it means that you have to create a data member access VI inside of the class of the Axes. These access screws (methods) allows you to set the values for these axes of type two objects inside of the controller of the class. Make sure that these two classes are in the less community.

    You can refer to a class using reference data value, Yes, BUT in this data type to the reference class is included. At the time, it seemed more convenient: LabVIEW programming job: The decisions behind the Design http://www.ni.com/white-paper/3574/en/

    Self an example here:

    Examples for the new reference value of data with the Forums of Discussion LVOOP https://forums.ni.com/t5/LabVIEW/Examples-for-New-Data-Value-Reference-with-LVOOP/td-p/1317493

    If you want to use data heavily references, I would recommend the GOOP package, which has different design questions build in singleton as etc. (which are not possible by default in LabVIEW)

  • Reading of file problem class

    I wrote an application that back up data to a file as a class of labview. The class consists of the table of waveforms and other classes. When I want to read data from the file, I get error 1527 "tried to read flattened data of a class of LabVIEW that is not currently loaded into LabVIEW".

    I tried to delete class library, because I found on the forums that it could be the cause of the problem, but it's no help. Then I put the class library, and now I get the error "end of file encountered.

    I don't know what I'm doing wrong, because I used the same approach several times and it worked fine.

    Is there another way to read data in the file? For example, if I want to know how the waveforms table is saved in the binary file I could analyze the data from file.

    I have Labview 2011.

    I'm guessing that this happens because only the class lost its changing history, so he doesn't know how to load old data. What could cause this is made to rename the class and moving to or from a library (as you found it). Replacing it does not back the history of the mutation and the only option is to go back to an older version of the class (if you have the source code control).

    Here are some relevant links, including descriptions of the flat how data are backed up, in no particular order:

    1. http://lavag.org/topic/14548-class-mutation-history
    2. http://zone.NI.com/DevZone/CDA/tut/p/ID/6316
    3. http://lavag.org/topic/13441-unflatten-from-string-on-class-Error-1527
    4. http://labviewwiki.org/LVClass_Data_Storage_Format
    5. http://digital.NI.com/public.nsf/allkb/103A235CD004CF5B862577E400752398
    6. http://zone.NI.com/reference/en-XX/help/371361H-01/lvconcepts/flattened_data/
    7. http://lavag.org/topic/9705-behaviour-when-loading-class-data-from-a-flat-binary-file
  • Life of delegate class semaphore

    Hi all

    With the help of LV2015 I have known a few frustrating behavior involving semaphore references dying in a delegate class that contains references to semaphore in the class data. I know that if the VI who created semaphores leaves memory, semaphore references will leave with her. However, I'm not sure what means "leaving the memory" when it comes to LVOOP or involuntary strange behavior on display there.
    In the example attached, I call two classes directly from top level. A class creates a semaphore reference and stores it in the class data. Lets call it owner of semaphore. The other class stores the first class in the class data after the semaphore has been initialized. Allows to call the classroom teacher. When I try to get the status of the semaphore by using the holder of the class I get error 1, invalid refnum. However, if I get the status of the semaphore using the original holder Semaphore class I don't get any error, even though the holder of the class said that the refnum of the semaphore is not valid. Is there a way to store a delegate class that has already been initialized without losing the references?

    Thank you

    jppb

    The problem is in your method of "write holder of semaphore. You will notice that the beam is not actually updating the output of class (try block diagram cleanup to see). It is a common trap.

  • Appeal of c# classes for LabVIEW instruments

    The c# programmers here in my company have developed a great c# class that contains all of the interfaces of instrument for our various test stations.  Instead of re - write all this LabVIEW code that would cause a maintainability nightmare, I want to use the class that they have created (and as an asset, tested and verified).

    I can get to all different methods, etc. so, using the .NET / LabVIEW connectivity is not a problem.  In addition, it's a matter of how exactly should I create the interop so that it is usable for our effective use of LabVIEW programmers.

    A quick description of the structure of language c#, using the Switch class for example:

    Upper level of the class has all the features of base common to all switches, and then as is normal, specific instruments have common methods in their breast and a few additional methods specific to this model.

    They use the Ifactory model for all this.

    Now I can be reading too far into this, or perhaps not far enough.

    I know that when we create classes in BT we can do a general change of class, and then have children of this class of specific instruments. In my case, I duplicated their structure and I all methods of higher level in a class of 'Switch', then a folder of children of switch has classes for each of the classes of children. I then put in place so that the child class inherits from the parent for each child.  All this with the intention of using dynamic dispatching.

    My first question is: who don't already be managed in c# code?  By calling the method of the parent class, wouldn't not on the c# code to take the correct child?  Or is it since I was using just the class, but not all of the air capacity of c# (I'm NOT an expert in c# if it isn't obvious now) I'm having to manage the dynamic send in LabVIEW?

    How exactly should I do after I have integrated LV class and configuration in pallets for future programmers? It's their programming, they know that they need a function from a specific switch, so they put that and by plugging in this interface of method, the class switch, it automatically performs the dynamic send call in the class (in fact, I typed, it made sense).  What I was wondering, is that we are so concerned about the adaptability / changability; We have a proverb which says that if Exchange you an equivalent switch in, it should work without having to re - write the code.  So of course, I am writing for this purpose.  Again, as I write this, I find to say to me, 'If you must use a particular method to pass type, because it is what is needed, then would still have an equivalent switch, with this same ability of method.

    I know I have rambled on this, but these are the roadblocks which my mind throw out there that I have create the method interfaces.

    Did anyone done something like this before? Is there an example that you could send me or tell me?  I can't believe I'm the first to try to take advantage of c# code that has already been written. I believe that I understand the nuances of make it right.

    Thanks for reading and potentially for helping me through this. It's very appreciated.

    Dan

    You could still do the objects accessible .NET via pallets is to put them in a merger of VI - one that its content when it falls from a palette on the block diagram. You probably wouldn't want to do it for every single method, but if make you at least the major top-level classes or the available constructors in this way (or property or call node for a static class), you're going to do the hard part (finding the right assembly and class) easy.

  • How to use Labview to control the motorized turntable?

    Hello

    I am new to Labview and do a project that requires the use of labview to control the motorized turntable (XYZ axes). I need to use the Labview programming and have no idea at all. Need help, thank you very much!

    Lei,

    Everything said by others is correct and to do because they describe, at a given time. But I always approached these projects of motion control first by looking at the 'motion controller' (I hope you have a) and 'drivers' (what you need) between the computer/LabVIEW and engines decide what communications will be required for these devices and get an idea of the syntax of command and the language to use with them.  In some cases, the controller and the motor driver are integrated in a single unit. Heck, in some cases, they are even integrated with each engine.

    The motors can be the stepper motors or perhaps servomotors.

    In the case of drivers stepper (devices that provide power electronics to run the engines), many of them are run using only two control signals for digital called 'step' (a pulse train) and 'direction' (high-low level) and if it is possible to generate directly with the PC, it's an order of magnitude easier (if you have not already a library of available motion control to manage the generation of these signals and) the execution of the stepper motors) of having a "Motion Controller" between the PC and the "motor".  Engine drivers step by step usually can be configured that current engine and the size of the stage and sometimes for the other plus-moteur/driver-parameter setting. The configuration of these can be made with jumpers, switches or, for some drivers, with orders ASCII on some sort of port of communication, but in general these are values you download the installer once at the beginning and then never touch again if you do not need generally to have a full time available on their change communication path.

    In the case of the actuator drivers (once again the devices that provide power electronics to run the engines), many use a +/-10V control input analog signal, and, again, while it is possible to generate the signal directly with the PC hardware, a separate axes controller is usually much simpler and more robust.  In the case of a servo system, there is also a signal back to an encoder or resolver attached to the engine to be used by any device will exercise the motion controller in the system.  There are once again associated with the driver configuration parameters (and controller in this case, since it is part of the servo feedback loop) which must be configured at the start but once set up properly, they rarely need to be changed again.

    A movement controller which is separated from the PC often manage several drivers, and can often coordinate a movement between them. It will load the rise up/down of the engine speed as that changes. It will be followed by position of each motor. The servo system, but it will take the feedback signal and use it to adjust the speed/position/torque of the engine. The motion controller also deal with race and home or index of signals is usually on most lines of movement and provide information of the State of the switch to the PC.   To run the motor controller is then just a matter of chaining a set commands of (usually ASCII) to indicate how fast to run and how far to go (and direction) and by sending a command "do it." Then, ask you to keep track of the status of the process and the States of the switches.

    In many cases the builders of controllers of movement are a primitive way to communicate with the controllers of a PC with no additional software other than what they offer. With this you can at least have an idea of how different the controller commands and responses they produce. That you can start to build sequences of commands to perform the actions you want.

    You can then add LabVIEW to the mix and to understand how you can get it to send sequences of similar orders on the paths of communication that are available and respond intelligently to the information it receives in return for motion control.

Maybe you are looking for