How can I convert a string of hex values to a hex format string programatically?

Is there a way to convert a string of the following format:
1400010107070D0305006A01 ........           ("Normal display" string)
programatically to:
1400 0101 0707 0D03 05006A01 ..........      ("Hex display" striing)
I need to do this in order to calculate a CRC16 value.
See attached VIs
Thank you.
Solved!
Go to Solution.
Attachments:
CMM_SN_MULTI.vi ‏50 KB
CMM_CRC16_Calculator.vi ‏23 KB

You can iterate over the string and use the String to Hex VI. If you work with two bytes of the string at a time you can get a U8 array of the desired binary values. Then when you are complete you can either work with the byte array of convert it back to a string using Byte Array to String.
EDIT: GerdW typed faster than I did.
Message Edited by Mark Yedinak on 03-18-2010 02:55 PM
Mark Yedinak
"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot

Similar Messages

  • How can I convert my AVCHD footage to an easier high definition format to edit?

    AVCHD UpShift, from NewBlue, convert AVCHD (hi-def MP4) to more standard HD-mpeg (hi-def MPEG .m2t), a format that is both more universally editable and which demands significantly less system resources.
    http://www.newbluefx.com/avchd-upshift.html
    The product sells for $49.95.
    Another solution that will convert your AVCHD to formats more easily edited on a PC with no loss quality. 
    http://www.shedworx.com/voltaichd
    Note, of course, with any conversion, your output files will be much larger, so allow for that extra hard drive space.
    It sells for $34.99.
    More information on the why's and how's of converting video for Premiere Elements can be found in my article "Converting Video for Premiere Elements", free from Muvipix.com.

    A free converter that will convert AVCHD to Premiere Elements compatible hi-def MPEG2 is the Free AVCHD Converter, available from:
    http://www.koyotesoft.com
    According tp Paul Scrivener, you should up the bit rate to 25000kb/s and convert, and it will export 1920x1080 MPEG2.
    One downside is that, when you install it, it automatically downloads a search tool to your browser toolbar -- but it can easily be removed using Add/Remove Programs.
    For easy editing of AVCHD and even conversion to standard DV-AVI, a great buy is Corel VideoStudio Pro X2. This editor/converter sells for $59.99.
    http://www.corel.com/

  • How can I convert the old AppleWorks files into a modern useable format?

    I've been using Mac computers for many years. The most important application (to me) was AppleWorks. But now I have learned that if I upgrade
    to Lion all my Appleworks files will be lost.  I have searched in many places for the "How to convert AppleWorks files to some format that WILL
    be supported by Apple.  I see no information on the Apple website and when I speak to a support person, I am always told that AppleWorks is
    so very old, it was not included in their training so they cannot tell me anything.  The little bits of advice I did get caused all my 20,000 AppleWorks
    files to be moved into my LaCie terrabyte external storage file, and at the same time the old files remain in my Macintosh Hard Drive. But in both
    places, those files cannot be read any more, and the nicely organized work I had done, was all gone. I mean - my AppleWorks files were always
    grouped by folders into special interest sections.  Now those folders don't exist and everything is in disarray - and unreadable. The titles of each
    file is now greyed out.  I have tried
    to make the transfer in Bento3 but mostly in iWork06.  I was told by Apple staff NOT to buy a higher iWork such as 09 because they are too
    far removed from the old AppleWorks to be able to do anything with it.  So I've stuck to iWork06 with no success.  Also, I went to my favorite
    privately owned Apples store and found all their instruction manuals and DVD application files MISSING. Their shelves are empty. I was told
    the new way is to order off the internet but....I'd far rather go into a shop and see all they offer for sale.  If I had gone there to buy ONE item,
    I'd drive away with THREE items, because getting my hands on items was the important way to understand what the value and purpose
    of that item is.
    To summarize: I have installed iWorks06 with no written information about it.  I have iWork08 with an instruction book which never never
    mentions AppleWorks, so I have not installed iWork08.  I have Bento3 installed, but no instruction book.  So I haven't learned or tried anything
    because it too never speaks of AppleWorks transfer.  Some of my AppleWorks files are extremely important to me. Not just personal or
    social but BUSINESS!  I won't be able to answer the tax man should he come a-knocking on my door.   HELP!!

    So what kinds of files are they? Word processing docs, from the painting Appleworks app, or spreadsheets?
    This is how I've handled it:
    Anything word processing: should be able to import them (drag them in or import) into Pages. Worked here.
    Spreadsheets: Used File > Open to open an AW spreadsheet. Needs a few adjustments, but I was able to tailor Numbers to get my spreadsheets the way I wanted them. Just experimented for a while with a non-essential spreadsheet until I figured out what to do.
    Painting: That is the one I used the most (and continue to do so): Cannot be read by any iWork. If your doc is a finished product, simply save it as a .pdf or .jpg and then you can drag it into Pages. If it is not, then you are out of luck. I am keeping a partition with a bootable Snow Leopard system with Appleworks on it in order to be able to keep creating my stuff because I've not been able to find a somewhat equal substitute.
    So, keeping SL on a partition and/or an external drive is one option if necessary.

  • How can I convert a 680x480x2 array of values into binary and then joining adjacent elements to make a 640x480 array?

    I am obtaining data from a camera and getting 10-bit data in Labview. I want to convert the element values to binary and then join adjacent elements to create an array half the size of the original. 

    Hi cowboy,
    well 640×480 is not exactly half of 680×480×2...
    - You have to read the specs of your camera. Then you should know how to combine the values.
    - When you get 10bit values you probably need I16 datatype to store the values. Unless you also decrease the color resolution to 8 bit you are still stuck to 640×480×2 byte per image...
    - To join numbers you should have a look at the numerics->data manipulation function palette
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • How can I convert/read out from a string Hex (8-bit), the bit 0 length 1

    How can I convert/read out from Hex (8-bit), the bit 0 length 1 (string subset!!??) and convert it to decimal.
    With respect to one complement and two complement ?

    Just like Jeff, purely guessing here.
    It almost sounds like you just need to Read from Binary File?
    AND the 8-bit number with 1?
    Need more details.  What exactly do you have to start with?  What exactly are you trying to get out of it?  Examples help.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • How can I convert an int to a string?

    Hi
    How can I convert an int to a string?
    /ad87geao

    Here is some the code:
    public class GUI
        extends Applet {
      public GUI() { 
        lastValue = 5;
        String temp = Integer.toString(lastValue);
        System.out.println(temp);
        showText(temp);
      private void showText(final String text) {
        SwingUtilities.invokeLater(new Runnable() {
          public void run() {
            tArea2.setText(text + "\n");
    }

  • How can I convert  an ArrayList to a String[]

    Hi,
    How can I convert an ArrayList (only with strings) to a String[] ?
    I've tried this :
         public static String listToString(List l) {
              StringBuffer sb = new StringBuffer();
              Iterator iter = l.iterator();
              while (iter.hasNext()) {
                   sb.append(iter.next().toString());
                   if (iter.hasNext()) {
                        sb.append(',');
              return sb.toString();
    But what I get is an array of xxxxx@435634 (for example).
    Thanks a lot !

    Strings are Objects but not all Objects are Strings and at least one of the elements in your List is not a String.

  • How can I convert output data (string?) from GPIB-read to an 1D array?

    Hello all,
    I am reading a displayed waveform from my Tektronix Oscilloscope (TDS3032) via the GPIB Read VI. The format of the waveform data is: positive integer data-point representation with the most significant byte transferred first (2 bytes per data point).
    The output data of GPIB-Read looks like a string(?) where the integer numbers and a sign like the euro-currency sign are seperated by spaces e.g. #5200004C3 4 4 4 4 3C3C3........ (C represents the euro-currency sign).
    How can I convert this waveform data into a 1D/2D array of real double floatingpoint numbers (DBL) so I can handle the waveform data for data-analysis?
    It would be very nice if someone know the solution for this.
    t
    hanks

    Hi,
    First of all, I'm assuming you are using LabVIEW.
    The first you need to do is parse the string returned by the instrument. In this case you need to search for the known symbols in the string (like the euro sign) and chop the string to get the numeric strings. Here are some examples on parsing from www.ni.com:
    Keyword Search: parsing
    Once you parse the numeric strings you can use the "String/number conversion VIs" in the String pallette.
    Hope this helps.
    DiegoF.Message Edited by Molly K on 02-18-2005 11:01 PM

  • How can I convert a String into an int?

    I need to use command-line args. So I enter "java Main 123" and I want to use 123 not as a String but as an int.
    How can I convert it into an int?
    Thank You!!
    Sprocket

    Example method (you don't need to use a method unless you do this a lot)
    private int stringTOInt (String aString)
    int result = 0;
    try
    result = Integer.parseString(aString);
    catch (Exception ex)
    System.out.println ("Failed to convert string " + aString + " to int.");
    return result;
    }

  • How can I convert string to the record store with multiple records in it?

    Hi Everyone,
    How can I convert the string to the record store, with multiple records? I mean I have a string like as below:
    "SecA: [Y,Y,Y,N][good,good,bad,bad] SecB: [Y,Y,N][good,good,cant say] SecC: [Y,N][true,false]"
    now I want to create a record store with three records in it for each i.e. SecA, SecB, SecC. So that I can retrieve them easily using enumerateRecord.
    Please guide me and give me some links or suggestions to achieve the above thing.
    Best Regards

    Hi,
    I'd not use multiple records for this case. Managing more records needs more and redundant effort.
    Just use single record. Create ByteArrayOutputStream->DataOutputStream and put multiple strings via writeUTF() (plus any other data like number of records at the beginning...), then save the byte array to the record...
    It's easier, it's faster (runtime), it's better manageable...
    Rada

  • How can I convert the variable expression stored as string back to variable expression

    How can I convert the variable expression stored as string back to variable expression?
    I am storing the expression enterd in the TSExpresssionEditControl as simple string and want to convert back to expression since I want to get the data type of that expression.

    pritam,
    I'm not sure what you're trying to do exactly. If you are trying to get the value of a variable and you only have the name of value in a string, then you can use Evaluate() to get its value. If you want the data type, my advise is to use the GetPropertyObject() API method and just pass in the loop up string. Then you'll have a handle to the data object and then proceed from there.
    Regards,
    Song D
    Application Engineer
    National Instrument
    Regards,
    Song Du
    Systems Software
    National Instruments R&D

  • CS3/CS4/CS5 Win/Mac: How can I convert a Windows string to mac?

    Hi
    I have a Windows coded string. I like to convert this string into a Macintosh string. This means several characters are changed, e.g. ä, ö or ü.
    Is there a method in the Indesign SDK?
    How can I convert a windows string into a macintosh string and back?
    Thanks
    Hans

    I don't think this should work that way. If this string is in resource file, use UTF-8 encoding and make PMString do its job. use kResourceUTF8Encoded in StringTable:
    resource StringTable (kSDKDefStringsResourceID + index_enUS)
            k_enUS,                                             // Locale Id
            kResourceUTF8Encoded,                         // Character encoding converter (irp) I made this WinToMac as we have a bias to generate on Win...
                  // ----- Menu strings
                    kWFPCompanyKey,                         kWFPCompanyValue,
                    kWFPAboutMenuKey,                         kWFPPluginName "[US]...",
                    kWFPPluginsMenuKey,                    kWFPPluginName "[US]",
                        kWFPDialogMenuItemKey,               "Show dialog[US]",
                    kSDKDefAboutThisPlugInMenuKey,               kSDKDefAboutThisPlugInMenuValue_enUS,
                    // ----- Command strings
                    // ----- Window strings
                    // ----- Panel/dialog strings
                        kWFPDialogTitleKey,     kWFPPluginName "[US]",
                        kWFP_Tuna_Key,     "Tuna",
                        kWFP_Salmon_Key,     "Salmon",
                        kWFP_Bonito_Key,     "Bonito",
                        kWFP_Yellowtail_Key, "Yellowtail",
                        kWFP_Currency_Key, "$",
              // ----- Misc strings
                    kWFPAboutBoxStringKey,               kWFPPluginName " [US], version " kWFPVersion " by " kWFPAuthor "\n\n" kSDKDefCopyrightStandardValue "\n\n" kSDKDefPartnersStandardValue_enUS,
    Message was edited by: Maciej Przepióra

  • How can i convert some caracteres of a String in bold characteres?? hELPME

    How can i convert some caracteres of a String in bold caracteres?? hELPME
    I have a JList and a DefaultListModel of Strings. So, i have many key words like "proccess", "if", "fi" that i want these characteres in bold.

    How i can use HTML in java to change a String to bold?
    example
    String str = "channel ";
    str = <b>str</b>;
    like this? syntax error =/

  • How can I convert a string to a seperated characters?

    How can I convert a string to a separated characters without using array?
    such as: input = String "word"
    output =
    w
    o
    r
    d
    Thanks

    A string is stored internally in individual characters.
    The String class has a method 'charAt(int index)' which returns the character at that index so using a for loop..
    String s = "word";
    for(int counter=0; counter < s.length(); counter++)
    System.out.println(s.charAt(counter));
    HTH

  • How can I convert a Waveform to a String-For​mat?

    Hello,
    I write with "SQL-Execute.vi" datas to an Access-file. The "SQL-Execute.vi" needs a statement in String Format. And that is my problem. My source-datas (that I want to save to Access) are Waveforms. How can I convert the Waveform datas to a String Format?
    Thanks for help!

    Wire the waveform to the Get waveform componants function...from that you get t0, delta t and the sample values. Now you can generate whatever string you want based on that information...
    You could e.g. wire the Y array to a for-loop in which you calculate the time of each sample by taking t0 and adding delta t multiplied with the array index, then you could convert the Y value and the time to strings using the seconds to time string and number to fractional string functions...etc etc...
    MTO

  • How can I convert a double to string

    Hello,
    how can I convert a double value to a string value?
    Werner

    an other way: ;)
    double yourDouble;
    int intTmp;
    yourDouble = yourDouble * 100;
    yourDouble = yourDouble + 0.5;
    intTmp = yourDouble.intValue();
    yourDouble = intTmp;
    yourDouble = yourDouble / 100;you can write it some shorter...
    double yourDouble;
    int intTmp;
    yourDouble = yourDouble * 100 + 0.5;
    yourDouble = yourDouble.intValue() / 100;*100 moves the comma about two steps to the left.
    + 0.5 enables rounding!
    if your value is x.5 or larger you get x+1.?
    if its smaller than x.5 you get x.?
    by parsing the double value to an int the ? is cut.
    /100 moves the comma two steps back
    you get a double value with 2 decimals which is rounded.
    just my coins :)
    happy progging,
    Thof

Maybe you are looking for

  • JMS Content Conversion with spaces

    Hi I am using the JMS Content Conversion to transalte MQ messages ( they come from the Mainframe ),to XML Format. These messages are in fixed lenghts structure , the fields contain blanks (spaces) The adapter cannot deal with it,only fixed lenghts wi

  • Is it possible to create a Master Form?

    Hello... i am using Acrobat Pro 8.6. I was wondering if it might be possible to create a master form. I am using a form to receive artwork approval from my customers. My question is if I can use my proof form to create a form and use that form every

  • Need info about the integration Process.

    HI , I would like to know about the different components of Integration Process like about the Receiver etc.. and how do we relate the properties of each component with the container. Thanks in advance

  • Metadevadm report invalid device relocation

    Hi All , The syslogd reports the below error message in /var/adm/messages May  4 08:26:02 ORADR metadevadm: [ID 209699 daemon.error] Invalid device relocation information detected in Solaris Volume Manager May  4 08:26:02 ORADR metadevadm: [ID 912841

  • Printing Issue: Colors print fine from Photoshop but washed out in Illustrator

    I am having trouble printing from Illustrator.  The same image...whether cut and pasted, opened in, or using the swatch created....prints differently in Photoshop and Illustrator.  I need to use this specific color (for branding purposes) and it prin