Moving two motors together.
Hi all,
I'm using MID-7604 motion controller that is driving a set of motors.
I wish to move 2 motors in tandem.
Can anyone suggest links to how this is done in Labview?
Does the hardware actually implement this in parallel, or does it internally serialize it?
Is there a performance issue with doing this vs moving the motors sequentially?
Thanks,
cosmund
cosmund,
there are several ways to move two motors together. One option is to configure a vector space that contains both axes and configure your moves for a vector space. Please refer to the shipping examples (e. g. Two-Axis Vector Move with Position Monitor.vi). Axes in a vector space always start and stop at the same time.
Another option is to configure the move constraints for both axes independently and use a single instance of Start Motion.flx to start both axes at the same time. You will have to use the Axis/VS map parameter and set the Axis or Vector Space parameter to Axis Control.
The third option is to use electronic gearing. In this mode you only have to control one axis and the other one will follow with the gear ratio specified by you. Please refer to the shipping examples (e. g. Master Axis - Slave Axis Gearing.vi).
I hope that helps,
Jochen Klier
National Instruments
P. S.: If you need further information, please add the NI-Motion device type (e. g. PCI-7340) to your next post.
Similar Messages
-
Hello,
A friend asked me this, and I couldn't come up with a reasonable answer on the spot.
Is there a way to keep two windows (JFrames, JWindows, whatever) in the same location relative to one another? As in, if I move Window A, Window B comes along for the ride. I think his end goal is to have a window that contains settings and whatnot slide out from underneath the other window, but stay behind it most of the time. Just a little bit of the "drawer window" would be visible hanging out from behind the main window.
My first thought was, maybe there's a Listener for window movement events, but I couldn't find one. Then I thought maybe overriding the windows' setLocation() methods to first call the OTHER window's setLocation().. but that would only work after the user was done dragging, not during.
Anybody have any ideas?This works for me. Updates as moving. Is that what you're looking for?
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;
class Testing implements ComponentListener {
public void stub1(){
JFrame frame = new JFrame("Test");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.addComponentListener(this);
frame.setPreferredSize(new Dimension(800,400));
frame.pack();
frame.setVisible(true);
public void componentMoved(ComponentEvent e) {
System.out.println("Frame moved: "+e);
public static void main(String[] args) {
SwingUtilities.invokeLater(new Runnable() {
public void run() {
new Testing().stub1();
public void componentHidden(ComponentEvent e) {}
public void componentResized(ComponentEvent e) {}
public void componentShown(ComponentEvent e) {}
} -
How do I connect two lines together.
I have two lines at an angle but where the corner of the angle is supposed to be there is a little triangle missing. I tried joining the two lines together but when I hit join one line goes past the other.
Before Joining:
After Joining:There is no need to lock one of the paths, because you do not have to tediously select endpoints just to join paths. Doing so was necessary in Illustrator for most of its history, but it finally (decades behind other drawing programs) gained the ability to join paths at their nearest endpoints by just selecting the paths.
Undo (or cut) the unwanted join.
Black pointer: Select the left and right paths.
Join.
Alternativley, when drawing line art, it is not uncommon to set your default Graphic Style to use rounded endcaps. That negates the problem of the "missing triangle" (as you call it) appearance of coincident straight end caps.
JET -
How do I "fuse" two photos together in elements?
I would like to "fuse" two photos together; how do I do this in elements?http://[email protected]
Please amplify what you are trying to do.
Do you wish to add an object from photo A to photo B, for example? -
Hi,
I have a 13" MacBook Air Mid 2013, 128GB, 4GB RAM, 1.3 GHz, OS X 10.10 Yosemite.
When I put a folder in iCloud Drive, the folder is in iCloud Drive and on my Desktop. What I want to do is link the two folders together so when I save a file in the folder on my desktop, it puts it in the folder that's in iCloud Drive too. I hope I have explained this good enough.
Please help.
ThanksIf you own both and have admin accounts on them, yes. On the "other" computer, go to System Preferences, Sharing, and turn on File Sharing.
When the two computers are on the same network, you should see the other computer appear in your sidebar in Finder. Click it, authenticate with your admin details (from the other computer), and you now have access to its files.
Matt -
Linking two switches together.
hi Guys ,
quick question in relation to joining two switches together,
can I link a 2950 switch with a 1000 BASE-SX with a 3560G with 4 SPF ports with fibre and what pitfalls should i look out for .
Thanks in advance
KevinHello,
So you would like to connect GBIC to SFP, you need Multimode Duplex Fiber Optical cable with SC-LC connectors. If SFP to SFP you need the same cably type with LC-LC connectors.
http://www.cisco.com/en/US/products/hw/routers/ps341/prod_module_installation_guide09186a00801cc731.html
http://cisco.com/en/US/products/hw/modules/ps5455/products_data_sheet09186a008014cb5e.html
bye
FCS
Please rate me if I helped. -
Are you able to link two accounts together. For example, I have had an account for a long time, but now my husband has one as well as my son. My son is currently signed in with my account but I would like to give him his own as well as share what I have with my husband.
Thanks,
StephaneeSorry, but it is not possible to merge iTunes Store accounts. You can, however, use content from multiple iTunes Store acounts on any given system or device. You just have to authorize the device to each account. You will have to use the account though which any item was purchased for redownloading, app updates, etc.
Regards. -
Linking two computers together
Can I link two macs together so I have access to both but the other computer doesn't have access to mine?
If you own both and have admin accounts on them, yes. On the "other" computer, go to System Preferences, Sharing, and turn on File Sharing.
When the two computers are on the same network, you should see the other computer appear in your sidebar in Finder. Click it, authenticate with your admin details (from the other computer), and you now have access to its files.
Matt -
I'm kinda new to Java, but i'm trying to create a program which joins 2 files together. It works fine with .txt files, but when i try to join two .wmv files, only the one it processes first will show, though the output file will have the size of the two files together. Here's my code for joining them together:
try {
JFileChooser location = new JFileChooser();
location.showDialog(this, "Save file");
File videoout = location.getSelectedFile();
OutputStream os = new FileOutputStream(videoout);
BufferedOutputStream out = new BufferedOutputStream(os);
InputStream is = null;
BufferedInputStream in = null;
ListIterator pathsIterator = paths.listIterator();
while(pathsIterator.hasNext()) {
File part = new File(pathsIterator.next().toString());
is = new FileInputStream(part);
in = new BufferedInputStream(is);
int line;
while((line = in.read()) != -1) {
out.write(line);
in.close();
out.close();
JOptionPane.showMessageDialog(this, "Done");
} catch(IOException io) {
System.out.println("IO: " + io);
}Any idea what i'm doing wrong?
ThanksJust because you put 2 files in the same file doesn't mean some application can understand that it's 2 files in 1. Meaning, the player of the merged WMV can't know that there's 2 files and that it should play both back to back. You have to read the WMV files knowing the WMV format and then generate 1 file that combines the 2, which typically would include updating header information in the file. Java's I/O classes are not going to provide that sort of thing for you.
-
I downloaded the latest iOS7 to my iPad and then the screen went blank and would not respond. I have tried pressing the two buttons together and briefly get the Apple logo but still can not restart, the logo disappears. I have tried connecting to my iMac to restore the iPad but the device does not show up (I have an old iMac). What else can I do?
You need to be running Snow Leopard 10.6.8 at the very least in order to sync your iPad with iTunes so you could update your Mac, if it can be updated, and if you care to do so.
If that's not an option, you will have to find someone that can restore the device for you with their computer running iTunes or make an appointment at an Apple Store and ask them to restore the device for you.
I hope that you have an iCloud backup, because you will lose everything on the device when it is restored.
Snow Leopard can still be purchased in the U.S. Apple Online Store.
http://store.apple.com/us/product/MC573Z/A/mac-os-x-106-snow-leopard
Also, I would not give up on the reset technique....holding down on the sleep and home buttons at the same time until the Apple logo appears. It takes about 10-15 seconds and sometimes just a little longer to get the logo to appear. -
I am trying to add two arrays together, it does not seem as if the arrays are broken up into more than one index. I have attached my code. If the array is broken up into indexes I would like to add each corresponding index, but I think the array is all in just one index and if so I was wondering how would I break it into indexes. Thanks
Attachments:
SimpleTest x1.vi 336 KBSince you are "transposing" and later work with 1D array, I assume you want to read the first column of the file.
Why do you need a sequence stacked 5 frames deep, local variables, 5 instances of the same boolean diagram constant and 5 path conststants of which some are identical??? None of this is needed!
All you need is probably something along the lines of the following picture, which probably does something similar to what you want. Still, we are probably still jumping through too many flaming hoops. Note that the execution order is uniquely defined by the wiring alone, no sequence needed! Can you take a step back and tell us what you are actually trying to achieve with all this? How many columns are in the file? Only one?
Message Edited by altenbach on 01-27-2009 04:02 PM
LabVIEW Champion . Do more with less code and in less time .
Attachments:
AddArraysFromFile.png 13 KB -
How to blend two photos together ?
Hi Everyone,
I'm an intermediate Photoshop user and this is my first post. I'm hoping to get some advice from an advanced user to achieve the following:
1) I have two seperate images...one of a scenic background and another of a person's face. I want to place the image of the person's face on top of the scenic background and blend them together so the person's face looks like a soft silhouette on the scenic background. I want to do this in an 'artful' way where the two images blend together with real chemistry. I tried using "overlay" mode on the facial image and fiddling with its layer opacity (which I thought would work) but the results look very contrived to me. Anyone know how to do this ?
Thank you very much for your time !
JayThank you John for the quick reply. I actually excerpted the facial image fairly well and I did use a feathered edge as well as a layer style called "Outer Glow". Both of these techniques helped. I'm just looking a way for these two images to have real chemistry together. I am designing a series of sympathy cards for a memorial service and I'm looking to marry these two images together in an artful way. Are there any 3rd party filters that combine photos together in a collage like this ? Although my collage is very simple (just two images). I have attached one sample background image here if you'd like to see what it looks like. I have the image of the Woman's face already cut out on a transparent background in a .psd file. I can't seem to post a PSD file here in the forum. So, I uploaded it to a website where it can be downloaded from the following location:
Woman's Face: http://www.fileuploadcenter.com/BettyWilson-sm.psd
2nd Sample Background: http://www.fileuploadcenter.com/MystyForestPath508293.jpg
Thank you,
Jay -
Dynamically parent two layers together with expressions
In AECS6, I have an Image Layer that is using the layer directly above as a Alpha Matte. I want both layers to scale at the same time, unless a certain condition is setup where I only want the matte to scale - leaving the image at original size. Normally I'd just make a new pair of layers and only scale that, but ALL my layers are dynamically linked to eachother for another more complex effect.
I wrote a simple expression to get the current scale of the matte layer (index-1), and then calculate what this particular layer's scale should be. But the scales don't match up just right because we are dealing with percentages... not absolute values. However, if I simply parent the two layers together, it of course works.
So, I either need to find a way to turn the parenting on/off with code, like if THIS, then ParentTo(index-1), or I need to write my scaling script correctly.
Fwiw- here's that script:
if (index != 15)) {
// get the original and current scale value of the layer just above, and calculate an offset
sOrig = thisComp.layer(index-1).transform.scale.valueAtTime(0)[0];
sNow = thisComp.layer(index-1).transform.scale[0];
sOffset = value[0] + (sNow - sOrig);
[sOffset,sOffset]
} else {
// this is layer index 15, don't do anything with it
value;
Appreciate the help!Not sure what you are getting at, but the actual value ranges do not really matter in an expression. It's more likely you are eitehr having an anchor point issue or your keyframes are simply not linear. in the latter case of course a simple subtraction would not give the correct result because values would be exponential/logarithmic/whatever. You'd have to use much more complex code then to accumulate all values over time such as the great Dan Ebberts explains on his website:
http://www.motionscript.com/articles/speed-control.html
Anyway, I suppose you could always use effects rather than native transforms to scale your matte while still leaving it parented. Y' know, there is a Transform effect... That would be much simpler and also avoid the expression evaluation bogging down your system...
Mylenium -
How do I talk to someone about my account and merging two subscriptions together...Can't seem to get to any way to conversing with a human from the website.
Worst Service In the World
I just want to cancel my order and get a refund, the company MUST be corrupt because it is nearly Impossible to get what is rightfully mine. It's been 3 years.. how, sad, is that, I got other people to try too...
they steal from people... by making it impossible to talk to anyone real. -
How to join two arrays together?
I have the following type
type TVarcharArr is table of varchar(4000) index by binary_integer;I have a procedure that passes in two separate arrays as:
p_account_number in TVarcharArr,
p_product_system_code in TVarcharArrThese arrays are related (they will have the same number of elements), the contents would be as follows:
Account Number Product System Code
123 ABC
456 DEF
789 GHII can use TABLE(CAST to turn each of these arrays into a table, but how do I join these two arrays together so that they become a single table with two columns? Or if I CAST them as TABLEs, how can I join these two tables together - is there some way of using the index to facilitate the join?
Cheers
RichardYou are right, I do need to convert the arrays first to use TABLE(CAST, and I do have my concerns about the use of rownum.
Here's the test case I built to test what I'm doing, incorporating the rownum solution:
declare
type TVarcharArr is table of varchar(4000) index by binary_integer;
v_arr TVarcharArr;
v_tab tchartab := tchartab();
v_arr2 TVarcharArr;
v_tab2 tchartab := tchartab();
begin
v_arr(1) := 'ABC';
v_arr(2) := 'DEF';
v_arr(3) := 'GHI';
v_arr2(1) := '123';
v_arr2(2) := '456';
v_arr2(3) := '789';
v_tab.extend(v_arr.Count);
for i in v_arr.first .. v_arr.last
loop
v_tab(i) := v_arr(i);
end loop;
v_tab2.extend(v_arr2.Count);
for i in v_arr2.first .. v_arr2.last
loop
v_tab2(i) := v_arr2(i);
end loop;
for rec in (with w_acct as
(select rownum rn, a.column_value acol
from table(cast(v_tab as tchartab)) a
w_prod as
(select rownum rn, b.column_value bcol
from table(cast(v_tab2 as tchartab)) b
select acol,bcol
from w_acct a,
w_prod b
where a.rn = b.rn) loop
DBMS_OUTPUT.PUT_LINE ( 'rec = ' || rec.acol || '|'|| rec.bcol );
null;
end loop;
end;It does return the correct result - but can it be trusted to be consistent - does the rownum in an array suffer the same problems as the rownum from a regular select? I'm guessing it's too risky to find out.
In essence, I'm getting two arrays and I'm trying to join them together so that I can CAST them as a table. (And I know the real question is why isn't it just one array of records with two elements - but sometimes you have to work with what you're given)
Maybe you are looking for
-
Comparison of multiple column values with a single column value
I have two separate tables say Tab1 and Tab2 I want to select some datas , which is common to both the tables. In tab1 , there is a column 'STATE' and it's value is 'A' In tab2, there are multiple columns for the state, say STATE_A,STATE_B, STATE_C E
-
How do I sync my iphone with my itunes without deleting the music that I have on my iphone?
I just recently had my computer (windows) wiped because my hard drive crashed and I had to re- download itunes. When I try to sync my iphone to the new itunes I had to download, it keeps telling me my iphone doesnt recognize the new one I downloaded
-
How to go for the Log Polar Conversion of the image.
How to go for the Log Polar Conversion of the image.
-
USING APACHE STURUTS BRIDGE WITH ORACLE PORTAL FOR STRUTS - JSR 168 PORTLET
I am trying to develop a JSR - 168 compliant portlet which uses struts framework.I am using APACHE STRUTS BRIDGE to run the application in my ORACLE 10.1.4 Portal server.While doing the configuration accoring to the documentation given in URL http://
-
i downloaded java3d opengl version and when i try to compile the examples it's give these exceptions -----------------------------------------------java.lang.UnsatisfiedLinkError: no J3D in java.library.path at java.lang.ClassLoader.loadLibrary(