MobiFlight Community Support

Welcome to the forum for MobiFlight! Feel free to reach out to the community in case you have questions, issues or just want to share great ideas or details about your latest home cockpit project.

You like MobiFlight? Donate via PayPal and support the MobiFlight development. Thanks! 

05/03/2024 - This forum is read-only

The community support for MobiFlight has moved exclusively over to our Discord server. Register for free and enjoy more interactive functions like image and video upload, voice chat. More than 7,000 registered users around the world make it a great experience!

See you on our MobiFlight Community Discord server.

A HUGE Thank You to everyone who participated in the forum, especially obviously to Pizman and Stephan who did an outstanding job over so many years providing an incredible service to the MobiFlight community.

The forum is still providing a lot of good content, hence we keep this information accessible.

icon
Avatar
raysot
Posts: 6
Is there a "Seek to zero" function for those steppers with built-in stops when I start the Mobiflight software?

This would help with startup and shutdown, since the steppers would always start from a known position (0).
2021-02-16 07:16
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
Hi

I not fully understand what you mean with "seek at Zero" ( Maybe my translation is wrong) .

Basicly MF got 2 Systems ....

By Software:
You define one time a Zero Point ( With the +/- Buttons in Display Tab of that Config) . After you click on "SET Zero Point" the current Position is Zero.
Means if you Stop and close Mobiflight the Motor will turn back everytime to this Zero Point !
Disadvantage: If you got a crash of Mobiflight or e.g. a Power issue on the Mega and the System Stops/kills before it can turn back then the last position is the "new" Zero Point.
Means you need to set the Zero Point once again.

By Hardware:
If you Enable the "Auto Zero Calibration" Checkmark in the Device Settings of the Motor then you can define a Pin on the Mega that include the Detector.
So you build e.g. a HallSesor, Laser/Light Sensor, Mechanical Contoact or so..... Simply a System that Close a Line from that Pin and GRD if Motor is in Zero Position.
Then at Systemstart MF will turn the Motor in one Direction aslong this Pin detect a GRD connection.


**************
Apollogy if i missunderstand your intentions.... If yes then explane me what you mean with a little example and maybe a linked Picture !
Good Luck !
2021-02-16 07:24
Avatar
raysot
Posts: 6
Let's take the FlightIllusion gauges for example (Their beautiful engine stack)

When power is first applied, regardless of where the needles are pointing, they are all rotated back to the physical stops to the left when the engine stack boots up. There are no sensors.

I would use sensors but a lot of my instrumentation doesn't have the room for the sensor so I would need to rely on a bootup sequence that rotates all the steppers back to zero.

As my gauge count grows, if the Mobiflight software decides to stop prematurely, then I have to manually reset all the steppers back to zero. I would rather not have to do that. ;-)
2021-02-17 01:39
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
I would say the situations of manual calibration needness are rare.

While building progress and lots of new configs every day ( and open Megas you handle new wires and so on) these Issues happen verry often. Also if you install new Aircrafts and while experiments on software settings a crash of Sim or the whole computer happen some times.
BUT
If your finished.... The Cockpit is fully working , Software have a final state and also MF have the final file that not need to get reworked again.... Then the number of fatal crashes pretty sure is nearly Zero.


Whatever.... At the moment there exist only this 2 System.
I not know how Flight Ilusion handle this.... But technical also with a kind of Sensor maybe.
In theory there can be a system in the Motor itself how many power ( tork) is used. So the motor "feel" when it get blocked by the endstop and in this way it find it´s zero point.
Or maybe the turn the Motor 360° At beginning and the needle got a clutch. Means the Shaft turn whatever the needle is still on endstop and the clutch allow the Shaft to turn "above".
Then after it stops (and the motor turn garantee further as the range of the gauge) the system know 100% that the needle is currently on the Endstop.... So also Calibrated.
(Whatever.... Both is not possible with the Mobiflight given Options)


Maybe a Solution for you is the Endstop itself. If you get access to the front. May you can build something like a button that is combined with this endstop. So if Neddle touch the stopper, then the button is pressed.
If endstop is metal ( and also the needle is metal) you could build a easy Switch.... GRD to Endstop. Pin to Needle. If needle touch endstop it is like a pushed button.
Maybe you can also build this with a little wire that is glued behind the needle and on the side of the endstop.


Last alternate: If we talk about Gauges without a Multiroation.... Then Servos are maybe more profitable.... Specialy if the gauges are slow and remaining in a point most of the time .
So Perfect for a TEMP or Fuel Gauge.... But not useable for Altimeters or Speed.
Good Luck !
2021-02-17 04:15
Avatar
raysot
Posts: 6
That's a fairly complicated suggestion for what is typically an industry-accepted practice with steppers.

It basically amounts to nothing more than rotating the needle one full revolution to the left in the setup() section of the Arduino code. In this way, no matter where the needle was, rotating it left (or right) one full revolution ensures the needle is physically resting on the stop, regardless if the needle was a few millimeters away from the stop or all the way over to the other side. There's no need for wires, sensors, limit switches, etc....

Or:
In the software, provide a button or something that does nothing more than rotate all steppers to the left. It's still a manual process but would be much better than having to manually re-calibrate all steppers back to zero in case of a system crash. (System crashes in simulators happen far more often than I care to say..... which is why I'm pushing for this feature. :-) )
2021-02-17 05:47
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 6010
Supporter
May i missunderstand you.... But how this should work ?

If a stepper turn "one revolution" to the left.... How should the motor know where the endstop is ? If the needle is on half way the "full turn to left" would occure in a situation that the needle is blocked by the physical Endstop but the motor try to still move it.
So technicla "somebody" need to tell the motor to stop.

Also your idea with "All Steppers turn to left until you press a Button" .
Not all Motors are in same position. Some will be far away from the endstop.... Others still reach it.
Same Problem. ... If you hold the button whatever one of the Motors is still on the endstop then this motor get broke in case it try to turn but can not do it.

For your Idea ( without any sensors) i think my idea with a clutch is the only logical..... And sure this would be the best finaly. But those glutches must be included in the meachanic of your gauge.... A Tool in the Software ( Turn 360 to Left ) make only sense for people with that mechanic !
Good Luck !
2021-02-17 07:56
icon