Page 10 of 74 FirstFirst ... 678910111213142060 ... LastLast
Results 91 to 100 of 737
  1. #91
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    It's always something simple. Compiled fine.

    I'll test that it works in FSX then add the other switches.

    Thanks
    David

  2. #92
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Stefan,

    In the DOS box, I am getting error message:

    FSBUS DLL:
    ObjectID-551(17,7) still in use
    press any key to exit....


    Any ideas what that means?

    I have only just started FSX and only just powered up my boards and only just run the .exe (through compiling)

  3. #93
    300+ Forum Addict
    Join Date
    Feb 2008
    Location
    Krefeld, Germany
    Posts
    318
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    That mean you have twice the same object ID.
    The message also say what object.
    Group: 17
    Object: 7

  4. #94
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Is this where I should be looking?

    The message is referring to the C_SWITCH_FUELPUMP OID_SWITCHES_GROUP +7

    #include"switches.h"
    #define OID_SWITCHES_GROUP (17 << OID_CONTROL_BITS)
    #define C_SWITCH_ALTERNATOR OID_SWITCHES_GROUP +1
    #define FS_ALTERNATOR OID_SWITCHES_GROUP +2
    #define C_SWITCH_MASTERBATT OID_SWITCHES_GROUP +3
    #define FS_BATTERY OID_SWITCHES_GROUP +4
    #define C_SWITCH_MASTERAVIONICS OID_SWITCHES_GROUP +5
    #define FS_AVIONICS OID_SWITCHES_GROUP +6
    #define C_SWITCH_FUELPUMP OID_SWITCHES_GROUP +7
    #define FS_FUELPUMP OID_SWITCHES_GROUP +8

  5. #95
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Hi Stefan,

    I've done a bit of detective work and this is what I've found. Yes, I did have a duplicate Fuel offset (I was experimenting weeks ago and forgot to delete it.

    So now the project compiles.

    All of the switches work ie: Master Battery, avionics and alternator and fuel pump.
    Interestingly, if I turn the fuel pump switch on, if I use any of the above switches,(except the Alternator switch) not only does it turn the switch that it's meant to turn on, but it also switches off the fuel pump.

    It does the same even if I // out all lines relating to the fuel pump.

  6. #96
    300+ Forum Addict
    Join Date
    Feb 2008
    Location
    Krefeld, Germany
    Posts
    318
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    ok, in that case i would make an if - else like at the LEDīs.

  7. #97
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Stefan,

    Can you give me an example.

    In the LEDs, I only have :

    case FS_NAV1GSFLAG:
    FsbusWrite (C_LEDGLIDESLOPEFLAG, val);
    break;


    Which I've used,

    For the To/From LEDs, I have the if - else

    case FS_NAV1TOFROM:
    if (val==0)
    {
    FsbusWrite (C_LEDFROM, val);
    FsbusWrite (C_LEDTO, val);
    }
    else if (val==1)
    {
    FsbusWrite (C_LEDFROM, 0);
    FsbusWrite (C_LEDTO, 1);
    }
    else if (val==2)
    {
    FsbusWrite (C_LEDFROM, 1);
    FsbusWrite (C_LEDTO, 0);
    }
    break;

    But it's to light 2 leds from the one offset.

    Thanks
    David

  8. #98
    300+ Forum Addict
    Join Date
    Feb 2008
    Location
    Krefeld, Germany
    Posts
    318
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    case C_SWITCH_ALTERNATOR:
    if (val==0)
    FsWrite (FS_ALTERNATOR, 1);
    else
    FsWrite (FS_ALTERNATOR, 0);
    break;

  9. Thanks RobiD thanked for this post
  10. #99
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Thanks Stefan,

    That works for all the switches but the same problem persists.

    The Batt and Avionics switch turns off the fuel pump (that is whether you turn the switch on or off, if you turn the fuel pump switch on, whichever way your turn the Batt or Avionics switch, it turns the fuel pump off). It won't turn it on, it just turns it off.

    Tha Master Alt switch does not turn the fuel pump off. I can't see what I've done differently for the Alt switch.

    Any other thoughts?

    Thanks
    David

  11. #100
    300+ Forum Addict RobiD's Avatar
    Join Date
    Sep 2007
    Location
    Gold Coast, Australia
    Posts
    430
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: Progamming help with FSBus dll

    Ok, I'm totally confused.

    I deleted all of my switches and started from scratch.
    I moved the fuel pump switch to a different group completely, and re-wrote the Master switches from scratch.

    The group that I moved the fuel pump to does not affect the fuel pump switch but the same ones as before still change the fuel pump ie: MasterBatt, MasterAvionics.

    Very confusing.

Page 10 of 74 FirstFirst ... 678910111213142060 ... LastLast

Similar Threads

  1. Fsbus CDK
    By flyandre in forum General Builder Questions All Aircraft Types
    Replies: 4
    Last Post: 12-27-2014, 12:58 PM
  2. Need Help Getting My FSBUS NG I/O Going Again..
    By JBRoberts in forum I/O Interfacing Hardware and Software
    Replies: 14
    Last Post: 03-21-2010, 01:38 PM
  3. Fsbus ng io
    By Davral in forum I/O Interfacing Hardware and Software
    Replies: 0
    Last Post: 01-10-2009, 10:38 PM
  4. Fsbus 2.4.3
    By Anderson/SBSP in forum I/O Interfacing Hardware and Software
    Replies: 9
    Last Post: 11-30-2008, 04:25 PM
  5. Help FSBUS
    By cesarfsim in forum I/O Interfacing Hardware and Software
    Replies: 2
    Last Post: 10-26-2008, 02:23 PM

Tags for this Thread