QNaN

Experts of LabVIEW,

I have a question of arithmetic on QNAN and typecast.  I wrote the code that's going to take a hexadecimal string and convert it into a floating point number.  For example:

hex: 0000C0C3

I swap the bytes to reach C3C00000, the integer value 3284140032, then typcast using 0.00 as type.  When I met hexagonal channels that evaluate to negative numbers, such as 0000C0C3 and after I swap the bytes and type conversion, I get-384.  Using this same procecdure in C++, I get 1. #QNAN00.  How does the Subvi LabVIEW type cast?

Hi shivels,

What happens when convert you to a SGL (that you have a 4 byte number) in LV and C?

Average cast reinterpreting a stream of bytes. 0xC3C00000 represents a 3284140032 U32 = 0d or a =-1010827263 I32 or a SGL = - 384. All use the same binary representation, just to dispel them is different...

Tags: NI Software

Similar Questions

  • File produces the following import errors: bad entry for OVPSMatrix: 1. #QNAN 1. #QNAN 1. #QNAN 1. #QNAN

    original eps file have prob

    I have check

    no prob

    Why this error during preflight

    Try to open the saved eps Illustrator as an .ai file original and use it instead.

  • Help-components throwing compile errors

    Thank you for reading my question. I am using Flash CS3. Recently, all my projects started throwing the standard component AS3 code compilation errors.
    Interface user, FLVPlayback component.

    I uninstalled and reinstalled Flash CS3, but in vain. Problem persists
    I keep getting errors involving "QNAN", which is to trap for a nonnumeric value, or something, in my opinion.

    As a test, I created a new Flash document, placed an FLVPlayback instance on the stage, pulled a. FLV file in the same directory.

    Errors on compilation:
    1093: syntax error.
    1084: syntax error: expecting rightparen before QNAN.
    1093: syntax error.
    1084: syntax error: expecting rightparen before QNAN.

    And so on, I get 5 sets of the same errors for different functions.
    The first question above function reads:

    function queueCmd (param1:VideoPlayerState, param2:Number, param3:Number = 1. #QNAN): void
    {
    If (param1.cmdQueue is nothing)
    {
    param1.cmdQueue = new Array();
    } / / end if
    param1.cmdQueue.push (new QueuedCommand (null, false, param2, param3));
    return;
    } / / end of function

    I get similar errors of my AS3 user interface component as well.

    I have not touched AS3 embedded for these components. What gives?

    Any ideas?

    Thank you
    Tim

    OK, by means of an update: do not trust Adobe to spare.

    I'm sure there is a reason for this, but I discovered that when you uninstall Flash CS3 program installation Adobe removes everything. Everything except the components and a few other odds and ends.

    Long story short, I did the uninstall and then manually trashed components. Reinstalled and everything seems hunky-dory.

    So, no idea why my component code went all wobbly, but a total reinstall did the trick.

    Thanks to everyone for their suggestions. Here I've had hours of back that I wasted assuming that uninstall meant uninstall ;)

    Tim

Maybe you are looking for