Notifications
Clear all

Manually moving stepper motor

30 Posts
3 Users
9 Reactions
227 Views
Horst
(@horst)
Member
Joined: 4 weeks ago
Posts: 9
Topic starter  

Hello all, I hope this question hasn't been posted before. I looked through the forum and couldn't find anything.

I am going to run a Nema 17 stepper with the TB6600 stepper motor driver. Very similar to the one Bill uses in his video titled "Big stepper motors with Arduino".

I am building an electric elevator trim for one of my simulator cockpits. I plan to use the stepper motor to move the trim wheel when the autopilot is engaged (or pilot uses the electric trim knob on flight yoke). However, I also need to be able to manually move the trim wheel. I was wondering if I rotate the stepper motor manually, if the generated current (from the stepper) could negatively affect the motor driver?

Thanks

Horst


   
Quote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@horst I doubt it, but I am not an expert. There are no contacts involved, just electro magnetic fields. Have you googled it? 

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
Horst
(@horst)
Member
Joined: 4 weeks ago
Posts: 9
Topic starter  

@zander Thank you Ron, yes, I Googled it and the opinions are as diverse as there are pages about it. My understanding is also that the power supply for the stepper is independent from the rest of the board. I guess I will give it a try and see.

Horst


   
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1778
 

Hi @horst,

  Remember that if the driver is powered, unless you have disabled the driver, then whilst is powered, it will 'usually' be supplying current to the motor, which will resist attempts to manually move the motor shaft. In many cases, (depending on current settings, motor size, etc.), unless you have considerable leverage or gearing to assist, you will not be able to move the shaft! Of course, it is possible to disable the driver on command, but in many cases, the driver will be continuously enabled.

If the motor is not powered, then moving the shaft will cause the motor to act as a generator, and the voltage might become high enough to damage the driver. In reality, this is probably a low risk, and I would hope a commercial driver unit would incorporate sufficient protection for any 'normal' event. But the designer of the driver has no control over the motor, etc., and the speed at which the shaft is rotated, so the risk of damage occurring cannot be completely discounted for all circumstances.

You do not fully describe the circumstances that the shaft will be driven manually. If it is only during operations such as mechanical assembly, then it is difficult (but not impossible) to imagine an occasion that you would have a problem.

However, I think you are stating that it is in 'normal' usage, implying the stepper motor control will need to be carefully managed to give the appropriate effect(s), as you are 'balancing' two forces, the electromagnetic force controlled by the driver and the manual applied force. Stepper motors are commonly used for operations like mechanical 3D printing or drilling, in which the motor is required to faithfully move and hold each commanded position, totally overcoming any forces like friction and inertia. That is, the electromagnetic force is designed to comfortably overcome any external force that can be exerted on the motor shaft.

However, I think you are suggesting, the motor should generally supply enough force to overcome friction, gravity, etc., but not enough to prevent a pilot manually applying a contradictory force. This is a far more subtle system.

In principle, most drivers provide some adjustment for current, and hence the torque that the motor can apply, but your requirement may require a more flexible adjustment capability than many drivers will provide, at least in their standard configuration. Of course, this is little more than wild speculation on my part, as I do not know your mechanical design, etc.

Best wishes and good luck, Dave


   
Ron reacted
ReplyQuote
Horst
(@horst)
Member
Joined: 4 weeks ago
Posts: 9
Topic starter  

@davee Thank you, I really appreciate the insight. This is what I read in other forums as well.

From a mechanical point of view, the larger trim wheel has a sprocket and a chain that connects that sprocket directly to a sprocket on the shaft of the stepper. At the back of the stepper, a potentiometer (with 10 rotations) is attached to the shaft of the stepper so I can measure the rotation/angle of the main trim wheel. The main trim wheel only rotates about 2.5 times each way (up or down).

There are three scenarios:

1. The driver is disengaged via commands from Arduino. There shouldn't be any voltage applied to the stepper, hence, the pilot can manually rotate the wheel. The rotation/angle is read by the pot as the stepper motor shaft is rotated. This feedback is used to interface with the simulator software.

2. The pilot engages the knob on the flight yoke (UP/DOWN), which then engages the driver and stepper motor to move in either direction (via Arduino). Again, the pot reads the position and feeds back to Arduino.

