Urgent!!! Need help in file read/write data to a serial port

Hi,
I really need someone's help in order for me to complete my project. I have attached a vi which I have taken from an example and integrate to my project. In the vi, I have managed to get the encoder counts using Ni 9411. I need to read/write that data from ni9411 to ni9870 without using any serial port as they are connected to a NI 9104 chasis. May I know whether I am correct in writing the data to my ni9870 port using the vi I have attached? Does anyone know how i can convert the number of counts to a 8-bit data/byte so that I can send the data through the RS232 port? I really need someone's help as I need to finished in 2 weeks time.
I have also attached an vi on controlling the epos2 controller using instrument driver. Does anyone know how can i integrate this vi to the fpga vi (the one which I need to read/write data to 9870) as I need to send those data to control my epos2 controller.
Please help me!!!
Attachments:
Encoder Position & Velocity (FPGA).vi ‏23 KB
SINGLEMOTORMODIFIED.vi ‏17 KB

Afai,
As I allready suggested you here, call your local NI Office and ask for assistance!
You really need assistence in a higher level that we can provide via the forums. Otherwise I don't see a chance for you to finish your project in time.
1. Convert I32 to U8 to write it to the 9870 could be done like this:
2. The vi to control the epos2.
There is NO way ( absolutely NO way) to port this vi to FPGA. It's based on VISA calls, uses an event-structure, both are not available at the FPGA.
The only thing you could do is to analyze the VI, the instruction set and design an FPGA vi which handles the specific instructions you would need.
I have no experience with epos2 and I'm not 100% sure if this would work as you would like to use it. And doing this needs deep knowledge of LabVIEW, VISA, Instrument Drivers, the epos hardware, FPGA programming, and so on... 
Christian

