User Tools

Site Tools


wiki:domus-proto

START PROTOTYPING

The breadboard is the primary place where you will be building the circuits. The horizontal and vertical rows of the breadboard carry electricity through thin metal strips under the plastic on top, with holes to plug in your components.

RGB LED

Get the code

To illuminate the Smart House, you will use a RGB LED. You will be able to control the color and intensity of the light inside the house.

Connect the long red wire to the 5V pin on the RED board, and put the other end in the long red (+) bus on the side of your breadboard. Connect ground on the RED board, to the adjacent black (-) bus with the long black wire. It’s helpful to keep your wire color consistent (red for power, black for ground) throughout your circuit. Make note of the longest pin on the LED, place it in your bread- board, and connect that pin to ground on the bus. Connect the other three pins to digital pins 9, 5, and 6 in series with 220 ohm resistors. Be sure to connect each LED lead to the correct PWM pin.

Upload your sketch to the board now! Once your RED board is programmed and wired up, the RGB LED will be red to begin the cycle. Notice how the LED’s color changes from red to green to blue to red, and all the colors in-between.

TEMPERATURE SENSOR

Get the Code

To illuminate the Smart House, you will use a RGB LED. You will be able to control the color and intensity of the light inside the house.

Connect the long red wire to the 5V pin on the RED board, and put the other end in the long red (+) bus on the side of your breadboard. Connect ground on the RED board, to the adjacent black (-) bus with the long black wire. It’s helpful to keep your wire color consistent (red for power, black for ground) throughout your circuit. Make note of the longest pin on the LED, place it in your bread- board, and connect that pin to ground on the bus. Connect the other three pins to digital pins 9, 5, and 6 in series with 220 ohm resistors. Be sure to connect each LED lead to the correct PWM pin.

Upload your sketch to the board now! Once your RED board is programmed and wired up, the RGB LED will be red to begin the cycle. Notice how the LED’s color changes from red to green to blue to red, and all the colors in-between.

PIEZO BUZZER

Get the Code

To make your Smart House with sound effects, you need the Piezoelectric buzzer. Use it as a bell or as an alarm for your mini house.

Connect one lead of the piezo to ground and the other lead to pin 10 on your RED board. You can see how the circuit is becoming more complex, but sections of the circuit are quite simple. Even with a two-lead component, do not rush the assembly, it is easy to make careless errors with a wire in a di erent row than the component, for example.

Once your board is programmed and wired up, you should hear tones from the piezo playing in a loop. The tone() function is fun for playing sounds, but it does have a few limitations. It can create only square waves, not smooth sine waves or triangles. Square waves jump to their amplitudes in a dependable way to play the frequencies. Only one tone can play at a time and tone() will interfere with analogWrite() on pins 3 and 11.

PIR SENSOR

Get the Code

Build an anti-theft system to secure your Smart House. For this purpose a PIR sensor is used as a motion detector.

Place the PIR sensor on the breadboard (the order of the pins is important!). If the sensor is back- wards, it will not get hot, but the lights on the RED board will go out, meaning there is a short-cir- cuit. There is a tiny black chip on one side of the green PCB holding the PIR sensor. This tiny black chip should face away from the RED board, the side that has very small symbols - 0 + should face the RED board. Connect the middle pin to digital pin 2 on the RED board. Next choose two jumper wires to connect the PIR sensor to the buses. Facing the RED board, the right pin goes to the nega- tive bus, and the left pin goes to the positive bus. Check and double-check!

Upload your code to the board and click the serial monitor icon to open the pop-up window. When you wave your hand near the PIR sensor, on the RGB LED, the red LED will turn on, the green LED will turn on, and you will see the message “Motion detected!” When the movement stops, the red LED will turn on, the green LED will turn on, and you will see the message “Motion ended!”

WI-FI SETUP

Connect your computer to the RED board network (what’s next RED board will appear in the list of networks as Red-WiFi-XXXXXX, where XXXXXX is the final part of the board’s Wi-Fi serial number (Mac Address).

Once the computer is connected to it, type http://192.168.240.1/ in your browser. This is the configuration panel where you are able to change the board name and connect it to your local Wi-Fi network SSID.

At the end of the procedure, connect back to the network you were using before, in order to proceed with the online step-by-step guide.

REST SERVER

One more step is needed, the RED board itself needs instructions to work with the app or a web browser. The last sketch to load, included in the WiFiConn library, is a Rest Server sketch, which will finally make your red a thing in the Internet of Things.

Open the Arduino IDE again, download and install the WiFiConn library (see instructions below). You can find the example in the Arduino IDE menu: File → Examples → WiFiConn → WiFiRestServerDomus and upload the sketch to your RED board.

Install WiFiConn

Download the WiFiConn library and add it to the IDE navigating to Sketch → Include Library → Add .ZIP Library and selecting the .ZIP file you just downloaded, then restart the IDE. The library is now loaded into the IDE, and you should see it in the Sketch → Include Library drop-down menu. Now you are ready to proceed to the next step.

Download Library

BUILD AND CUSTOMISE YOUR DOMUS

Get a shape

Fold the paper house provided around your circuit to make your mini house more 3 dimensional. Place your work base inside the assembled mini house. You may also design your own paper engineering blueprint, re-use cardboard, or 3-D print an enclosure for your project. The sky is the limit, what will your Smart House look like?

THE DOMUS APP

It’s now time to download the SmartHouse app, available for Android, iPhone / iPad, or Chromebook. Download it for your respective device. Once you launch the app, your device will be detected and you will be able to connect it. Enjoy controlling the functions of your Smart House and observing the data in the app!

Get the App from the Apple store

Get the App from the Google Play store

* What’s Next is a trademark of CC Logistics GmbH. Apple, the Apple logo, iPhone, and iPad are trademarks of Apple Inc., registered in the U.S. and other countries. App Store is a service mark of Apple Inc., registered in the U.S. and other countries. Google Play and the Google Play logo are trademarks of Google LLC.

ENJOY DOMUS

Congratulations!

You have successfully assembled your Smart House circuit, programmed the RED Wi-Fi board, and now you have access to your mini house from the internet! Enjoy learning more about IoT with your what’s next kit!

wiki/domus-proto.txt · Last modified: 2019/01/26 10:36 (external edit)