3. The autopilot is engaged, which sends commands from the flight simulator through the Arduino to move the stepper left or right. The feedback from the pot is used to determine when to stop the stepper.

From looking at force feedback systems, I can see that stepper motors are used to move and provide "resistance" to movements for flight yokes. I assume that a small amount of voltage is applied to the stepper motor to "resist" the movement and at the same time bring it back to its intended position (determined by the flight simulator software).

 

Horst


   
Ron reacted
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@horst I went back and re-read your OP plus looked at @davee's post and Dave hit the nail on the head. Unless you kill power to the stepper, it will be very hard to move by itself let alone if there is any gearing involved.

I never flew anything that had elevator trim that worked that way, but maybe you know how it is done in a real plane? My SWAG is the wheel electric trim switch causes a mechanism like a car starter to pop out a gear so that when not engaged there is no electric motor impeding manual operation. The balance of the system is designed to have enough friction in it to keep the trim tab stationary probably through the use of a lot of cables and pulleys. If that is how it works IRL, you can do the same in the model.

The difficult part will be making the stepper 'pop out' so that the gears mesh. IIRC the car starter uses a return spring and then centrifugal force? cases the starter pinion to pop out and mesh with the engine's flywheel.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1778
 

Hi Ron @zander,

  I agree with your comment immediately above, but in addition to the 'on' / 'off' situation you describe, I was suggesting it might be possible to adjust the electrical current to provide a 'measured' force, that could be overcome by a manual input, thus not limiting to the cases in which mechanical friction, etc. alone provide the stability required when the electrical drive is disabled. It may also overcome the problem of determining when the electrical drive should be on or off, which for something like a realistic simulator, may be tricky, if the 'real thing' does have any need for switches, etc.

However, because this is an unusual requirement, it might be practically difficult to achieve, without hardware modifications, etc.

Also, the motor may exhibit a 'snatching' feel, when the manual override causes it to jump from one pole to an adjacent pole. The extent to which this is apparent depends on many factors, including gearing, amount of electrical torque and so on, so this would be a very experimental development.

Best wishes, Dave


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@davee I think you are right, controlling the current will reduce/increase the torque, BUT how does the MCU know that the operators hand is on the wheel?

The 'real' thing does indeed have a rocker switch on the wheel. That is why I suggested a car starter type mechanism. The modern Auto Start/Stop may be a good model but is probabky very expensive.

Yes it will be 'grabby'.

The reason for the wheel is to make quick large adjustments, the wheel rocker switch for fine tuning as in adjusting for fuel consumption. Some pilots prefer the rocker switch for fine tuning, others the wheel. It's sort of an analogue vs digital choice.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1778
 

Hi Ron @zander,

   I would look to the approach, that the aircraft that is being simulated uses, to determine how the system alternates between auto and manual control

This might result in an impossible challenge, but that would be my first step. e.g. Does the pilot flick an 'auto-off' switch or simply move a control, to take manual control. I am not suggesting this will be trivial to achieve, but if it can be done on a real aircraft, then it can probably be simulated. I would expect this to reveal some fundamental differences in approach used by different aircraft designers.

I am suggesting that if stepper motors are used to simulate the physical (haptic) feedback, then it might require more precise and complex control of the electrical current flows to the motors than is required for more typical applications, such as 3D printers or robots. Whilst I would expect it to be possible with straightforward engineering, it may require hardware design and construction skills, as well as software.

Best wishes, Dave


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@davee Sorry, my previous explanation was insufficient. The electric motor drive is controlled by a rocker switch, OFF in the center, direction one to the top, direction 2 to the bottom. Remembering that the electric drive is spring loaded, and the rocker is self centering, whenever the rocker is not pressed, it is off and the spring disengages the stepper from the trim system so it is free to be moved now by hand.

Does that help?

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@davee Oops, I just noticed something, you said AUTO, there is NO auto in this scenario, in fact for various reasons the auto system can be slightly off so we have trims. There is elevator trim for up/down, rudder trim for yaw and aileron trim for roll control. The later can happen if there is more fuel in the left wing than the right for instance. Keep in mind modern commercial craft will have a high degree of automation in fuel management for the purpose of overall aircraft balance, but for some period of time there may be sensor lag but the human balance system can sense it so the pilot can make manual adjustments. Pilots do this fairly constantly without even thinking about it.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
(@davee)
Member
Joined: 3 years ago
Posts: 1778
 