Similar Messages

  • [Urgent] Need help calculating difference between two dates

    I'm trying to write a code to display the current day and time, then accept two dates from the user and display the difference between the two dates. To display the current date and time, I've used the SimpleDateFormatter library but I'm having difficulty calculating the difference between two dates. Could someone please help me with this?
    Below is my code so far
    import java.util.Date;
    import java.util.Scanner;
    import java.text.SimpleDateFormat;
    public class DateFormatter {
         public void displayNow()
              Date todaysDate = new Date();
              SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MMM-dd HH:mm:ss");
              String formattedDate = formatter.format(todaysDate);
              System.out.println("Today's date and time is: "+formattedDate);
         public void calculateDifference(Date startDate, Date endDate)
              /* This is whre i need help! */
         public static void main(String[] args)
              DateFormatter df = new DateFormatter();
              Scanner sc = new Scanner(System.in);
              df.displayNow();
              System.out.println("Please enter a date: ");
              String date1 = sc.next();
              System.out.println("Please enter another date: ");
              String date2 = sc.next();
    }The methods displayNow() and calculateDifference(Date startDate, Date endDate) are essential and cannot be skipped out.

    tarahmarie101 wrote:
    Dude. I've tried doing assignments under pressure, and it doesn't work. Here's a piece of free advice. Start earlier next time, don't put "urgent" in the title of your post b/c it just pisses people off around here--and is a sure sign of an overdue homework assignment which no one around here likes helping with, and try to ask intelligent questions--don't just say "Help me!"
    Of course, it takes some time to learn what the intelligent questions are. You have my sympathy. Try asking questions about how to do a particular task, instead of asking people to tell you what to do. It starts to get easier after a while.
    actually dude i started on this on monday.. but there were so many other stuff to do along with this.. and i did try referring up the Calendar utility but it was a bit confusing actually.. it was only after that did i come to this forum.. nor am i very good at Java.. anyhoo thanks for your sympathies :P

  • Hello!!!I need to read some data from the serial port and processing these, at the same time I want to see the process that I am doing.

    I read the data without problems, and I see them using Waveform graph, the problem is that I want to see the real time stamps, but in the graph appears 2:00:00,000 and 01/01/04, so the date and the time is wrong !!
    Can I change this?
    I am thinking that the problem is that I have to adquire the data and the time stamps ( using Get date/time) and after, I have to represent both!!!
    Thanks!!!

    Hello,
    As you probably know a waveform is made of a beginning time (t0), a time difference between each value (dt) and an array of values (Y). Your problem is probably that you don't initialize t0. Use the Vi 'Waveform->Build a waveform' to initialize the time of the waveform.
    Hope this helps !
    Julien

  • Sending/reading hex data to a serial port in Powershell

    I have a device which responds to serial port requests. Using portmon I can see a request formatted as a six byte hex string.
    e.g. x'02031005E6 the last byte being a crc which I can work out.
    I don't seem to be able to write this data to a comm port as if I write
    [Byte[]] $request = 0x02,0x03,0x10,0x05,0xE6
    $port.Write($request)
    I see
    0.00189600 powershell_ise IRP_MJ_WRITE LSerial0 SUCCESS Length 12: 32 20 33 20 31 36 20 35 20 32 33 30  
    where I was expecting Length 6: 02 03 10 05 E6
    even if I write
    [Byte] $request = 0x02
    $port.Write($request)
    I get
    0.00188317 powershell_ise IRP_MJ_WRITE LSerial0 SUCCESS Length 1: 32  
    I have a nasty feeling I am misunderstanding how Powershell handles hex strings/arrays and will assume the sucking of air through clenched teeth on the reply.

    Your handling of Bytes, hexadecimal literals and arrays is fine. What type of object is the $port variable referring to?
    Edit:  If it's a [System.IO.Ports.SerialPort] object, then the problem is that you're calling SerialPort.Write() with a single argument.  The only overload of that method which takes a single argument accepts a String parameter, and PowerShell
    is automatically turning your bytes / arrays into a string representation (which is then being converted back into a byte stream.)
    To use SerialPort.Write with a Byte[] argument, you need to pass in 3 arguments:  The array, the offset, and the byte count.  For example:
    [Byte[]] $request = 0x02,0x03,0x10,0x05,0xE6
    $port.Write($request, 0, $request.Count)
    See
    http://msdn.microsoft.com/en-us/library/System.IO.Ports.SerialPort.Write(v=vs.110).aspx for more info.

  • Urgent-Need help with code for Master data enhancement

    hi Experts,
    I have appended YMFRGR field(Table MARC) to 0MAT_PLANT_ATTR datasource.
    The key fields in the MARC table are MATNR and WERKS.Can anybody help with the user exit to populate this field,as am pretty new to ABAP.
    Thanks in advance

    Hi,
    go through this link which has the similar problem:
    https://forums.sdn.sap.com/click.jspa?searchID=1331543&messageID=2794783
    hope it helps.
    Thanks,
    Amith

  • Urgently need help with this

    Hi!!
    I urgently need help with this:
    When I compile this in Flex Builder 3 it says: The element type 'mx:Application' must be terminated by the matching end-tag '</mx:Application>'.
    but I have this end tag in my file, but when I try to switch from source view to desgin view it says, that: >/mx:Script> expected to terminate element at line 71, this is right at the end of the .mxml file. I have actionscript(.as) file for scripting data.
    This is the mxml code to terminate apllication tag which I did as you can see:
    MXML code:
    <?xml version="1.0" encoding="utf-8"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" backgroundGradientAlphas="[1.0, 1.0]" backgroundGradientColors="[#007200, #000200]" width="1024" height="768" applicationComplete="popolni_vse()">
    <mx:HTTPService id="bazaMME" url="lokalnabaza/baza_MME_svn.xml" showBusyCursor="true" resultFormat="e4x"/>
    <mx:Script source="dajzaj.as"/>
    <mx:states>
    <mx:State name="Galerije">
        <mx:SetProperty target="{panel1}" name="title" value="Galerije MME"/>
        <mx:SetProperty target="{panel2}" name="title" value="opis slik"/>
        <mx:SetProperty target="{panel3}" name="title" value="Opis Galerije"/>   
        <mx:AddChild relativeTo="{panel1}" position="lastChild">
        <mx:HorizontalList x="0" y="22" width="713.09863" height="157.39436" id="ListaslikGalerije"></mx:HorizontalList>
                </mx:AddChild>
                <mx:SetProperty target="{text1}" name="text" value="MME opisi galerij "/>
                <mx:AddChild relativeTo="{panel1}" position="lastChild">
                    <mx:Label x="217" y="346" text="labela za test" id="izbr"/>
                </mx:AddChild>
                <mx:SetProperty target="{label1}" name="text" value="26. November 2009@08:06"/>
                <mx:SetProperty target="{label1}" name="x" value="845"/>
                <mx:SetProperty target="{label1}" name="width" value="169"/>
                <mx:SetProperty target="{Gale}" name="text" value="plac za Galerije"/>
            </mx:State>
            <mx:State name="Projekti"/>
        </mx:states>
    <mx:MenuBar id="MMEMenu" labelField="@label" showRoot="true" fillAlphas="[1.0, 1.0]" fillColors="[#043D01, #000000]" color="#9EE499" x="8" y="24"
             itemClick="dajVsebino(event)" width="1006.1268" height="21.90141">
           <mx:XMLList id="MMEmenuModel">
                 <menuitem label="O nas">
                     <menuitem label="reference podjetja" name="refMME" type="check" groupName="one"/>
                     <menuitem label="reference direktor" name="refdir" type="check" groupName="one"/>
                  <menuitem label="Kontakt" name="podatMME" groupName="one" />
                  <menuitem label="Kje smo" name="lokaMME" type="check" groupName="one" />
                 </menuitem>           
                 <menuitem type="separator"/>
                 <menuitem label="Galerija">
                     <menuitem label="Slovenija" name="galSvn" type="check" groupName="one"/>
                     <menuitem label="Nemčija" name="galDeu" type="check" groupName="one" />
                 </menuitem>
                 <menuitem type="separator"/>
                 <menuitem label="projekti">
                     <menuitem label="Slovenija" name="projSvn" type="check" groupName="one"/>
                     <menuitem label="Nemčija" name="projDeu" type="check" groupName="one" />
                     <menuitem label="Madžarska" name="projHun" type="check" groupName="one"/>
                 </menuitem>
             </mx:XMLList>                       
             </mx:MenuBar>
        <mx:Label x="845" y="10" text="25. November 2009@08:21" color="#FFFFFF" width="169" height="18.02817" id="label1"/>
        <mx:Label x="746" y="10" text="zadnja posodobitev:" color="#FFFFFF"/>
        <mx:Panel x="9" y="57" width="743.02814" height="688.4507" layout="absolute" title="Plac za Vsebino" id="panel1">
            <mx:Text x="0" y="-0.1" text="MME vsebina" width="722.95776" height="648.4507" id="Gale"/>
        </mx:Panel>
        <mx:Label x="197.25" y="748.45" color="#FFFFFF" text="Copyright © 2009 MME d.o.o." fontSize="12" width="228.73239" height="20"/>
        <mx:Label x="463.35" y="748.45" text="izdelava spletnih strani: FACTUM d.o.o." color="#FBFDFD" fontSize="12" width="287.60565" height="20"/>
        <mx:Panel x="759" y="53" width="250" height="705.07043" layout="absolute" title="Plac za hitre novice" id="panel3">
            <mx:Text x="0" y="0" text="MME novice" width="230" height="665.07043" id="text1"/>
            <mx:Panel x="-10" y="325.35" width="250" height="336.61972" layout="absolute" title="začasna panela" color="#000203" themeColor="#4BA247" cornerRadius="10" backgroundColor="#4B9539" id="panel2">
                <mx:Label x="145" y="53" text="vrednost" id="spremmen"/>
                <mx:Label x="125" y="78" text="Label"/>
                <mx:Label x="125" y="103" text="Label"/>
                <mx:Label x="0" y="53" text="spremenljivka iz Menuja:"/>
                <mx:Label x="45" y="78" text="Label"/>
                <mx:Label x="45" y="103" text="Label"/>
            </mx:Panel>
        </mx:Panel>
        <mx:Label x="9.9" y="10" text="plac za naslov MME vsebine" id="MMEnaslov" color="#040000"/>
         </mx:states></mx:Application>

    I know it's been a while but… did you fix this?
    It looks to me like you are terminating the <mx:Application> tag at the top. The opening tag should end like this: resultFormat="e4x">, not resultFormat="e4x"/> (Remove the /).
    Carlos

  • Urgently  need help for parsing IP header

    Hi, could anyone tell which class I should use to parsing the IP header of a packet?
    Thanks many many times!

    > Hi, could anyone tell which class I should use to
    parsing the IP header of a packet?
    DatagramPacket?
    > Urgently need help for parsing IP header
    Don't flag your question as urgent, even if it is for you.
    * We all answer questions here voluntarily, in our leisure time. We do that because doing so is fun for us, because we enjoy helping people and having interesting discussions. Guess what, it is much less fun if it gets stressful. So the last thing you want to do to get us to answer your question is to pass your stress over to us.
    * People who are stressed and want a fast answer often don't even find the time to do the necessary research or to formulate their question in an easy to comprehend way. That's even less fun to work with. So you really don't want us to feel your stress. Instead you want to take your time to write a well formulated post that is fun to answer. The less likely it is for us to know that your question is urgent, the more likely you are to get a fast answer!
    * The simple notion that you want your post to be answered faster than those of the other members might feel rather unfair to some of us. Doubly so because often "urgent" questions actually are homework questions. Yours might be different, but someone who had bad experiences with this type of question might not read far enough to notice.

  • File read/write in Oracle JVM

    Are there any known issues around file read/write in Oracle JVM. I finally got around the issue of getting the error that says no permission is there by giving <<ALL FILES>> option, but still I don't see a file being created. Any help is appreciated.
    Code:
    try{
    fwriter = new PrintWriter(new FileOutputStream("debugLog.txt",true));
    } catch (IOException ioe) {
    System.err.println("IO Exception for Output File" + ioe.getMessage());
    Thanks.
    -Mujib

    A couple of suggestions:
    1. (Please don't be offended...) I assume you have some stuff like:
    fwriter.println("hello");
    fwriter.flush();
    fwriter.close();
    in your try block?
    2. Try catching FileNotFoundException and SecurityException also.
    3. Try providing a full path on the file just to make sure it's not buried somewhere odd.
    John H.

  • Missing file read/write feature on Mac OS X?

    HI,
    i am missing the file read/write statistics on Mac OS X. First i thought i just need to enable it in the template editor under "Advanced -> Java Application" but the two list items are simple not there. I ve seen a screenshot somewhere from the JMC where the two options are present but not for me. Can anyone tell me if this is a platform issue or how to enable it?
    Thx
    Marc

    You didn't say which version you are using, but I think what you are seeing is that the file and socket events are not available in JDK 8 only in JDK 7. This is a known regression that will be fixed in the next update to JDK 8.

  • I am setting up a new iMac and need help syncing files to Dropbox.  On my old computer I had it set where when I saved a document, it was saved on my hard drive, as well as to a folder in Dropbox.  I can't remember how I set this up.  Any help?

    I am setting up a new iMac and need help syncing files to Dropbox.  On my old computer I had it set where when I saved a document, it was saved on my hard drive, as well as to a folder in Dropbox.  I can't remember how I set this up.  Any help?

    The way that Dropbox works is that it keeps a copy of all your files in your local Dropbox folder on your hard drive (which is, by default, directly under your home folder). Adding files to that folder will sync them to the Dropbox server.
    You do of course have to download the Dropbox application to enable this (download link at the top right of http://dropbox.com ).
    Matt

  • I need help installing Acrobat Reader - messaged failed to connect to a DDE Server. Can't access documents

    I need help installing Acrobat Reader - messaged failed to connect to a DDE Server. Can't access documents

    Please see if "acrobat failed to connect to dde server" when openning Adobe Acrobat XI PRo helps.

  • Is it possible to read/write data from Salesforce using web service hub in Informatica?

    Anyone from Informatica can asnwer this question please

    Is it possible to read/write data from Salesforce using web service hub in Informatica? Not asking about PowerExchange for Salesforce or Informatica Cloud. Just using web service can we load data into Salesforce? Thanks ahead.

  • Need help! Can't validate date overlaps for a tabular column

    Hello all,
    The validation I created to validate whether new or updates rows does not overlap with any records in the table isn't working.
    The columns are StartDt and EndDt
    Validation Type: NOT EXISTS
    Validation expresion:
    select 1
        from  sample S
        WHERE S.STARTDT BETWEEN :STARTDT AND :ENDDT
    OR(S.ENDDT BETWEEN :STARTDT AND :ENDDT)
    or (S.STARTDT <= :STARTDT and S.ENDDT >= :ENDDT)
    or (:STARTDT <= S.STARTDT and :ENDDT >= S.ENDDT)
    Error Message:
    Times overlap
    When Buttons pressed
    -Select Button-
    The validation works if a new row or updated row overlaps any existing start and end date records but it doesn't work if I update startdate and end date rows that doesn't overlap existing date times
    Example:
    TABLE DISPLAYS THE FOLLOWING RECORDS
    NAME                   START DATE                      END DATE
    TEST                    1/1/2012                               12/31/2012
    If I update the rows to the following values, I receive an error message (although those values don't overlap any records in the table)
    NAME                   START DATE                      END DATE
    TEST                    6/1/2012                               10/30/2012
    Any ideas? Do I need to change my code?
    Click the link to view the answer to this question. Need help! Can't validate date overlaps for a tabular column
    Message was edited by: CharlieMack

    Logic for date range overlap testing only requires two conditions in the WHERE clause:
    ORACLE-BASE - Overlapping Date Ranges
    WHERE S.STARTDT <= :ENDDT AND S.ENDDT >= :STARTDT -- TRUE for ranges that overlap
    It looks a little odd, but, if you scribble out a 'logic table', it makes sense.
    Condition
    A.start <= B.end
    A.end >= B.start
    A__A B--B
    true
    false
    A__B=A--B
    true
    true
    A__B==B__A
    true
    true
    B--A==B__A
    true
    true
    B--B A__A
    false
    true
    MK

  • Why does a standalone program created in Labview 8.5 try connecting to the internet when the program only reads data through the serial port? Firewalls object to progams that contact the internet without permission.

    why does a standalone program created in Labview 8.5 try connecting to the internet when the program only reads data through the serial port? Firewalls object to progams that contact the internet without permission.
    The created program is not performing a command I have written when it tries to connect to the internet, it must be Labview that is doing it. How do I stop this from happening? 
    Any help would be very appreciated.

    It looks that way..
    "When LabVIEW starts it contacts the service
    locator to removes all services for itself. This request is triggering
    the firewall.This is done in case there were services that were not
    unregistered the last time LabVIEW executed- for example from VIs that
    didn't clean up after themselves"
    This is not yet fixed in LV2009.
    Message Edited by Ray.R on 11-04-2009 12:25 PM

  • Need SNMP MIB files For Cisco SF 300-48 48-Port 10/100 Managed Switch

    Hi All,
    I need SNMP MIB files for Cisco SF 300-48 48-Port 10/100 Managed Switch.
    I have gone through cisco site but not able to get it.
    Can anyone please provide me.I have stuck with this.
    Thanks
    Ram

    Hi Ram, yes the MIB can be used. The switches are essentially the same in many regards (especially on a software level).
    I do not know the OID for bandwidth. If you're looking for a particular OID may be this tool helps you
    http://tools.cisco.com/Support/SNMP/do/BrowseOID.do?objectInput=dot1dTpPortTable&translate=Translate&submitValue=SUBMIT&submitClicked=true
    -Tom
    Please mark answered for helpful posts

Maybe you are looking for

  • Unable to open any docs in Adobe (11)

    Cannot open any docs with Adobe. Get message "Adobe has encountered a problem and needs to close". Can you help? thanks

  • I have a G4 and just bought the iPhone 4 and cant get my music on my phone

    I have a G4 with OSX 10.4.11 and just bought the iPhone 4 and cant get my music on my phone because apparently I need to upgrade to itunes 10 but cant because it only works with OSX 10.5. So basically im forced into another upgrade is that what i hav

  • Will KisMac run on Mountain Lion?

    I have heard that KisMac does not play well with Mountain Lion.  Has anyone had experience with this combination? Thanks.

  • How to read music file size?

    I have the third generation iPad. I've sync'd (via iTunes of course) a CD album in Apple Lossless and another CD album in AIFF. Most other audio that have already been sync'd is in MP3 format. So how can I see the file size of each song in the iPad?

  • Space to Install on Solaris over 2GB???

    Hi, Having installed 1.0.2.2 on NT and saw the tablespace sizing listed in the install guide as adequate, I next installed on Sun Solaris 8, using 8.1.7.1. In the Portal Configuration Assistant, I have to keep increasing the tablespace for this. My l