I'm looking for some simple schematic for movement detection.

I want to use it with a small hobby project of my own to detect if someone is moving the box, doesn't matter the direction. I'm looking for simple and (preferencially) cheap.

I'm not looking for accelerometers or gyroscopes. The most simple solution that I've found for this is a tilt switch, but I couldn't find if it's the simplest solution.


I've found out that piezo sensors are also used as a vibration detector: What's the cheapest way to detect vibration with Arduino?

Do you think that it could work for me? In this case, the piezo could be attached to the plastic box.


Following @Kortuk advices, here's the original idea and the one I want to be able to do:

I have a box with my system inside (in this case MCU, bluetooth and a USB connector). The box doesn't exist yet, so I don't know which kind of box could it be, this is just an hobby project to play with stuff that I've never played before.

My goal it's to have a pin that will be active when someone moves the box, and that could be change it's place, tap it or even moves the table where the box if. I have no problems with some false alarms, if the box it's going to be attached to a wall and some guy starts drilling the wall, the pin could be activated too.

I'm looking for the simplest solution.

  • \$\begingroup\$ Vibration is very different from movement in the classical sense. I would say that maybe you should explain what kind of application you need to detect motion in with detail and not get the cart ahead of the horse with guessing for solutions in the question. Is this a device that should never be moved? Is it going to be placed somewhere and have a sensor that detects movement after being moved without need for internal reconfiguration? Details give great answers. \$\endgroup\$
    – Kortuk
    May 12, 2012 at 17:48
  • \$\begingroup\$ @Kortuk: my initial idea was to detect if the box is moving, doesn't matter where. I already do that but with an accelerometer. Then I read about this piezo sensors and I thought that I could use one of those to detect motion and ambient vibration. \$\endgroup\$
    – rnunes
    May 12, 2012 at 18:02
  • \$\begingroup\$ I am trying to explain that you get the best quality answers if you post a thorough explanation of the problem you face and avoid explaining what you think the solution is. The users here know a large deal about these things, compared to most I am an amateur. What is the acceptable tolerance for false positive and for false negative? How far is moving? Is this going to be in a location that has large amounts of vibration? What power consumption is acceptable? \$\endgroup\$
    – Kortuk
    May 12, 2012 at 18:05
  • \$\begingroup\$ just wanting you to get the best possible answer. \$\endgroup\$
    – Kortuk
    May 12, 2012 at 18:06

2 Answers 2


There are accelerometers that are designed with the application in mind. There are many options available out there but a couple that might be useful:

  • Raise an output high whenever acceleration is above a certain amount and lower when acceleration stops.
  • Raise output high when acceleration is above a certain amount and output is kept high until a command is sent to clear.

Both these are designed for this application to give you as simple a circuit as possible and I suggest them compared to other options but you might have reasons to need a mechanic tilt switch.

  • 2
    \$\begingroup\$ For fun, you make an acceleration detector with a piece of bare wire with a little weight on it, poking through the loop in another piece of wire. Seems like a no-brainer. Object moves, weight's inertia causes contact with the loop. One of these covers the x-y plane, and one more gives you z coverage. \$\endgroup\$
    – Kaz
    May 12, 2012 at 2:19
  • \$\begingroup\$ @Kaz, sounds pretty cool. I was answering what I have seen as a solution for making many of these. I would have made it a comment but, alas, they have formatting limits. Many people do not realize how many features accelerometers have, they have become very impressive in their own right. Making detectors yourself not very functional for a group of products, but for at home tinkering I think the decision is a no brainer. \$\endgroup\$
    – Kortuk
    May 12, 2012 at 2:50
  • 3
    \$\begingroup\$ @Kaz, that plus a simple circuit would make a pretty good answer on its own. \$\endgroup\$
    – Kortuk
    May 12, 2012 at 2:54
  • \$\begingroup\$ The weight-on-a-wire requires a particular orientation of the installation. Otherwise gravity would pull the weight into the loop. \$\endgroup\$
    – user9224
    May 12, 2012 at 13:27
  • 2
    \$\begingroup\$ @scorpdaddy - Not necessarily. You can mount it any way you want. Inertia works in any direction. \$\endgroup\$
    – stevenvh
    May 12, 2012 at 13:45

Hacking a mouse and get the x,y delta output might be a cheap option if you already have one sitting around. Adding some IR sensors might help to make sure it is a living thing that is moving the box, if you need that.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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