Douglas Adams envisioned a Happy Vertical People Transporter as opposed to the mundane every day elevators
This project was created on 03/18/2014 and last updated 5 months ago.
TODO aka future improvements
Somewhere within the following couple of years the project will be rebuilt with better materials to form a nice conversation piece. The elevator will also be equiped with a sound source to recreate some of the conversations the HVPT has with passengers, and a display to show the floor number where the HVPT finds itself.
The Defocused Computer Perception module will also be heavily improved on. Currently it can only track one object (person) and will (with a very high rate) mistake coming passengers for passengers walking away from the elevator, and vice versa.
I have however learned that computer vision is easier to get started with than anticipated, but it is something that I will have to put much more time into for future projects as there is so much more to learn!
The Defocused Computer Perception (DCP) module is used to 1) detect motion on each floor and 2) determine if the motion is coming towards the HVPT or moving away.
OpenCV2 is used with python bindings to make this work. First three images are read, thresholded and then filtered to decide if enough change is present in them to mark it as motion. Thereafter we calculated the moments of the change (in all fairness, OpenCV calculated it, we just asked nicely). If the moment is large enough, we find the centre point and mark it on the original image (it just looks much better than using the thresholded images). Next the absolute distance between a set point and the moment centerpoint is calculated (thanx Pythagoras). As each frame will not neccesarily show forward motion as the person is walking (shadows, arms swinging etc will muck this up) a list is kept and the tendency is calculated (somewhat ineffective though). This lets the Arduino know via serial when movement is detected approaching the HVPT. All of this is iterated frame for frame over each camera to detect motion on multiple levels by utilising only one script. Obviously in a large building this will need to be improved on by using threads, interrupts and maybe more processing power.
And with this, we mark the end of the HVPT project for the Sci-Fi competition. We will however continue this project later on to round it off way better than it is now, and a spin-off is coming in the form of a yard security monitor OR a pool safety monitor. Who knows, maybe both.
Lolla's part of this project was to build the actual HVPT. Since the first version is more of a proof of concept, most the construction was made out of cardboard box since we had a lot of that lying around. The lift body was constructed out of cardboard with an aluminium foil backing. This backing will later form part of the level detection.
The elevator shaft was also constructed from cardboard box, and 680 ohm resistors were placed in pairs to form a resistor ladder. You can see in the pic below how the legs protruded to make contact with the aluminium foil backing when the lift body moves to a level. The resistors were soldered into a series connection, making two rows of resistors, one down each side. In theory, the 5V will be put over the the complete resistor ladder as well as one extra resistor, effectively creating a voltage divider between the ladder and the referance resistor. All resistors being 680 ohm. Why 680? Well, we had lots of them, so they won the opportunity :)
As the lift body moves past a pair of resistors, they form part of the voltage divider, and thus the Arduino's ADC can determine the current level. The contact points were made on the bottom of each level. In retrospect, halfway might have been better, but I will leave this for DigiGram to fix with code.
Thank you. I borrowed the idea from one of the most expensive level detectors I've ever seen (and I work in the oil field, we have some crazy expensive electronics). This one was made up out of 100 reed switches, and a resistor ladder to connect it all up. Surrounding the whole thing was a floating magnet. Very simple, but cost waaaayyyy more than reed's and resistors would :)