Results 1 to 3 of 3

Thread: Flash for RRFusion Volts output

  1. #1
    Constant Bitrate
    Join Date
    Jul 2008
    Location
    Lee's Summit
    Posts
    138

    Flash for RRFusion Volts output

    I'm reading in the RRFusion plugin. It's working great! but I can't seem to get the volts needle to stop on the correct number.
    I'm not sure it's seeing the int. for the if's... can someone tell me if this should work? I think it is close but may not be...

    Somebody? Anybody?


    tmpstr = _root.ANALOG1;

    //used to remove the V at the end of the numbers from tmpstr
    volt_tmp = tmpstr.slice(0, length(tmpstr)-1);

    //This reads in the volts but if I try to do this:
    // It's not working correctly...

    if (volt_tmp>1){gotoAndStop("1");}
    if (volt_tmp>2){gotoAndStop("2");}
    if (volt_tmp>3){gotoAndStop("3");}
    if (volt_tmp>4){gotoAndStop("4");}
    if (volt_tmp>5){gotoAndStop("5");}
    if (volt_tmp>6){gotoAndStop("6");}
    if (volt_tmp>7){gotoAndStop("7");}
    if (volt_tmp>8){gotoAndStop("8");}
    if (volt_tmp>9){gotoAndStop("9");}

    //and so on up to 16+ volts

    How can you tell if your getting and Int value to run the if off of?
    I'm getting out put for it just fine... The textbox on my flash outputs reads (2.34) as example.

    Thanks for the help..
    Troy
    Batmaninls
    www.evorbust.com

  2. #2
    Constant Bitrate
    Join Date
    Jul 2008
    Location
    Lee's Summit
    Posts
    138
    I got it... I had to work a little math in there... It appears to function correct now and I got rid of all them If's clean code will run better...

    Here is what I used....

    volt_tmp1 = Math.round(volt_tmp / 2) * 2
    gotoAndStop("" + volt_tmp1);
    Batmaninls
    www.evorbust.com

  3. #3
    Mo' Programming Mo' Problems
    Auto Apps:loading...
    Sonicxtacy02's Avatar
    Join Date
    Sep 2004
    Location
    Woodbridge, VA
    Posts
    8,173
    Blog Entries
    53
    glad to hear you got it working
    mp3Car.com Senior Tech Blogger (Want a product reviewed? Contact me.)
    Find my plugins on the MP3Car App Store!
    Follow Me on Twitter or Facebook
    Live mp3Car Facebook Chat

Similar Threads

  1. Replies: 4
    Last Post: 12-04-2008, 02:29 PM
  2. Replies: 33
    Last Post: 03-28-2008, 03:18 PM
  3. Replies: 5
    Last Post: 04-08-2007, 09:38 PM
  4. Is all coax/optical spdif output created equal?
    By Choser in forum General Hardware Discussion
    Replies: 26
    Last Post: 12-19-2004, 03:48 PM
  5. How many volts can a sound card output?
    By kkhendricks in forum General Hardware Discussion
    Replies: 5
    Last Post: 01-16-2001, 12:36 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •