New to Microcontrollers / Robotics

Hey folks,

I’m very new to the micro controllers / robotics world but eager to learn. Wanted to start off with a simple project of opening and closing a box lid (90 degrees) w/ a switch.
I’m coming across some design / hardware issues I’d like some assistance with (hopefully this is the right place to ask these questions!).

Project Scope:
Simple cardboard box (5" x 5" x 5").
An On/Off Switch resides outside the box.
Turning it On, open’s the lid (90 degrees).
Turning if Off, closes the lid.

My Design:
I was going to have a servo connected directly to the pivot point of the lid, as to control the opening / closing. Seemed like a simple thought (if otherwise please correct me).
All the electronics could reside inside the box. They don’t need to be hidden elsewhere.

My Issues:
How do I program the switch / microcontroller to flip the lid open and back when in on/off position and then cut the power? I’ve heard the controller will cycle through its rotational limits when power is applied? (lack of experience, please excuse the novice statement)

When the lid is closed. How do I prevent someone pushing down with a finger and back-driving the servo (damaging it?) - I initially assumed a high torque servo would counteract a certain amount of force (correct me if I’m wrong please).

My current shopping list:
#1352 Mini Maestro 12-Channel USB Servo Controller (Assembled)
#2832 Pololu 6V, 1A Step-Down Voltage Regulator D24V10F6
#1057 Power HD High-Torque Servo 1501MG
#1154 4-AA Battery Holder, Back-to-Back
#1930 Female Crimp Pins for 0.1" Housings 100-Pack
#1900 0.1" (2.54mm) Crimp Connector Housing: 1x1-Pin 25-Pack

Hello,

You might look at the “Using a button or switch to control servos” example in the “Example Scripts” section of the “Pololu Maestro Servo Controller User’s Guide” to see how you might program your Maestro for an application like that.

It is not clear from your description how the lid is supposed to move, but you might look into placing a physical stop to prevent the door from moving. If you can more clearly describe how your door is going to move, I might be able to offer some additional suggestions.

In looking over your parts list, I do not see how the regulator you have would be helpful. You might consider a 6V step-up regulator as a substitute to the step-down you chose.

If you want to learn more about servos, you might take a look at this helpful series of blog posts.

-Derrill

Thank you Derrill.

I’ll try the physical stop and the codes - I think that’s what I need.
The final product would be in my car’s trunk. I was going to power the servo and controller from my car’s battery. Hope that makes sense?