Results 481 to 490 of 737
Thread: Progamming help with FSBus dll
-
10-14-2010, 01:20 PM #481
- Join Date
- Jan 2007
- Location
- NEW ZEALAND
- Posts
- 899
Re: Progamming help with FSBus dll
Sorry David,
I was thinking of the Compass, where you stick a rod in the center of the Faceplate and this has to be drilled.
Les
-
10-14-2010, 06:20 PM #482
Re: Progamming help with FSBus dll
Oh, got ya.
Umm, although this was my first gauge build, it will probably be my last to finish as the Stepper part of FSBus is only looking like it's sorted now. My compass rose is loose in the gauge.
What I may do is re-cut the compass rose with the cnc machine and make the centre hole at the same time. At least I know it will be centered.
-
10-15-2010, 07:19 AM #483
Re: Progamming help with FSBus dll
Stefan,
Have some questions, hoping you can help.
I am having a go at getting the altitude indicator programed.
I have a 200 step stepper motor 360 deg = 1,000 ft. on the gauge
720 deg = 2000 ft etc.
I am using the offset 0x3324 Altitude feet.
In FSInterogate 0=0 (on the ground), and at 10000 feet = 10000 in FSInterogate
I have made the objects and declared them.
MkFsbusObject (BTP_A_OUT, S_ALTIMETERFEET,"Altimeter Feet", cbGauges, 8,80);
MkFsObject(FS_ALTIMETERFEET,"Altimeter Feet", cbGauges, 0x3324, 4, TP_I32, FS_NORMAL);
The way I'm looking at it is that Dirk is suggestion using the FsbusWriteFmtVar(30, 80, 0); to write the position to the stepper
0 in the (30,80,0) being the position of the stepper (number of steps), if it was 200 it should have done a 360 deg movement.
So can I make the 0 a variable, and give the value of the offset to this variable, but also do it in a way so that each 1000 on the variable = 200 steps
Look forward to your thoughts.
Thanks
David
-
10-15-2010, 07:34 AM #484
- Join Date
- Feb 2008
- Location
- Krefeld, Germany
- Posts
- 318
Re: Progamming help with FSBus dll
ok short idea.
case FS_ALTIMETERFEET:
val= val/5; // 1000feet for 360° are 200 steps (1000/200)
FsbusWriteFmtVar(8, 80, val);
break;
how you connect the 3 Sensors to the Stepper card? in a row?
Stefan
-
10-15-2010, 07:56 AM #485
Re: Progamming help with FSBus dll
Thanks Stefan,
I put the 3 interupters in a row one on the 100 feet, one on the 1000 ft and one on the 10000 ft gears
This way, when it needs to zero, it won't stop going to the left until all 3 needles are on zero.
case FS_ALTIMETERFEET:
val= val/5; // 1000feet for 360° are 200 steps (1000/200)
FsbusWriteFmtVar(8, 80, val);
break;
So how do I get the offset value to be val?
David
-
10-15-2010, 08:00 AM #486
- Join Date
- Feb 2008
- Location
- Krefeld, Germany
- Posts
- 318
Re: Progamming help with FSBus dll
I put the 3 interupters in a row one on the 100 feet, one on the 1000 ft and one on the 10000 ft gears
This way, when it needs to zero, it won't stop going to the left until all 3 needles are on zero.
case FS_ALTIMETERFEET:
val= val/5; // 1000feet for 360° are 200 steps (1000/200)
FsbusWriteFmtVar(8, 80, val);
break;
So how do I get the offset value to be val?
-
10-15-2010, 08:15 AM #487
Re: Progamming help with FSBus dll
Oh, ok. So in this instance, val will be the value of FS_ALTIMETERFEET
When ever you have the case then object, val will be the value of the object.
-
10-15-2010, 09:07 AM #488
Re: Progamming help with FSBus dll
I'm not getting any action in the Altitude indicator.
What syntax do I use to view the value of val, ie: printf(........);
Any other suggestions to try?
Also, Shouldn't I be writing to S_ALTIMETERFEET
MkFsbusObject (BTP_A_OUT, S_ALTIMETERFEET,"Altimeter Feet", cbGauges, 8,80);
-
10-15-2010, 09:32 AM #489
- Join Date
- Feb 2008
- Location
- Krefeld, Germany
- Posts
- 318
Re: Progamming help with FSBus dll
Also, Shouldn't I be writing to S_ALTIMETERFEET
MkFsbusObject (BTP_A_OUT, S_ALTIMETERFEET,"Altimeter Feet", cbGauges, 8,80);
Sample for a printf
printf("input %d trimL %d trimR %d\n", val, trimL, trimR);
%d is the space where the variable is shown.
in my sample 3 %d for the 3 variable.
\n is new line.
-
10-15-2010, 09:41 AM #490
Re: Progamming help with FSBus dll
Would that object be having any effect on 'no movement' on the gauge.
Should I also see the green led on the Stepper board lighting up quite a bit. It is not receiving any data at all (not lighting up, other than when FSBus starts)
Similar Threads
-
Fsbus CDK
By flyandre in forum General Builder Questions All Aircraft TypesReplies: 4Last Post: 12-27-2014, 12:58 PM -
Need Help Getting My FSBUS NG I/O Going Again..
By JBRoberts in forum I/O Interfacing Hardware and SoftwareReplies: 14Last Post: 03-21-2010, 01:38 PM -
Fsbus ng io
By Davral in forum I/O Interfacing Hardware and SoftwareReplies: 0Last Post: 01-10-2009, 10:38 PM -
Fsbus 2.4.3
By Anderson/SBSP in forum I/O Interfacing Hardware and SoftwareReplies: 9Last Post: 11-30-2008, 04:25 PM -
Help FSBUS
By cesarfsim in forum I/O Interfacing Hardware and SoftwareReplies: 2Last Post: 10-26-2008, 02:23 PM
KIDS TEEN 9year GIRL DAUGHTER WEBSITE: OPEN IN AN ANONYMOUS BROWSER (the link does not work in...
Offsets for Trottle