How to connect heidenhain L476(semi absolute) encoder to 7344

We are trying to connect a heidenhain L476 (semi absolute) encoder to the 7344 motion board,
is there  NI software to handle this?  (in this system when the power goes off you only have to move about an inch
to get a absolute reading instead of going all the way to absolute "0" ,sounds nice but doesn't make it any easier for me to set up the controller!!!)
The people at heidenhain gave me a formula but I have no experience with the ni s/w and don't know
how to approach the problem.
Thanks for your help

Got the info I needed disregard post

Similar Messages

  • How to find RPM of an absolute encoder?

    Hello guys, I am new to the labview programming and I am having a lot of difficulty trying to find the RPM of an absolute encoder. The encoder model is 960 from www.encoder.com. One of the things that I tried was counting edges and then dividing by the pulse per revolution. I believe that this only gives me the revolutions, and I am not sure how to calculate the time elapsed and use that to find the RPM of an absolute encoder. Thanks for the help.

    Hello,
    I feel that the filter will not be needed if you follow the example that Ravens Fan posted.  The RMP2.vi uses the timeout value of the DAQmx Read.vi as an input to the second divide.  Where the posted example is using a value that is wired into a Wait Until Next ms Multiple.vi.  The second divide in the calculation is outputting revolutions per ms.  Please note that is why the posted example ends by multiplying by 60,000.  Once you make these small changes to your code, you RPM output should be more constant and eliminate the need for a filter. If you are still interested in filter, please review the attached documentation.
    Smoothing Filter Coefficients
    Filter
    Samantha
    National Instruments
    Applications Engineer

  • How many connections supports a web interface with each camera and how many Adobe Encoder clients does AMS support? AMS Standart

    How many connections supports a web interface with each camera and how many Adobe Encoder clients does AMS support? AMS Standart. We need connect by  Adobe Encoder many people. what is differences between Adobe Media Server 5 Professional, Adobe Media Server 5 Standard and Adobe Media Server 5 Extended?

    For the detailed list of differences across editions refer this link
    http://www.adobe.com/in/products/adobe-media-server-family/buying-guide-comparison.html

  • Generating a 6X Sine Wave using an absolute encoder

    How do I get an Analog Signal Generation Synchronized to six times the frequency of an absolute nine bit parallel encoders output with adjustable phase relation. I am using a PXI-6533, a PXI-6711 and have available a PXI-6070E.
    Now the long version of the problem. I have a 9-bit absolute encoder connected to a motor shaft (up to 420Hz). From the encoders 9-bit (0-511) parallel signal I need to create a synchronized 6X sine wave (up to 2500Hzwith an adjustable phase relation. Picture an electronic timing chain. For every cycle of the encoder, I need to produce six full sine wave cycles with a variable tuned phase shift. I have LabView 7 w/RT.
    I have tried to use the Update Clock (PFI5) to step through a buf
    fer but it seems to drop an update every so often. I also have tried to monitor the bit-0 line to determine freq. and scaled the update rate accordingly but the phase shifts all over the place. Does anyone have any ideas on the matter ? I would really appreciate it! Thanx….Phil

    Phil,
    Another different option to solve your application would be to use the new LabVIEW FPGA module and the 7831R reconfigurable I/O hardware. Using these tools you can configure the FPGA on the board to generate the sine wave based on the 9-bit parallel input. The most simple setup would be to have a lookup table in the FPGA that has a corresponding output value to each of the 512 possible input values. This 512 sample table would contain 6 cycles of a sine wave. Every time the parallel input changes the analog output value would be updated accordingly from the lookup table. This setup would also allow to easily add a phas
    e shift of the output by shifting the point in the lookup table you are reading by a known constant.
    Christian L
    NICS
    Christian Loew, CLA
    Principal Systems Engineer, National Instruments
    Please tip your answer providers with kudos.
    Any attached Code is provided As Is. It has not been tested or validated as a product, for use in a deployed application or system,
    or for use in hazardous environments. You assume all risks for use of the Code and use of the Code is subject
    to the Sample Code License Terms which can be found at: http://ni.com/samplecodelicense

  • How to connect to and communicate with an SQLite database in AIR/Flex

    Hey guys,
    I recently decided I would try programming a vocabulary-training program in AIR, so I could use it on Linux as well. I got stuck pretty soon. I am trying to connect to a local SQLite database and I obviously fail epically. Posting the source code of the application here:
    <?xml version="1.0" encoding="utf-8"?>
    <mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
       <mx:Script>
          <![CDATA[  
               import flash.filesystem.File;
              import flash.data.*;
             import mx.controls.Alert; 
                      private var dbFile:File;
                   private var conn:SQLConnection;
                   // -- AUTO INIT FUNCTIONS --------------------------------------------------- /
                   private function init():void {
                        // Create a File Reference to the Included DB
                        dbFile = File.applicationDirectory.resolvePath( "../slovniky.db" );
                        // Create SQL Connection
                        conn = new SQLConnection();
                        // Event Listener that will tell us when the DB is opened
                        conn.addEventListener(SQLEvent.OPEN, openSuccess);
                        // Event Listener that will tell us if an error occurs
                        conn.addEventListener(SQLErrorEvent.ERROR, openFailure);
                   // -- EVENT HANDLERS -------------------------------------------------------- /
             private function starter() :void {
                  slovickoEn.enabled = true;
                  nazor.enabled = true;
                  odeslat.enabled = true;
                  zrusit.enabled = true;
                  start.enabled = false;
                  // Otevírám spojení s databází v asynchroním módu
                   conn.openAsync( dbFile );
             private function openSuccess( event:SQLEvent ):void {
                        // Pokud se spojení povede!
                        Alert.show("Spojení se zdařilo!");
               private function openFailure( event:SQLEvent ):void {
                        // Pokud spojení selže!
                        Alert.show("Spojení se nezdařilo!")
             private function kontrola() : void {
                  if (nazor.text != "") {
                       if (nazor.text == "Pes") {
                       Alert.show("Správně!");    
                       else {
                       Alert.show("Špatně!! " + "Napsané slovíčko bylo " + nazor.text);     
          ]]>   
       </mx:Script>
       <mx:VBox width="400" height="200"
                   horizontalCenter="0" verticalCenter="0" backgroundColor="#FFFFFF"
                   paddingBottom="20" paddingLeft="20" paddingRight="20" paddingTop="20"
       >
          <mx:HBox width="100%" verticalAlign="middle" horizontalAlign="center">
             <mx:Label text="Anglicky:"/>
             <mx:TextInput id="slovickoEn" editable="false" text="Dog" enabled="false"/>
          </mx:HBox>
          <mx:HBox width="100%" verticalAlign="middle" horizontalAlign="center">
             <mx:Label text="Česky:"/>
             <mx:TextInput id="nazor"  enter="kontrola()" enabled="false"/>
          </mx:HBox>
          <mx:HBox width="100%" horizontalAlign="center">
             <mx:Spacer width="50" height="10"/>
             <mx:Button id="odeslat" label="Odeslat" color="#0D8401" click="kontrola()" enabled="false"/>
             <mx:Button id="zrusit" label="Zrušit" color="#0D8401" enabled="false"/>
          </mx:HBox>
          <mx:HBox width="100%" horizontalAlign="center">
             <mx:Spacer width="50" height="10"/>
             <mx:Button id="start" label="Start" color="#0D8401" click="starter()" enabled="true"/>
          </mx:HBox>
       </mx:VBox>
    </mx:WindowedApplication>
    The Run of the program tells me this:
    TypeError: Error #1009: Cannot access a property or method of a null object reference.
         at pes/starter()[C:\air\projects\pes\src\pes.mxml:45]
         at pes/__start_click()[C:\air\projects\pes\src\pes.mxml:93]
    I would appreciate any help or a how-to. I am an absolute beginner with some experience from HTML, CSS, PHP and rarely JS. What am I doing wrong? File attached for easier manipulation as well.
    Erthy

    Hi,
    Here is the complete example for the same with the code.Let me know if you have any issue with this.
    http://shardulbartwal.wordpress.com/2008/04/14/adobe-air-and-sqlite-connectivity/
    with Regards,
    Shardul Singh Bartwal

  • Use absolute encoder to get positioning

    Hi all friends, 
    i am relatively new in labview, and sorry in advance if i ask something very silly. 
     i am writing this to seek help for absolute encoder data acquisition. 
    The DAQ set i am using is NI USB-6218 BNC which has 8 digital inputs. 
    The absolute am using is ACE 128, data sheet is http://www.bourns.com/pdfs/ace.pdf
    I am connecting the 8 output pins of the encoder to the 8 digital input pin P0.0-0.8 
    and then i am using  DAQ Assitant 8 times he input and then convert it to decimal numbers and save it to a text file. 
    attached is what i have. 
    it seems that it works well, but however when i look through the text file, i found that there are a lot of errors in the decimal numbers. 
    can anybody help me to figure out why it happens??
    Thank you very much 
    Attachments:
    EIM sem 5.vi ‏447 KB

    melvinfeng wrote:
    Hi all friends, 
    i am relatively new in labview, and sorry in advance if i ask something very silly. 
     i am writing this to seek help for absolute encoder data acquisition. 
    The DAQ set i am using is NI USB-6218 BNC which has 8 digital inputs. 
    The absolute am using is ACE 128, data sheet is http://www.bourns.com/pdfs/ace.pdf
    I am connecting the 8 output pins of the encoder to the 8 digital input pin P0.0-0.8 
    and then i am using  DAQ Assitant 8 times he input and then convert it to decimal numbers and save it to a text file. 
    attached is what i have. 
    it seems that it works well, but however when i look through the text file, i found that there are a lot of errors in the decimal numbers. 
    can anybody help me to figure out why it happens??
    Thank you very much 
    im confused when you say...."I am connecting the 8 output pins of the encoder to the 8 digital input pin P0.0-0.8", thats not truly a correct statement?
    8 inputs is a port( line0:7)....
    look for the example in the \examples\DAQmx\Digital Input\Digital - SW-Timed Input.vi (change the example data format to decimal output)
    and i dont know if you want to write the data continuous or only when changed to the file?
    Attachments:
    Digital - SW-Timed Input.png ‏18 KB

  • Satellite A200 - How to connect to TV?

    Hi, Dear.
    How I connect my laptop to tv with S-video Media Cable or VGA-RGB cable? I tried to connect by Fn+F5 but no signal comes out. If I use VGA -RGB cable something is comeing out on TV but its scrolling continuously .
    Kindly assist me..

    Hi
    You can use both cables to connect your notebook to TV. Its depending on the interfaces on notebook and TV but in both cases its the same:
    Connect the cable to notebook and TV, power on your TV and select the right channel and then power on your notebook. After boot procedure you can switch with FN+F5 between monitors.
    If you use S-Video cable make sure that you are using the right television encoding system, e. g. PAL or NTSC.
    > If I use VGA -RGB cable something is coming out on TV but its scrolling continuously .
    What settings did you use (screen resolution, screen refresh rate, etc.)

  • How do I use daqmx to get encoder direction/count on E-series board?

    Hardware:
    PCI-6014
    Labview 7.1
    I have a linear actuator and wish to get distance/direction.  The
    motor has a quad encoder with phase A and B only.  I connected the
    lines according the the E-series, PFI-8 and PFI-6, and ground to
    digital ground. I then attempted to design a control with daqmx but
    failed.  I have tried the daqmx examples but none were attempting
    a reverse in direction.  Most examples given for direction change
    are for traditional daq control; i cant make a correlation on what to
    use to substite traditional daq with daqmx vi's. 
    2 questions:
    How do I use daqmx to get encoder direction/count on E-series board?
    Are there low pass filter vi's recommended for each phase connection to stabilize data?
    Thanks,
    Wayne Hilburn

    Hello Wayne,
    Take a look at the Count Digital Events.vi shipping example.  You can find this in LabVIEW by selecting Help >> Find Examples... then browsing to Hardware Input and Output >> DAQmx >> Counter Measurements >> Count Digital Events.
    If you set the "Count Direction" control to "Externally Controlled", you will be able to count up and down depending on which direction you rotate your encoder.  Make sure you wire Phase A to Ctr0 Source and Phase B to P0.6.  P0.6 is the up/down line for counter 0.
    I hope this helps.  Please let me know if you have any further questions.
    Regards,
    Sean C.

  • How to Connect Airport Express to Existing Wireless Network (Client Mode)

    I am posting this for everyone tearing their hair out trying to connect the Airport Express to your own existing home wireless network. After spending 2 hours last night installing this on my father-in-law's home network, I hope to be able to save someone else the agony we went through.
    So here's the situation:
    Say you already have your own home network set up, and all you want is to be able to use AirTunes to play music off iTunes into your speaker system. And, you don't need the printer sharing capability nor creation of another wireless network (2 of the features of Airport Express). Then this solution is for you - read on.
    Unfortunately, Apple's user manual is very unclear how to connect Airport Express to your own network. When you look at the picture diagram they provide, they show Airport Express picking up its signal from another Apple-oriented base. This can make you think you need to buy another piece of hardware to make it work. DON'T If you read through the manual, the Support section here, etc., you will hear lots of talk about "Client Mode" - and that this is the only way to get it to work. Nice - but no one really tells you how to set up the Airport in client mode.
    Do yourself a favor, toss that user manual aside and run these steps.
    (Note: These directions assume your DSL/Cable Modem is hooked up to a wireless router or acts as its own wireless router)
    1. Get a cat5 Ethernet cable (anything but an orange cable - that's a crossover cable) like you would use to connect your PC to your router to pick up the Internet.
    2. Connect the Ethernet cable to the router on one end, and to the Airport Express unit on the other end.
    3. Plug in your Airport Express unit to the wall (this will not necessarily become its permanent location - you will be able to move it later). The light will glow solid Amber for about 30-45 seconds while it starts up, then blink Amber. At this point, the unit is ready to operate.
    4. Install the CD to the PC where your iTunes music is stored. This should be painless. Once you open the program, it should detect the Airport unit.
    5. At this point, the on-screen wizard will present you with your options, and walk you through the setup. This is much like the user manual describes - and you should be good to go form here forward.
    Some pointers:
    - When asked if you want to create a new network, join an existing network, or connect via Ethernet, choose the middle option for joining an existing network. You will need to know the name of your network, the password to connect to the network (if present), and the type of encryption used on the network (e.g. WEP, WPA, etc.). Side note, WPA is recommended, as it is a higher level of security than WEP. You will be able to configure the Airport Express unit to automatically login to your network.
    - I would recommend, when creating a password for the Airport Express unit, use the same password as your network, to avoid confusion.
    6. The very last step will ask you to save the settings to the Airport Express. Here's the kicker - when you save the settings, you are TRICKING the Airport Express into no longer acting as a network broadcaster, but instead being a "slave" to your own network. What do I mean? You will lose the connection from your PC to the Airport Express - an error message will pop up telling you the unit can no longer be found. While you might think you did something wrong, you actually were successful!
    7. Unplug your Airport Express, and disconnect the Ethernet cable from your router and the Airport unit. This will no longer be needed.
    8. Go to your desired location where you want to plug in your Airport Express unit. Before plugging it in, connect your Audio cable from the Airport Express to your audio receiver. Once that is connected, then plug in the Airport Express unit. The light will glow solid Amber for 30-45 seconds while it loads, and then will blink Amber for a brief period of time before turning solid GREEN. When this happens, you have successfully connected the Airport Express to your home network!
    9. Go back to your PC with iTunes. Open the Airport software - you should now have a listing for your Airport Express unit in the upper left. Click on this, and the wizard will guide you through connecting - you will need the password you created for the unit. You only need to go through this wizard once, and when finished, the software will tell you that can now use iTunes with your Airport unit.
    10. Open iTunes. On the lower right, you will see a dropdown for Speakers, and it should be defaulted to My Computer. Click on that drop-down, and you will see the name of your Airport unit. Click on that name, and now your music will broadcast to the Airport unit!
    11. Play a song in iTunes. Go to your audio receiver, and connect it to the channel for your external connection to the Airport Express unit. You should hear your music from iTunes. CONGRATULATIONS! =)
    I hope these instructions were helpful - I am happy to answer any questions, so feel free to contact me, *******************@*****.**.
    <Edited by Moderator>

    Thanks for the detailed directions. You are absolutely correct in stating that people should toss the user manual; it's pretty worthless. I have had a problem setting up my new Airport Express as I have described in an earlier post - http://discussions.apple.com/thread.jspa?threadID=1839873&tstart=45
    One quick question - does using your setup process set the AE up as part of a distributed network where the AE is acting as a wireless router where it is extending the range of your network? Or, is it simply a wireless connection to your stereo for iTunes? I am interested in having both, since my AE will be at the other end of the house from the main wireless router.
    Thanks

  • How to connect multiple Xserve Raid for Best Performance

    I like to get an idea how to connect multiple Xserve Raid to get the best performance for FCP to do multiple stream HD.

    Again, for storage (and retrieval), FireWire 400 should be fast enough. If you are encoding video directly to the external drive, then FireWire 800 would probably be beneficial. But as long as the processing of the video is taking place on the fast internal SATA drive, and then you are storing files on the external drive, FireWire 400 should be fine.
    Instead of speculating about whether it will work well or not, you need to set it up and try your typical work flow. That is the only way you will know for sure if performance is acceptable or not.
    For Time Machine, you should use a single 1.5TB drive. It is likely that by the time your backup needs comes close to exceeding that space, you will be able to buy a 3TB (or larger) single drive for the same cost. Also, I would not trust a RAID where the interaction between the two drives is through two USB cables and a hub. If your primary storage drive fails, you need your backup to be something that is simple and reliable.
    Oh, and there should be no problem with the adapter, if you already have it and it works.
    Edit: If those two external drives came formatted for Windows, make sure you have use Disk Utility Partition tab to repartition and reformat the drive. When you select the drive in the Disk Utility sidebar, at the bottom of the screen +Partition Map Scheme+ should say *GUID Partition Table*. When you select the volume under the drive in the sidebar, Format should say *Mac OS Extended (Journaled)*.

  • Hibernate query...how to connect two databases...

    hi i m new to hibernate..
    i created two tables..
    1st table is catalog:
    2nd table is acctinfo
    //HBM file is :
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
    <hibernate-mapping>
    <class name="hibernate.example.Catalog" table="catalog">
    <id name="id" type="integer" column="ID">
    <generator class="increment"/>
    </id>
    <property name="journal" type="string" column="JOURNAL"/>
    <property name="publisher" type="string" column="PUBLISHER"/>
    <property name="edition" type="string" column="EDITION"/>
    <property name="title" type="string" column="TITLE"/>
    <property name="author" type="string" column="AUTHOR"/>
    <bag name="accinfo" cascade="all" >
    <key column="ID"/>
    <one-to-many class="hibernate.example.Acctinfo"/>
    </bag>
    </class>
    <class name="hibernate.example.Acctinfo" table="acctinfo">
    <id name="id" type="integer" column="ID">
    <generator class="increment"/>
    </id>
    <property name="account" type="string" column="ACCOUNT"/>
    <property name="password" type="string" column="PASSWORD"/>
    <property name="balance" type="string" column="BALANCE"/>
    </class>
    </hibernate-mapping>
    ///******************getter setter file is::****************
    package hibernate.example;
    public class Acctinfo
         int id;
         String account;
         String password;
         String balance;
         public Acctinfo()
         public void setId(int id)
              this.id = id;
         public int getId()
              return id;
         public void setAccount(String account)
              this.account = account;
         public void setPassword(String password)
              this.password = password;
         public void setBalance(String balance)
              this.balance = balance;
         public String getAccount()
              return account;
         public String getBalance()
              return balance;
         public String getPassword()
              return password;
    //********************2nd getter setter file is:***********************
    package hibernate.example;
    import java.util.List;
    public class Catalog
    int id;
    String journal;
    String publisher;
    String edition;
    String title;
    String author;
    private List accinfo;
    public Catalog()
    public void setId(int id)
    this.id = id;
    public int getId()
    return id;
    public void setJournal(String journal)
    this.journal = journal;
    public String getJournal()
    return journal;
    public void setPublisher(String publisher)
    this.publisher = publisher;
    public String getPublisher()
    return publisher;
    public void setEdition(String edition)
    this.edition = edition;
    public String getEdition()
    return edition;
    public void setTitle(String title)
    this.title = title;
    public String getTitle()
    return title;
    public void setAuthor(String author)
    this.author = author;
    public String getAuthor()
    return author;
    public void setAccinfo(List accinfo)
    this.accinfo = accinfo;
    public List getAccinfo()
    return accinfo;
    * To change this template, choose Tools | Templates
    * and open the template in the editor.
    package hibernate.example;
    import hibernate.example.Acctinfo;
    import hibernate.example.Catalog;
    import java.util.ArrayList;
    import java.util.Iterator;
    import java.util.List;
    import java.util.ListIterator;
    import org.hibernate.Query;
    import org.hibernate.SQLQuery;
    import org.hibernate.Session;
    import org.hibernate.SessionFactory;
    import org.hibernate.Transaction;
    import org.hibernate.cfg.Configuration;
    public class CatalogClient
         Session session = null;
         SessionFactory sessionFactory = new Configuration().configure().buildSessionFactory();
         public static void main(String str[])
              CatalogClient clc = new CatalogClient();
              //clc.saveData();
              //clc.deleteData();
              //clc.showData();
              clc.updateData();
         public void showData()
              try
                   session =sessionFactory.openSession();
                   String SQL_QUERY ="select id, journal, publisher, edition, title, author from catalog";
                   // String SQL_QUERY ="select c.ID, c.JOURNAL, c.PUBLISHER, c.EDITION, c.TITLE, c.AUTHOR, a.ACCOUNT, a.PASSWORD,a.BALANCE from catalog c, ACCTINFO a where c.ID = a.ID";
                   SQLQuery query = session.createSQLQuery(SQL_QUERY);
                   System.out.println("*** query : *** "+ query);
                   //for(ListIterator it=query.list().listIterator();it.hasNext();)
                   for (ListIterator lit = query.list().listIterator(); lit.hasNext();)
                        Object[] row = (Object[]) lit.next();
                        /*System.out.println("ID: " + row[0]);
                        System.out.println("Title: " + row[1]);
                        System.out.println("Author: " + row[2]);
                        System.out.println("Isbn: " + row[3]);
                        System.out.println("Pages: " + row[4]);
                        System.out.println("Copyright: " + row[5]);
                        System.out.println("Cost: " + row[6]);
                        System.out.println("******NEXT****************");
    Object[] row = (Object[]) it.next();*/
                        System.out.println("ID: " + row[0]);
                        System.out.println("JOURNAL: " + row[1]);
                        System.out.println("PUBLISHER: " + row[2]);
                        System.out.println("EDITION: " + row[3]);
                        System.out.println("TITLE: " + row[4]);
                        System.out.println("AUTHOR: " + row[5]);
                        System.out.println("acc: " + row[6]);
                        System.out.println("pass: " + row[7]);
                        System.out.println("bal: " + row[8]);
                        System.out.println("***************************");
                   session.close();
              catch(Exception e)
                   System.out.println(e.getMessage());
         public void saveData()
              session =sessionFactory.openSession();
              Transaction transaction = null;
              transaction = session.beginTransaction();
              Catalog catalog = setBean();
              //System.out.println("before save");
              session.save(catalog);
              //System.out.println("after save");
              transaction.commit();
              session.flush();
              session.close();
         public void updateData()
              session =sessionFactory.openSession();
              Catalog catalog = new Catalog();
              catalog.setId(2);
              catalog.setAuthor("manoj");
              catalog.setJournal("java");
              catalog.setEdition("1st");
              catalog.setPublisher("indiabulls");
              catalog.setTitle("java Servlet");
              session.update(catalog);
              session.flush();
              session.close();
         public void deleteData()
              session =sessionFactory.openSession();
              Catalog catalog = new Catalog();
              catalog.setId(3);
              session.delete(catalog);
              session.flush();
              session.close();
         public static Catalog setBean()
              Acctinfo accinfo = new Acctinfo();
              accinfo.setAccount("MANOJ1");
              accinfo.setPassword("orbis");
              accinfo.setBalance("1000");
              List list = new ArrayList();
              list.add(accinfo);
              Catalog catalog = new Catalog();
              catalog.setJournal("india");
              catalog.setPublisher("indiabulls");
              catalog.setEdition("ist");
              catalog.setTitle("orbis");
              catalog.setAuthor("manoj");
              catalog.setAccinfo(list);
              return catalog;
    //********************CFG FILE IS ******************
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
    <hibernate-configuration>
    <session-factory name="session">
    <property name="hibernate.dialect">org.hibernate.dialect.Oracle9Dialect</property>
    <property name="hibernate.connection.driver_class">oracle.jdbc.driver.OracleDriver</property>
    <property name="hibernate.connection.url">jdbc:oracle:thin:@172.16.31.25:1521:BOMBAY</property>
    <property name="hibernate.connection.username">mumbai</property>
    <property name="hibernate.connection.password">mumbai123</property>
    <!-- Set AutoCommit to true -->
    <property name="connection.autocommit">true</property>
    <property name="dialect">org.hibernate.dialect.OracleDialect</property>
    <!-- Mapping files -->
    <mapping resource="Catalog.hbm.xml"/>
    </session-factory>
    </hibernate-configuration>
    **********************error i m facing is :************************
    0 [main] WARN net.sf.ehcache.config.Configurator - No configuration found. Configuring ehcache from ehcache-failsafe.xml found in the classpath: jar:file:/C:/Documents%20and%20Settings/d.poonam/Desktop/hibernate/lib/ehcache-1.1.jar!/ehcache-failsafe.xml
    1188 [main] WARN org.hibernate.impl.SessionFactoryObjectFactory - Could not bind factory to JNDI
    javax.naming.NoInitialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
         at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
         at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
         at javax.naming.InitialContext.getURLOrDefaultInitCtx(Unknown Source)
         at javax.naming.InitialContext.getNameParser(Unknown Source)
         at org.hibernate.util.NamingHelper.bind(NamingHelper.java:52)
         at org.hibernate.impl.SessionFactoryObjectFactory.addInstance(SessionFactoryObjectFactory.java:90)
         at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:247)
         at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1043)
         at hibernate.example.CatalogClient.<init>(CatalogClient.java:24)
         at hibernate.example.CatalogClient.main(CatalogClient.java:27)
    please help me out....
    thanks in advance..
    if u know how to connect two tables plz let me know..
    its urgent....

    I made this work with MySQL. Adapt to your situation as needed. - %
    package hibernate.model;
    import hibernate.util.HibernateUtils;
    import hibernate.model.Catalog;
    import hibernate.model.Account;
    import org.apache.commons.logging.Log;
    import org.apache.commons.logging.LogFactory;
    import org.hibernate.Session;
    import hibernate.util.HibernateUtils;
    import static junit.framework.Assert.assertEquals;
    import static junit.framework.Assert.assertNotNull;
    public class CatalogTest
       private static final Log LOGGER = LogFactory.getLog(CatalogTest.class);
       public static void main(String[] args)
          Session session = null;
          try
             session = HibernateUtils.getSessionFactory().getCurrentSession();
             session.beginTransaction();
             int rowsBefore = HibernateUtils.getRowCount(session, Catalog.class);
             assertEquals("should not have any Catalogs", rowsBefore, 0);
             Catalog catalog = new Catalog("test title");
             catalog.addAccount(new Account(100));
             catalog.addAccount(new Account(200));
             Long id = (Long) session.save(catalog);
             assertNotNull("generated id should not be null", id);
             LOGGER.info("returned id: " + id);
             session.getTransaction().commit();
             LOGGER.debug("transaction committed");
          catch (Exception e)
             LOGGER.error(e);
             session.getTransaction().rollback();
    package hibernate.model;
    import java.io.Serializable;
    import java.text.NumberFormat;
    public class Account implements Serializable
       private Long id;
       private int balance;
       public Account()
          this(null, 0);
       public Account(int balance)
          this(null, balance);
       public Account(Long id, int balance)
          this.id = id;
          this.balance = balance;
       public Long getId()
          return id;
       private void setId(Long id)
          this.id = id;
       public int getBalance()
          return balance;
       private void setBalance(int balance)
          this.balance = balance;
       public boolean equals(Object o)
          if (this == o)
             return true;
          if (!(o instanceof Account))
             return false;
          Account account = (Account) o;
          return !(id != null ? !id.equals(account.id) : account.id != null);
       public int hashCode()
          int result;
          result = (id != null ? id.hashCode() : 0);
          result = 31 * result + balance;
          return result;
       public String toString()
          return new StringBuilder().append("Account{").append("id=").append(id).append(", balance=").append(NumberFormat.getCurrencyInstance().format(balance)).append('}').toString();
    <?xml version="1.0"?>
    <!DOCTYPE hibernate-mapping PUBLIC
          "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
          "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
    <hibernate-mapping package="hibernate.model" default-access="field" default-lazy="true">
       <class name="Account" table="accounts">
          <id name="id" column="account_id">
             <generator class="native"/>
          </id>
          <property name="balance" column="balance"/>
       </class>
    </hibernate-mapping>
    package hibernate.model;
    import java.io.Serializable;
    import java.util.Set;
    import java.util.HashSet;
    import java.util.Collections;
    public class Catalog implements Serializable
       private Long id;
       private String title;
       private Set<Account> accounts;
       public Catalog()
          this(null, "", Collections.EMPTY_SET);
       public Catalog(String title)
          this(null, title, Collections.EMPTY_SET);
       public Catalog(Long id, String title, Set<Account> accounts)
          this.id = id;
          this.title = title;
          this.accounts = new HashSet<Account>(accounts);
       public Long getId()
          return id;
       private void setId(Long id)
          this.id = id;
       public String getTitle()
          return title;
       private void setTitle(String title)
          this.title = title;
       public Set<Account> getAccounts()
          return accounts;
       private void setAccounts(Set<Account> accounts)
          this.accounts = accounts;
       public void addAccount(Account account)
          this.getAccounts().add(account);
       public void removeAccount(Account account)
          this.getAccounts().remove(account);
       public boolean equals(Object o)
          if (this == o)
             return true;
          if (!(o instanceof Catalog))
             return false;
          Catalog catalog = (Catalog) o;
          return !(id != null ? !id.equals(catalog.id) : catalog.id != null);
       public int hashCode()
          return (id != null ? id.hashCode() : 0);
       public String toString()
          return new StringBuilder().append("Catalog{").append("id=").append(id).append(", title='").append(title).append('\'').append(", accounts=").append(accounts).append('}').toString();
    <?xml version="1.0"?>
    <!DOCTYPE hibernate-mapping PUBLIC
          "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
          "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
    <hibernate-mapping package="hibernate.model" default-access="field" default-lazy="true">
       <class name="Catalog" table="catalogs">
          <id name="id" column="catalog_id">
             <generator class="native"/>
          </id>
          <property name="title" column="title"/>
          <set name="accounts" cascade="all">
             <key column="catalog_id"/>
             <one-to-many class="hibernate.model.Account"/>
          </set>
       </class>
    </hibernate-mapping>
    <!DOCTYPE hibernate-configuration PUBLIC
         "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
         "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
    <hibernate-configuration>
         <session-factory>
          <property name="connection.driver_class">com.mysql.jdbc.Driver</property>
          <property name="connection.url">jdbc:mysql://localhost:3306/hibernate?autoReconnect=true</property>
          <property name="connection.username">hibernate</property>
          <property name="connection.password">hibernate</property>
          <property name="connection.pool_size">1</property>
          <property name="dialect">org.hibernate.dialect.MySQL5InnoDBDialect</property>
          <property name="show_sql">true</property>
          <property name="generate_statistics">true</property>
          <property name="query.factory_class">org.hibernate.hql.classic.ClassicQueryTranslatorFactory</property>
          <property name="cache.provider_class">org.hibernate.cache.NoCacheProvider</property>
          <property name="cache.use_minimal_puts">false</property>
          <property name="cache.use_query_cache">false</property>
          <property name="order_updates">false</property>
          <property name="hbm2ddl.auto">create-drop</property>
          <property name="current_session_context_class">thread</property>
          <mapping resource="hibernate/persistence/hibernate/Account.hbm.xml"/>
          <mapping resource="hibernate/persistence/hibernate/Catalog.hbm.xml"/>
         </session-factory>
    </hibernate-configuration>

  • Using cRIO-9024 serail port can I read the data from AFM60 absolute encoder, multiturn, SSI interface

    I would like to request you to kindly address the following quarries.
    1. Using cRIO-9024 serial port, can I read or write data from AFM60 absolute encoder, multi-turn, SSI interface (please see the attachment for detail information about the encoder)?
    2. Which type of encoder interface (SSI, TTL/HTL) is compatible with the serial port connection of cRIO-9024 controller?
    3. Are there any limitation on choosing the output frequency and resolution (pulses per step) of the encoder? If the answer are yes, what are the suitable ranges of frequency and resolution?
    Looking forward to your kind reply. Thanking you.
    Regards
    Shantanu
    Attachments:
    afs60_afm60_english.pdf ‏2298 KB

    Hi Shantanu,
    To read and write data from the serial port on a cRIO you access the serial port as a VISA resource, there are serial VISA VIs to read and write data on the serial port.
    If you look under the Hardware Input and Output folder in the NI Example Finder, you should find a Serial folder, this contains examples for serial communication.
    The serial interfaces on cRIO devices use the RS232 standard, unfortunately as SSI is based on the RS422 standard, you won't be able to directly interface the encoder to the serial port as they are not compatible. You would have to either use a separate interface between the devices or use a digital input module in your cRIO to directly process the encoder data.
    To answer your question about frequency, the maximum baud rate for the serial port on the 9072 as listed here is 115200 bps, so this would be the maximum raw data transfer rate for any connected device, the number of steps for your particular encoder is limited by the maximum shaft speed as detailed in its specification. 
    I hope this is helpful to you, feel free to ask further questions and I'll do my best to answer them.
    Regards,
    Adam Brown
    Applications Engineer
    National Instruments UK

  • "How to forward from a struts form to a login page?"or "how to connect form

    Can Any boby please let me know
    "How to forward from a struts form to a login page?"or "how to connect form to login session id"?
    Thanks
    Shailajakrishna

    I believe I can not use a
    request.sendRedirectURL("....") in which I would
    encode all my parameters, because:Righto. This is a bit tricky.
    Basically, you have two options, and both of those are a little nasty.
    1) You could use and intermediate JSP page. Just dispatch you request to that page, use the attributes to construct a form with hidden fields, and use Javascript to POST that form to your intended URL on the document's BODY onload event. Would work, but wouldn't be pretty and requires you to use JSPs and Javascript. Still an idea.
    2) This is something that I wouldn't recommend. Open a socket to the URL you you want to post your data. Manually construct a HTTP POST request, encoding your parameters into the headers. Read and parse the response & modify your HttpServletResponse object accordingly.
    Take a look at i.e. http://javaalmanac.com/egs/java.net/PostSocket.html?l=new for some pointers.
    I'd go with item #1.
    For my own edification, I'd be also interested in
    knowing why such a function does not exist in the
    current httpServletRequest api.I suppose it's a little out of scope. Servlets were ment to interoperate inside one container, not across domains and different implementations.
    I'm guessing I must be missing something fundamentals
    maybe?No, you're not.
    .P.

  • NI-9514 with external absolute encoder

    Hi All,
    I'd like to use a NI-9514 (Servo Module) through the FPGA interface, but I don't want to connect my encoder directly to the module : My encoder is an absolute encoder decoded through a dedicated cRIO module.
    My idea was to implement my own position control loop on FPGA (based on my absolute position) and send the computed torque setpoint (0-10V) to the 9514, but it seems that the 9514 embeddeds its own Position Loop (based on the encoder connected to the connector). As I won't have any encoder connected to the 9514, my idea is not possible....
    My 2 questions are the following:
    - Is my conclusion right?
    - Is there any way to disable the PID loop on the 9514 module, and use the 9514 as a simple open loop torque générator (0-10V génération) ?
    Thanks for your answer.
    Cordialement,
    Raphael T

    Hi Raphael,
    When you use the 9514 in FPGA mode, the position loop on the module is automatically disabled. 
    I agree that the documentation terms aren't the best. Position loop mode is when the position loop is running on the 9514. You send the 9514 position setpoints and it generates a torque output. This mode is not accessible from FPGA.
    Torque loop mode is when no position loop is running on the 9514. You can run in this mode by using the 9514 in FPGA mode or by using it in scan mode and unchecking the "Run Position Loop on Hardware" button in the axis configuration settings. Note that torque loop mode does not imply that the torque loop is running on the 9514; the torque loop is always running on the drive.
    Thanks,
    Paul B.
    Motion Control R&D

  • How to connect to weblogic?

    I have an ADF web applicaton which contains 2 projects, Model and ViewController.
    I create another project named Build and it has a xml file, ojdeploy-build.xml.
    However, how to connect to weblogic domain in ojdeploy-build.xml?
    ---------------------ojdeploy-build.xml--------------------
    <?xml version="1.0" encoding="US-ASCII" ?>
    <!-- Defines default parameters for all deploy tasks.
    Also defines some variables strictly for use within this file
    in macros
    -->
    <ojdeploy-build>
    <deploy>
    <parameter name="workspace" value="E:\SOAworkspace\otnapp\otnapp.jws"/>
    <parameter name="profile" value="*"/>
    <parameter name="nocompile" value="true"/>
    <parameter name="nodatasources" value="true"/>
    <parameter name="forcerewrite" value="true"/>
    <parameter name="outputfile" value="E:\SOAworkspace\otnapp\deploy\otntest.ear"/>
    <property name="wl_server" location="D:\weblogicSA2011\wlserver_10.3\samples\domains\wl_server" />
    </deploy>
    </ojdeploy-build>

    This blog gives you a start http://blogs.oracle.com/smuenchadf/2009/11/online_help_for_ojdeploy_utili.html
    But as far as I can tell ojdeploy just creates the EAR file. It does not deploy it to an WLS. For this you can use WSLT.
    Timo

Maybe you are looking for

  • How do I restore all bookmarks from an external hard drive to a refreshed firefox?

    I just "refreshed" Firefox and lost ALL of my passwords, even though the instructions said they would be saved. I have tried copying them from the Old Firefox Data folder and this does NOTHING. I have all of the data I need on an external hard drive

  • Altering a table in a materialized view environment

    Hello everybody!. My question is as simple as this: When I have a single master - multiple materialized views environment , and I want to alter the master table (usually adding a column) , how do I propagate the change to the materialized view sites

  • DispatchKeyEvent propagation error

    Hi, I have a JDialog and there is at a certain moment a child modal JDialog. These 2 dialogs have this code public boolean dispatchKeyEvent(KeyEvent e) switch( e.getKeyCode() ) case KeyEvent.VK_ESCAPE: cancelButton.doClick(); return true; default: re

  • Installed windows 7 on macbook but im having a few problems...

    I decided to install windows on my macbook since i want to play games and it is restricted in macbook... So i installed windows 7 ultimate 32 bit, but i can't open the games i installed because of some directx problem, it literally says that i should

  • Daily business report to top management

    Hi all We are running Enterprise portal 7.0 in our environment with no BI repoting. Our requirement is as follows: Currently the managers post their daily business reports on Excel; the problme in it is that everyone creates the report with his own i