Hack a Mousetrap with Windows 10 Internet Of Things

Sign in to queue

Description

Recently DX team members from Microsoft Canada took part in the DevOps Hackathon.  Our hack was to literally build a better mousetrap by connecting a Raspberry Pi to record the number of times a trap is set off and where the trap has been set off.  The data is fed through IoT Hub, stored in Azure SQL and then fed to Azure Machine Learning to provide predictions as to when the traps would need to be emptied. The solution also provides a floor plan heat map via Power BI as to where the best places would be to set the traps. 

*Update: 04/01/2016 - As requested, the GitHub repository can be found here: https://github.com/jefking/MouseTrapp/

Embed

Download

Download this episode

The Discussion

  • User profile image
    Felininho

    Leave the rats alone!

  • User profile image
    PenGun

    Indeed. The perfect large scale rat trap is a big box in the middle of the floor, this is warehouse stuff, with a platform nearby with some bait. The platform is really a catapult, and lofts our friend into the big box. As it's some distance from the platform the rats never connect the place where their friends are trapped with the trap. Last time I heard the record was nearly 500 rats at some large establishment.

    Go ahead, network your silly traps. Hell get to work, we need a TCP/IP over rat protocol to go along with Coxies TCP/IP over carrier pigeon. Real tunnels.

  • User profile image
    PaddyJoe

    A simple but informative model of an IOT technology stack for people that need entry level orientation and awareness.  Nice work.

  • User profile image
    John Arnold

    Mitraad misses Lincoln
    The five-year-old was a best-priced 9-1 second favourite for the first big handicap of the Flat turf season at Doncaster on Saturday despite having had just three races.

    "I don't think he's quite ready to win. I'll just give him a bit more time," said Haggas "We'll see how he goes, but he's not far off ."

    The Newmarket trainer reports his other Lincoln entry Predominance to be on course for Doncaster.

  • User profile image
    ZombieVoyeur

    Really? Windows 10?

    Seriously, why would you bog down a Raspberry Pi with bloatware given that the memory space is 1Gb RAM?

    There is more efficient ways to platform mousetraps than trying to squeeze it into an ARM micro-architecture. Raspberry Pi is designed for Linux, Unix and has long established 'mousetrap' packages.

    The fact that your using warehouse powered Azure platforms proves that you have more money than sense.

    Lastly, it is annoying me that corporations like Microsoft cannot keep their hands of the free flow and open source community that is IoT, stick to clunky enterprise apps.

  • User profile image
    ZombieVoyeur

    @Felininho: If there using Windows 10 then there would be little threat to the fury critters. It would be more likely the mice would sit dumpfounded as Windows 10 slowly consumed all the memory food.

  • User profile image
    Ian Young

    Classic Micro$oft, throw excessive technology at a problem that has an effective, proven mechanical solution. A database for a mousetrap!!!

  • User profile image
    Zombie​Crusher

    @ZombieCrusher Stop being a hater you bitter twisted little individual. If you don't like Microsoft, Windows 10 IOT and RP2, then why on earth are you reading this article? Perhaps you should go back to Linux and write yourself an open source spell checker...

  • User profile image
    Shinkou​Ookami

    @ZombieVoyeur - This is Windows 10 IoT Core, it's vastly slimmed down over the regular Windows 10 OS and Microsoft let you have it for free so whats the problem? it's not like they are charging you.

    And seeing as you are such a Microsoft hater I assume you don't use an ATM/Cash machine, because it might surprise you to know that a vast number of them run Windows NT.

  • User profile image
    brolleke

    if Microsoft  wants to enthousiasm people to make use of its Windows 10 iot, it should demonstrate it through a really usefull project (instead of a clusterbomb to kill a fly) and show us that Windows 10 solves the problem and implements that project better than it could be done with the native Raspberry-operating systems...

  • User profile image
    Terry Piper

    For very intelligent people this is a very dumb idea. Developing a project to kill any animal has to be questioned, you could have turned this project in to an environmental monitoring of said mice and rats for example.

  • User profile image
    Eric Brightwell

    It is true that if you are clever enough and have sufficient resources you can program any hardware to do anything using any software. However, in the real world all we want is software that is easy to install and always works with the hardware which we happen to have available, and has a simple intuitive interface which enables us to do what we want without having to read more than a page or 2 of a manual. We do not want additional functions that we are unlikely to use and which make the software more complicated than necessary. Unfortunately, one size does not fit all and never will.

  • User profile image
    NoNoNo

    Dude, this is a demo project, it doesn't matter what the subject is, it's the topics they're covering that are important. This is Microsoft, we are Microsoft devs, we don't care about Linux, we don't care whether Windows can utilise the Pi better than a Linux based OS, we're just interested in what we can with OUR native system and the languages that we use every day. I for one would not be interested in the Pi if Microsoft didn't provide an IOT version that runs on it, moreover it is the fact that Microsoft provided IOT that got me interested in the Pi at all. It's tiring listening to guys like you hate on MS products, why don't you just be happy that there are other options out there for people from different backgrounds; and if you can't even do that then please, do us all a favour, and just steer clear of discussions like this altogether.

  • User profile image
    Virginia

    I'm already thinking of ways I can do this in my home with the traps in the garage. Guess I'm heading out to GitHub to find the code unless the guys who put this together would share? Nothing like a project like this to get your hands dirty in the IoT.

  • User profile image
    Random​Opinion

    To all the critics out there, I think this mousetrap video worked well to show in the comments who has a problem thinking out of the box on the concept or in integration with various technologies.

    1. Some individuals take a simple product (mouse trap) and add a lot of functionality to the 'triggering' of products.

    2. At timestamps 10 mins and 13 mins, you start getting to the point of how something so simply using the relatively often ridiculed IoT concept to have value.

    There are tons of products that can have value with these concepts (adding IoT to devices, getting it to a database, building the analysis, etc). In this exact scenario? I can easily imagine Pest Control companies laughing at a 'internet mouse trap'....Then realize they know how often it gets triggered, which ones get triggered, where it gets triggered and which ones may need to be reset...multiply this by how many clients and they may be very interested in saving money instead of paying workers to do rounds and checking traps, etc.

  • User profile image
    Pi starter

    This is a great example of how we can think of IoT applied into non-existing and funny area even though it may be dump idea. HOWEVER, I could consider this app to work with food and safety inspection for food industry to collect big data rather than killing but monitoring. Any thing better than thinking regardless OS or design language... nice job.

  • User profile image
    Interest of Things

    Neat to see a use case, but boy are there a lot of haters. And goodness, if you're going to post in a public area, make sure you're using proper grammar!!

    You're ≠ your
    Their ≠ there

  • User profile image
    Nottinghams​hire

    The mouse in Nottingham eat electric cables before food!!!

  • User profile image
    Jhall007

    OK, yes it is silly to make a huge project out of a mousetrap (especially when the electronics will probably snap if there is no mouse in the trap or if any liquid from the animal should escape and short something out).This kinda reminds me of the "Hello World" program in Basic.

  • User profile image
    Lubenz

    Many ways to make this cool mouse trap.
    Here is my version of the IoT mouse trap. ESP8266 communicate with the raspberry pi. So you dont need to hardwire it. http://hindberid.is/index.php/arduino/85-esp2866-wifi-sendir-post-vidh-raesingu-2

  • User profile image
    Kevin in Phoenix

    It is unnecessary to predict when the traps need to be emptied since you know in almost real-time when they are "full". Profiling by time of day and showing increased/decreased trapping over time would be useful to show activity and if the mouse population is being reduced. Every mouse trapped will have an affect on the current and future population.

  • User profile image
    fxv300

    If a mouse sets of the trap the mouse insulates the contact points.

  • User profile image
    JOhnK

    this must be most the worst time wasted ever. Have you nothing better to do. Go and do some work

  • User profile image
    Robert Amine

    Right on NONONO ;-) interesting little article... just for fun, might dust off my PI and give it a little test with Win10 ;-)

  • User profile image
    Martin Bolbroe

    It apparently hasn't occurred to anyone that it is April 1st. today :) :)

  • User profile image
    JackCr

    It is truly disappointing to see Microsoft and it's staff waste time on almost pointless exercises like these. Internal functions appear to have learned nothing from Windows Phone and Robotic studio. 

    How about designing an OS imaging system for RPi with PXE based network boot and image load for any OS. Don't force the hobbyist into the largest possible configuration based on Microsoft product use. Finesse them by supporting extensions to what they have now and attract them to Windows 10 as a development environment and the IoT hub and cloud data features.

    Enhance the Python environment for Windows and produce a decent stack for intercommunication between a whole range of OS's and development languages. Who know's Windows 10 may win in the end, but it won't if you just foster the Windows only environment.     

  • User profile image
    iLikeAzure​SQL

    Can you give a little more description to reference to where can I get more info on setting up Raspi with he configuration you used for this demo? how to connect to IOT hub?

    I want to re-do this demo for our folks, this is a end to end demo for IOT solution

Add Your 2 Cents