Instructables
loading
loading
Picture of Infinity Mirror Clock
IMG_0266.JPG

Ever since my addressable RGB LED strips (WS2812B) came from Aliexpress, I've been fascinated with LED projects. Following up on my success with my Charlieplexed LED clock, I wanted to create something with more Jazz..

While browsing google images, I came across an instructable for an Arduino Infinity Mirror and the brain cells started working in overdrive. Why shouldn't I make an infinity mirror, that's also a clock !!

Features:

  1. Works like a clock - the colours of the hands are user-programmable over bluetooth
  2. Has an IR sensor to sense if someone is coming near the mirror. Switches off the LEDs, so that this can be used as a normal mirror :-)
  3. Shows a rainbow effect every 15 minutes (time is user adjustable)
  4. Has a touch button to toggle between clock and rainbow effects
  5. Switches to night mode between midnight and 7:00 AM - can be changed in the code.
  6. Can be programmed over bluetooth - so you do not need to take it off the wall if you need to update the code
 
Remove these adsRemove these ads by Signing Up

Step 1: Electronics

Picture of Electronics
  1. A Standalone Arduino: http://dushyant.ahuja.ws/2013/10/standalone-arduin... OR Arduino mini pro: http://www.aliexpress.com/item/10Pcs-Lot-Pro-Mini-...
  2. RTC Module – DS1302: http://fabtolab.com/DS1302-RTC-module?search=rtc
  3. LM2596 Step Down Adjustable Power Supply Module 1.3V-35V: http://cgi.ebay.in/ws/eBayISAPI.dll?ViewItem&item=...
  4. 1m 60LEDs/M Addressable RGB LED Strip (WS2812B): http://www.aliexpress.com/item/1M-WS2812-WS2812B-6...
  5. HC-05 Bluetooth module: http://www.aliexpress.com/item/RS232-TTL-LC-05-Wir...
  6. IR Proximity Sensor: http://www.instructables.com/id/Simple-IR-proximit... 4 IR LEDs; 1 IR LED detector: http://www.evelta.com/industrial-control/sensors/5...
  7. Touch Pad: http://www.aliexpress.com/item/Touch-Pad-Brick-Sen...
  8. 9V – 2A Adapter
  9. CP2102 USB-to-TTL (the RST pin on the CP2102 is not for resetting the arduino – you have to solder a wire to the DTR pad on the PCB – which sends a reset signal to program the arduino. This has to be connected to the DTR pin on the Arduino
1-40 of 137Next »
dushu (author) 2 months ago

Just realised, the set_time doesn't function correctly, please replace with the following:

void set_time(){

DateTime now = rtc.now();

Serial.println("IN SETTIME");

uint8_t hr = (uint8_t)atoi(sCmd.next());

uint8_t minu = (uint8_t)atoi(sCmd.next());

uint8_t sec = (uint8_t)atoi(sCmd.next());

rtc.adjust(DateTime(now.year(),now.month(),now.day(),hr,minu,sec));

}

Format for setting time TIME h m s

e.g. TIME 10 12 00

i changed a code but it doesnt make the Leds ON.I wanna make only a clock Led without others function like bluetooth.Only with Leds and this code it doesnt work.May be you know the solution

dushu (author) 15 days ago

I've had the clock running for nearly nine months and it started getting stuck erratically. The clock would run for a few hours and then stop - the LEDs would get stuck. I tried everything to troubleshoot them - going so far as to replace all the components (except the LED strips one by one). But to no avail. Long story short - I have narrowed down to the following:

1. The first LED in the code remains ON at full brightness at all times

2. This caused the first LED to overheat and stop transmitting data

3. The solution is to change the white colour to (50,50,50)

It's working now - but will update if there are any issues.

The code work but the LED off.May be you know the problem

with other codes LEDs works normal(so it doesnt problem with LEDs)

dushu (author)  AngelSymbol.10 days ago

Did you check the version of FastLED? Have you connected the correct pin to the data line (5) ? Is your RTC working fine?

PrestonW226 days ago
I'm having a problem with the rtc. I bought a ds1302. but the schematics show a DS1307. help?

Also, the arduino uno offers ports for SDA and SCL. Do I still plug into A4 and A5?
temp_546002257.jpgtemp_607284294.jpgtemp_-1939278747.jpg
dushu (author)  PrestonW217 days ago

DS1302 and 1307 - both should work. The SDA and SCL are actually A4 and A5 - so you can connect to any one

PrestonW2 dushu14 days ago

I finally got that working! But now I am having a few problems with the Diagram. What are JP1 and IC1? Can you add an image of what your final circuit looked like?

ivanyd1 month ago

hi i was wondering what the jp1 was in the drawing of the schematics? also im using a Arduino uno and was wondering if i am able to leave out the circuits at pb6-pb7 and pc6 as they are only needed for a stand alone arduino?

dushu (author)  ivanyd17 days ago

The JP1, circuits at PB6, PB7 and PC6 are required only for the standalone - they are not required if you're using an Uno

Could anyone please post an image showing the circuit connections in detail??

pleaseee

dushu (author)  inifinityone1 month ago

Please see image in Step 2 - it can't get any more detailed than that. The circuit is actually very simple - with only a few connections required.

Could anyone please post an image showing the circuit connections in detail??

pleaseee

judas791 month ago

Neat project but I was getting errors all day while trying to compile; like the following:

Infinity_Mirror_v1:22: error: 'CRGBPalette16' does not name a type
Infinity_Mirror_v1:23: error: 'TBlendType' does not name a type
Infinity_Mirror_v1.ino: In function 'void setup()':
Infinity_Mirror_v1:42: error: 'currentPalette' was not declared in this scope

about 20 more errors of the same nature. It was caused by using these versions:

FastLED.zip

FastLED-archive-FastLED2.1.zip

Then I spotted the link below in the comment section and all is well.

github.com/FastLED/FastLED/

Hope this helps anybody that gets stuck as I did

rafam2 months ago

hello when i try the code it gives me

avrdude: stk500_recv(): programmer is not responding

any ideas how to fix it?

I'm guessing you've got a mismatch of what your Arduino IDE is set to and what the board you're programming actually is. If you're building it outside of the Arduino, you need to remove the ATMEGA 328 chip from the Arduino itself before using "Arduino as ISP" setting AND choosing exactly what chip/board you are programming.

If it your hardware isn't in the dropdown, you need to add it.

http://www.instructables.com/id/Arduino-on-all-sorts-of-Atmels/

Oh right, the reason; you can't have 2 different chips on the TX and RX pins of the Arduino board, which is already wired to its own ATMEGA 328.

dushu (author)  rafam2 months ago

Just found out that the arduino mini pro is programmed at a different speed - if you're using one - you will have to change the speed of the Bluetooth module to 57,600 instead of 115,200

dushu (author)  rafam2 months ago

Did you connect pin 32 from the HC-05 to the reset pin as mentioned in step 2?

rafam2 months ago
I'm having I'm having trouble getting the lights to turn on. When I connect the LM25 to the lights they glow for a second then stop. Any idea?
15, 5:02 PM.jpg
dushu (author)  rafam2 months ago

These LEDs will not work without a microcontroller - they need data to switch on. Please connect the arduino and load one of the test sketches in the FastLED Library

How would you go about making this without the clock portion just the infinity mirror and an IR sensor?

dushu (author)  whynotdotoday22 months ago

That should be easy - just delete the portions of the code that have the clock functions and replace them with the rainbow functions.

inifinityone2 months ago

Is it necessary to use the 7805 if im using the arduino uno?

dushu (author)  inifinityone2 months ago

No, just ensure that the LED strips are not powered through the arduino. The LED strips should have a separate power.

inifinityone3 months ago

the rgb led strip that i bought online has a circuit similar to this

how do i go about the connections? please help

download_1.jpg
dushu (author)  inifinityone2 months ago

You can use this to build one of these:

http://www.instructables.com/id/Infinity-Mirror-Ta...

whoa looks pretty coool man! awesome stuff!
My addressable leds arrived just today! lets hope that im able to complete this project! *fingers crossed*

dushu (author)  inifinityone3 months ago

This looks like a 12V RGB strip - I don't think this is addressable. You need an addressable rgb strip for this project.

rafam2 months ago
So it is possible to use a simple flat glass and not a convex one?
dushu (author)  rafam2 months ago

There is no convex glass in this build. The back and front mirrors are flat.

rafam2 months ago
Is the touchpad a necessary item to this built?
dushu (author)  rafam2 months ago

No - you can leave it out - but you will have to modify the code slightly

rafam2 months ago
Does the glass have to be a convex glass of can it just be a normal flat glass?
A-Bomb963 months ago
(removed by author or community request)
A-Bomb96 A-Bomb963 months ago
(removed by author or community request)
dushu (author)  A-Bomb963 months ago

Yes - this should work. You should stick it on the inside face of the glass. An alternative would be a two-way mirror.

GrosSinge3 months ago

Hello, I'm facing issues with the code. I recieve the following message when I try to compile:

noise.cpp:24: error: expected initializer before 'const'
noise.cpp:50: error: expected initializer before 'grad16'

This is with the FastLED library. If I remove noise.cpp the code will compile but the software will only display "Status:" in the Serial Monitor and will eventually freeze up.

I've tried uploading to a Stand Alone Arduino (Uno) and an Arduino Nano and I get the same results. This is also with the latest software as well.

Any thoughts?

dushu (author)  GrosSinge3 months ago

Which version of FastLED and arduino IDE are you using? I believe v3.0 has some issues with the arduino IDE 1.5.7 or later.

https://github.com/FastLED/FastLED/

1-40 of 137Next »