Hi Ron,

  Sorry, but maybe you have a particular control in mind. I was imagining the different approaches used in jet aircraft, some of which (I think) still use mechanical linkages to flight surfaces, etc., whilst others use joysticks, etc, with the flight control systems having the authority to overrule the pilot.

My comments will not be applicable in all circumstances, as I don't know enough about the actual cockpit to be simulated. I merely point it out, as being a possible problem to consider, whilst planning a project that seems to be using stepper motors.

Best wishes, Dave


   
ReplyQuote
Horst
(@horst)
Member
Joined: 4 weeks ago
Posts: 9
Topic starter  

Thank you all for your replies. My postings are currently being moderated as I am a new member, that's why you are not seeing my responses.

I am converting a discarded King Air 200 airframe into a simulator. I spent many hours talking to the pilots regards the electric elevator trim. In summary, there is no haptic feedback for the trim wheel, it moves somewhat freely (with some friction) when the pilot adjusts the trim manually. He then uses the rocker switch on the flight yoke to further adjust if necessary, especially to achieve level flight (without autopilot). When the autopilot is ON, it uses the same motor to adjust the trim so there is a visual indication for the pilot on where the trim is.

From what I understand, in a real airplane, all this achieved through the use of servo motors and cables. Everything is mechanically connected all the time (no pop-in or pop-out of the motor to rotate the wheel). The difference is where the signal to "move the trim wheel" is coming from (manual, rocker switch or autopilot). If the autopilot is flying the plane (and adjusting the trim) and the pilot engages the rocker switch (or manually moves the wheel), the autopilot is automatically disengaged.

I have done this system with a previous simulator (

and (

The difference with this one is that it already had the gear system for the elevator trim built-in, I just needed to control the DC motor via an H-Bridge.

Arduino and the Flight Simulator are constantly checking trim values, so it is relatively easy to "capture" the different scenarios via the Arduino code. The new aspect for me for this simulator is the use of stepper motors instead of a DC motor driven gearbox.

 

Horst


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@davee Hydraulic/mechanical linkages still dominate for sure and work more or less as I described. Of course there are newer 'joystick' fly by wire systems even in commercial passenger jets. The modern day fighter jet may in fact have computer control overrides so that the pilot does not cause hiomself to black out in too tight a turn.

However, none of that is what the OP is talking about, he is asking about the standard trim system with a rocker switch on the wheel, and a hand wheel on the center console IIRC.

I have no idea why the OP suggested a stepper, it could just as well work with a simple DC motor but without knowing a lot more about his cockpit in terms of size, degree of reality desired and probably some unknowns it is hard to say.

I suspect that a fly-by-wire or sidestick system does not have mechanical trim controls, they too will most likely be electric. Since I have not flown one of those I am just using my best guess and experience.

I based my model off the OP's comments, it sounds to me like he is describing a common cable or hydraulic and cable system.

In any case, let's stay on point, can he design a trim system where the manual wheel is not going to cause damage to the stepper? As has been pointed out the answer is yes since the motor will either be mechanically disengaged or powered off.

NOTE: Boeing does NOT use sidesticks, but Airbus does as does the F-16 and F-22 to name a couple. Keep in mind that although the Boeing 777 still has a conventional yoke, it is in fact a fly by wire system.

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
Ron
 Ron
(@zander)
Father of a miniature Wookie
Joined: 4 years ago
Posts: 7358
 

@horst Your videos are throwing an error, see pic below.

It sounds like you are well experienced. All I might suggest is creating some modules to convert a DC gear motor instruction into a stepper sequence. This way the higher level code will look like your other cockpits and can even be copies of the code with the new stepper code translation modules doing the hard part (just name them one character different usually at the beginning or end so your call goes to the right place)

 

 

 

Screenshot 2024 06 04 at 19.22.03

First computer 1959. Retired from my own computer company 2004.
Hardware - Expert in 1401, and 360, fairly knowledge in PC plus numerous MPU's and MCU's
Major Languages - Machine language, 360 Macro Assembler, Intel Assembler, PL/I and PL1, Pascal, Basic, C plus numerous job control and scripting languages.
My personal scorecard is now 1 PC hardware fix (circa 1982), 1 open source fix (at age 82), and 2 zero day bugs in a major OS.


   
ReplyQuote
Page 1 / 2