I have made a wooden case to hold both my Xbox 360 and my PS3. It's as wide as both consoles laid down next to each other and as high as the console. it has 2 doors on the front, one for each console. They're both hinged separately from the bottom. What I want to do is to use a hobby motor to open (push) and close (pull) the door open to 90 degrees. The best way I can see is using plastic cord that has teeth on it and a motor that a teethed head on it to lower and pull the door up.

The problem is:

  • how can I control the motor to run for a certain time (so it doesn't just keep running) and
  • how with just one button I can press it and it lowers to 90 degrees and press it again and it will pull the door back up and stop
  • 2
    \$\begingroup\$ Geesh, get off the couch already! If walking over to the thing and manually opening a door is so much trouble, you shouldn't be allowed anywhere near a game console, at TV, or the couch for a while. Find a 5 mile loop and go running. \$\endgroup\$ – Olin Lathrop May 22 '12 at 11:47
  • \$\begingroup\$ @OlinLathrop I think it's more a thing like Pimp my living room :) \$\endgroup\$ – clabacchio May 22 '12 at 12:31
  • \$\begingroup\$ @clabacchio: Then my comment still applies. \$\endgroup\$ – Olin Lathrop May 22 '12 at 12:39
  • 7
    \$\begingroup\$ @Olin - he'll need a motor to open the closet to his running shoes. \$\endgroup\$ – stevenvh May 22 '12 at 12:57
  • \$\begingroup\$ It depends if you want to spend money or time. There are commercial systems available. If you want to make all the electronics yourself, then we need to know how much experience you have, so we know what sort of system so suggest. It's not that trivial if you've never done any electronics before. \$\endgroup\$ – Rocketmagnet May 22 '12 at 12:58

I'd suggest a much simpler solution: buy a hobby servo, attach a long-ish horn to it, and connect a rod from the end of the horn to the door. By adjusting the position of the rod on the horn and the door, you can ensure that at full extension, the servo opens the door completely.

Servos have built in position feedback, so you can control one with a microprocessor and instruct it to move to 'open' and 'close' positions as desired.

  • \$\begingroup\$ i had thought of that, would you recomend it seeing as servo motors are easly controled with a arduino? \$\endgroup\$ – lewis denny May 22 '12 at 13:19
  • \$\begingroup\$ @lewisdenny Yes, ease of control is one of the reasons I suggested it. Pololu also sell servo control boards that interface directly with USB, if that's all you need to do. \$\endgroup\$ – Nick Johnson May 22 '12 at 23:54

You need two more things, apart from your motor and Arduino.

An H-bridge to interface the Arduino to the motor. This is a chip which allows you to control the direction of the current in the motor. You'll just need to select one which is rated for enough current and voltage. Probably the Dual TB6612FNG on a breakout board is the simplest solution for you.

A sensor to detect the position of the door. Probably the simplest thing is to use two microswitches, one which is pushed when the door is fully open, and the other which is pushed when the door is fully closed. Connect them to the Arduino so that it can tell the position of the door.

  • \$\begingroup\$ ok great, im just waiting for my arduino to arrive so i can start experimenting. im going to see if useing a servo will be enough and give me the results. if not ill e useing the info that you've given me here, thanks \$\endgroup\$ – lewis denny May 23 '12 at 3:35

If the door has mechanical limits at the vertical and horizontal orientations, I would just use a cheap dc motor that winds/unwinds a thread that pulls/lowers the door. To know when the door is vertical, you can measure current, and detect an excess of it. About it being horizontal, you don't have to be so exact, since you can just unwind extra thread. Just work by time, when opening. So, close until you detect overcurrent, and open during a fixed time. The overcurrent detection will also "calibrate" your system, every time you close the door.

If the door does not have mechanical limits, or you don't want to detect overcurrent, you can attach a MEMS accelerometer to the door, at a point farthest away from the axis of rotation (so that it moves with the maximum possible radius), and read the signals along the two axes that are perpendicular to the axis of rotation, to know when you have to stop while opening and closing. This way, you will be even able to choose any "closed" and "opened" angles, for the door. However, the "opened" angle should not be much higher than 90º, because otherwise the thread will not pull correctly.

  • \$\begingroup\$ this is a great answer, i hadnt thought about makeing an actuater, thank you \$\endgroup\$ – lewis denny May 23 '12 at 10:51
  • \$\begingroup\$ you can see the scale of the case by the PS3, do you think i would have enough room for enough threded rod? and what youve just said can be controled using a arduino? thanks \$\endgroup\$ – lewis denny May 23 '12 at 10:52
  • \$\begingroup\$ @lewisdenny I would not use a threaded rod. It would be more complex, mechanically. I'd just use a resistent wire, but that can be easily winded (like fishing wire?) and a DC motor with a gearbox included, so that it has more torque, and moves slower. And yes, you can use two analog inputs of an Arduino to read those two axes, and one or two digital outputs, to control the motor (you need to reverse direction). \$\endgroup\$ – Telaclavo May 23 '12 at 11:28
  • \$\begingroup\$ Just as a side note: it may not look as cool as with an "invisible" mechanism \$\endgroup\$ – clabacchio May 23 '12 at 11:32
  • \$\begingroup\$ @clabacchio Invisible like what? \$\endgroup\$ – Telaclavo May 23 '12 at 12:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.