Smart Mirror Using Broken Android Tablet

20,002

319

21

A while ago I accidentally dropped my Android tablet on its face. The glass broke, but the rest was still working fine. At the risk of being called a hoarder by my partner once again, I put it in a draw, hoping I'll find a use for it some day. That day came when I got a "staff's picks" email from Instructables with a link to this cool Smart Mirror project https://www.instructables.com/id/Android-Motion-Se...

There are many similar projects posted, and mine is not the most impressive one. Quite the opposite in fact, I just wanted to stick a tablet behind a mirror, download an app and be done with it. But nothing is simple, isn't it? Turns out my tablet was sitting in a draw for far too long and there are no apps that would work on Android v2.3 (Gingerbread) any more. So I had to write it all by myself. It was my first Android (and Java) project so please don't judge.

The physical assembly was fairly simple to implement. I stripped the tablet even before I ordered the parts to make sure I can mount it easily without the glass. Turns out that the glass is separate from the LCD screen and comes off quite easily. At the same time, all the components like PCB, battery and the screen itself were nicely packed together so no extra mounting was necessary. I've found that the touch sensor however, is glued to the glass. But as I didn't intend to have interactive mirror that was OK.

Step 1: Shopping List

As I mentioned I already had a tablet - Scroll Excel 7-inch, but any tablet would work equally well or even better. In addition to that I had to buy:

  1. A3 size photo frame from IKEA
  2. Two way acrylic mirror sheet A3 from ebay
  3. Black fab foam sheet A3 from HobbyCraft

I also used:

  1. Stanley knife
  2. Super glue
  3. Sandpaper
  4. Drill with small drill bits
  5. Dremel and a mini hacksaw

To avoid any complications I bought the picture frame first. I suspected that dimensions in the description might not be accurate and I was right about that - the dimensions were given of the inside of the frame, not the size of the glass or the backboard.

I chose to buy acrylic sheet with semi-transparent film already deposited as I read some stories of people struggling to get good quality out of glue-on film. Have you tried to put a screen protector on your phone? I think its impossible to get clean results without actual clean room.

Step 2: Preparation

So the first thing was to disassemble the frame itself. I was surprised how easy that was with little clips all around the sides. I think this worked out in my favour as some frames have backboard that slides in and out, which could potentially scratch the fragile mirror coating.

Then I measured the acrylic mirror sheet and cut to size. The sheet has protective film from both sides so cutting was fairly easy (though, you still have to be careful not to make any deep scratches). I used Stanley knife to score the sheet and then snapped against the edge of a wooden piece. It wasn't a clean cut and produced some sharp edges, so I carefully smothened them out using some sandpaper. Be careful here as acrylic has tendency to crack and shatter more than you would expect from plastic.

I only had to cut the mirror sheet length wise as the width was almost perfect for the frame and it only had a couple of millimetres of play. To make sure it doesn't slide around I used some insulated wire bits on both sides.

To protect the mirror sheet from scratches I've added a sheet of black fab foam with a cut-out a couple of millimetres smaller than the LCD screen to avoid any edges being visible. Initially I tried to reuse a white inner board that came with the frame, but white colour could be easily seen against the black LCD screen, especially in daylight.

You might notice in some of my photos I had a cushion under the frame. I realised a bit too late that the acrylic sheet is very flexible and while the frame kept it above the desk top, sometimes the sheet would touch the surface and get scratched up. The scratches are barely visible at the moment but it nags me every time I clean it. You have been warned.

Oh, and don't forget to take the protective film off when assembling. I read a few reviews that complains about the mirror not being reflective or clear at all. That made me chuckle a little :)

Step 3: Mounting the Tablet

I've mounted the tablet directly into the backboard. Its a 3mm hardboard so it has enough strength to support the weight of the tablet. Cutting the board was easy with a hacksaw and a Dremel tool, though I had to be careful not to make hole too big.

Even though I'm not planning to use the camera, I chiselled out a small hole for it just in case. Then I glued some bits of leftover hardboard with super glue where I was planning to mount the cover. You might notice couple of plastic mounts there as well. Due to electronic components around the mounting holes, I could use only a small amount of material and I didn't think the hardboard would hold. So I found some old plastic box and cut pieces out of that.

Finally I screwed the original back cover of the tablet. It doesn't seal it perfectly, but it provides good support and protection for all the components while still giving me the access to connectors and the power button.

Step 4: Software

Considering that most applications out there are for Android v4 or higher, I had very little chance to find a Smart Mirror application that would work on my tablet. Upgrading the tablet was not possible either, so I decided to download Android Studio and develop application myself. Disclaimer - I am full time .NET developer, so even though mobile and Java development is new to me, the learning curve was not as steep as it would be learning programming from scratch.

Describing the whole source code would be a topic on its own. Let me know in the comments if you are interested and perhaps I'll make another post. But for now, I will only explain my requirements and basic functionality. By the way, the source code is available on GitHub (https://github.com/audrius-a/smart-mirror.git). It is published under MIT license so please feel free to fork it and use for your projects.

My requirements:

  • Must show date and time;
  • Must show day and night temperature forecast 5 days ahead;
  • Must show weather conditions 5 days ahead;
  • Must run continuously without user interaction even after reboot;

