Introduction: Smart Laundry Basket

When you just have one laundry basket to take care of, life is easy. It's always sitting in your closet, you see it every day, and you know when it is full. The problem comes when you have multiple kids. Now you have laundry baskets spread throughout the house. Going around to each room every other day and checking how full they are is annoying and a waste of your time. Today, we're going to solve that problem.

We'll use the LinkIt One hooked up to an online cloud program (MediaTek Cloud Sandbox) that will allow us to tell if our kid's laundry basket is full from the cloud!

Step 1: Requirements

Requirements

  1. LinkIt One Board by MediaTek
  2. Grove IR Distance Interrupter
  3. Laundry Basket
  4. A MediaTek Cloud Service account

Tools

  • small screw driver
  • tape

You'll also probably need some tape to secure the IR Distance Interrupter to your laundry basket

Step 2: Setting Up Your Hardware

Plugging in the Grove IR Distance Interrupter

This should be pretty straightforward. Plug the Grove module into the pin already available on your board. Because the LinkIt One has these ports built in, it makes it extremely easy to connect and disconnect them for rapid prototyping.

Connecting the Battery

Because laundry baskets get moved around a lot, you'll probably want to attach the battery to the LinkIt One. That is also a pretty straightforward process. Simply connect it to the battery terminal at the front of the device and you should be good to go. Also make sure that you have moved the LinkIt One's power switch to 'BAT' to go on battery power.

Connecting WiFi Antenna

Since we'll be connecting to the cloud for this project we will also need to connect to WiFi. For that, we'll have to plug in the WiFi Antenna that came with your LinkIt One Board. Again, pretty straight forward process here. It connects in the back near the pin that says 'Wi-Fi' on it.

Step 3: Create Your MCS Project

If you're unfamiliar with MediaTek's Cloud Sandbox, I suggest you go read up on it here. Hopefully you have already created an account so we can jump right into the project scene.

You'll want to create a new project under the development tab. Follow the images above as a guide for what exactly you need to set up. Remember to write down your DeviceID and DeviceKey, as we will need those later in order to connect to our account from our LinkIt One.

If this all seems a bit overwhelming for you, I would highly suggest you do the MCS LinkIt One tutorial first in order to get a better grasp of the MCS environment.

Step 4: Adjust Your Sensor to Settings

The Grove - IR Distance Interrupt needs some manually adjustment before it is ready to go. You'll need to get a small screw driver and start spinning the potentiometer screw. The sensor needs to be calibrated to know what distance to look for. It looks for an object a certain distance ahead of it, and if it doesn't find it, returns 'LOW'. Otherwise it would return HIGH (you'll see this in the code in the next steps).

So screw the potentiometer until you have hit the required distance that you would say is a "Full" laundry basket.

For more help on this matter, check out the Interrupt Wiki.

Step 5: Deploy Code to Device

Attached is an .ino file that requires a bit of adjusting before we deploy. You'll need to fill in your own WiFi SSID and password, along with your custom Device Key and Device ID from your MCS account.

This code will connect to your WiFi and MCS account, and then upload the status of your Smart Laundry basket every few seconds.

Step 6: Deploy Hardware

Using some tape, attach your LinkIt One to your laundry basket. The battery is pretty light, so even regular old scotch tape will do (for more long-term projects, you might want to use duct tape or hot glue of some kind).

Make sure that the sensor is pointing down the basket, so it can accurately tell if the basket is full or not.

Step 7: Going Forward

And you're done! Now you have your very own SmartBasket that can tell you if a laundry basket is full all the way across the world. Simply log into your MCS account and check your dashboard to see it!

Going foward, there are obviously a lot of ways we can expand this project. We could create our own API webhook so that whenever the bin is full, it sends us an e-mail, or maybe even create your own App that can monitor it from your phone!