To achieve the above I signed up to Met Office DataPoint which provides free weather updates that are pretty reliable, even for the unpredictable UK weather. Signing up is very easy and they provide you with an API key right away allowing to query data almost immediately. Check out app/src/main/java/com/development/audrius/smartmirror/MetService.java file for the exact query I used.

To display weather conditions I used free icons from http://www.alessioatzeni.com/meteocons/ shared by Alessio Atzeni. Thanks Alessio, for publishing these icons, they are great.

I thought the biggest struggle will be with the last requirement of keeping the application always on top. Turns out, it is very easy with a couple of permissions in the AndroidManifest.xml file and a StartupHandler class. Even if the tablet dies for any reason or simply needs a reboot, the application comes back on just a few seconds after the startup and stays on forever.

The only outstanding issue I have so far is the WiFi signal disappearing after a day or two. I believe that was the case in the past and perhaps my only option would be to reboot the tablet after a few failures to connect to the internet. I'll update the post once I get it resolved.

Step 5: Summary

I hope you've enjoyed reading this instructable and perhaps even learned something or got inspired. Please feel free to leave your feedback or any questions in the comment area.

Share

    Recommendations

    • Make it Glow Contest 2018

      Make it Glow Contest 2018
    • Plastics Contest

      Plastics Contest
    • Optics Contest

      Optics Contest

    21 Discussions

    0
    None
    jacobz_20

    11 months ago

    The misspelling of super glue as "supper glue" had me confused for a minute there. I mean, what the heck is supper glue?!
    Nice build. Good job working around your limitations. I hope you figure out a decent solution for the Wi-Fi issue.

    3 replies
    0
    None
    bcarpenter1jacobz_20

    Reply 6 days ago

    "Supper glue" is what I call my wife's mashed potatoes

    0
    None
    audrius-ajacobz_20

    Reply 11 months ago

    Fixed. Thanks for spotting.I assure you there was no food harmed in making this.

    0
    None
    viveba

    11 months ago

    Thank you very much for your contribution, for some time I was looking for information about this type of mirrors, and your work is very clear and convincing. To the point that I started loading old tablets into disuse ...

    Sorry for the Google brand translation, I hope you understand!

    Muchas gracias por tu aporte, hace tiempo que buscaba información sobre este tipo de espejos, y tu trabajo es muy claro y convincente. Al punto que ya me puse a cargar viejas tablets en desuso...

    Perdón por la traducción marca Google, espero se entienda!!

    1 reply
    0
    None
    audrius-aviveba

    Reply 11 months ago

    Thank you for your kind words. Good luck building your own version, its fun. Please don't forget to share once it's done.

    0
    None
    12chilies

    11 months ago

    Impresses the heck out of me.

    0
    None
    bcarpenter1

    11 months ago

    Without a touchscreen how did you install the weather software and configure the tablet?

    On a side note, I hope no one realizes you have a camera hidden behind that mirror :)

    2 replies
    0
    None
    audrius-abcarpenter1

    Reply 11 months ago

    I had the same concern, but turns out Android Studio installs application when running on device. I just need to connect USB cable to it. Oh, and I had to enable development mode on the tablet itself. Of course, I kept the touchscreen just in case I have issue I cannot resolve via code, like time settings.
    Indeed, no one can tell there is a camera. That will be my little secret :)

    0
    None
    AlexanderP124audrius-a

    Reply 11 months ago

    Although not all, but many tablets, including very old ones, support USB-OTG, also called USB-host. So with a cheap USB-OTG adapter such as https://www.amazon.co.uk/female-Micro-Adapter-Cable-Function/dp/B009DFCCKO/ref=sr_1_5 you can connect a usual USB mouse and even keyboard, if you'd like. This can be very helpful if the touch panel is not working.

    0
    None
    SeanG113

    11 months ago

    Dude! Truly awesome! I knew I've kept my busted screens for a reason!

    0
    None
    Bigslik

    11 months ago

    I have grandkids so I've thrown at least 3 away. Not hoping for another but if I do.

    0
    None
    Gandolf the green

    11 months ago

    how do you power it? do you just wait for the battery to run down, or do you have some power system rigged up to power it.

    nice project, i can think of a few pranks that this could be used for. also like the idea of a notification system that doesn't involve a phone

    overall good job

    1 reply
    0
    None
    audrius-aGandolf the green

    Reply 11 months ago

    Thanks. For power I just used standard mini USB charger contantly plugged in.

    0
    None
    yjames

    11 months ago

    Can a kindle fire be used in this project?

    1 reply
    0
    None
    audrius-ayjames

    Reply 11 months ago

    I believe that it has LED backlit display. In that case it should work. It really depends on the brightness of the display. Mine is not so great and it is hard to see the image in the daylight. But I'm OK with it as it will be going into the fairly dark hallway.

    0
    None
    ddzahn

    11 months ago

    You could also set up a small bluetooth keyboard for it as well

    1 reply
    0
    None
    audrius-addzahn

    Reply 11 months ago

    Interesting idea, but at the moment I cannot see use for it. It was meant to be non interactive mirror.

    0
    None
    oakai

    11 months ago

    Excellent idea! I can't wait to made my own.

    0
    None
    Swansong

    11 months ago

    I'm glad you could find a new use for it :)