Venetian Blinds Auto-winder (time Controlled)
by BegMN in Circuits > Arduino
295 Views, 1 Favorites, 0 Comments
Venetian Blinds Auto-winder (time Controlled)
This instructable outlines a venetian blinds’ winder that is time controlled. The initial design was presented in my book “Arduino Ventures” and was an IR controlled device. This redesign offers a better sensing module in the VL53LOX and is non disruptive when installing (won’t damage the blades of your blinds). The previous device required two magnets glued to the blades of the venetian blinds as well as two reed switches and a whole lot of logic gates to determine whether the blinds were open or closed. The old design worked with IR so you had to physically be close to the window in order to open and close the blinds. This design uses a RTC and allows the user to either physically enter a time for opening and closing or programmatically assign these times.
Supplies
Apart from the electronic components that have to be used to create the circuit necessary to do the heavy lifting,you will also have to do a 3D print for a bracket that i have designed for this project. On my Ender-3 it took 1hr53min to complete, the link to the STL is further down. The very final piece of hardware requires a 1mm thick paperclip to be formed as a hook to couple with the loop of your blinds winding mechanism. I have dedicated a section to this.
Here you will find the STL for the 3D print:
https://www.thingiverse.com/thing:7328402
Components/Modules Required
1 x Arduino nano (c-type usb)
1 x 16x2 line I2C LCD (with backlight)
1 x DS3231 RTC (use a 2032 battery for backup)
1 x VL53LOX time-of-flight distance sensor
1 MX1508 mini dual h-bridge
3 x 100W,1%
3 x6,8kW,1%
3 x150nF capacitors
3 x SPST microswitches
1 x BLUE L.E.D 5mm
1 x RED L.E.D 5mm
1 x Geared Motor (low voltage) used in many other Arduino based instructables - that yellow motor
Forming the Hook
I have these not so ordinary paperclips that have a metal thickness of greater than 1mm and a total length of around 76mm. A single clip is straightened on one side and used to bore through the motor's rotating shaft (sometimes there is no need to bore through as the shaft is clear of any obstruction). Once through, mark off 15mm for the top part (do this in 5mm steps starting from the top edge). Leave 10mm for the protruding metal piece at the bottom of the motor.Remove the paperclip and fashion a "L" for the top part and complete the hook. Replace the paperclip into the plastic shaft and bend the bottom carefully and fix with a cable tie. In my project i also applied some hot glue to the end to secure it better.
The Circuit
The circuit shows how good use is made of the i2c bus of the Arduino Nano. We have connected a 16x2 line i2c LCD ;a RTC DS3231 and the VL53LOX on SDA (pin A4 on the nano) and SCL (pin A5 on the nano). Power connections Vcc and ground for all modules are made, although obvious must be mentioned. Three switches and three L.E.D.s are used to provide the user with access to the device. The “Menu/SET” switch is connected to pin 2 of the nano which is one of the interrupts and allows the user to navigate the setting of RTC; Open and Close times.The overall simplicity of the circuit feels like an achievement on its' own. The low component and module counts make this a cost effective alternative to even the commercial relay based circuits to switch house lights on and off. A four-channel 5v relay board was tested instead of the motor h-bridge on A0 and A1. It worked well.Obviously if you would use it like a normal timer than you should remove the VL53LOX loop and declarations in the code.
The Code
The code has portions borrowed from my first instructable “Time Frame” and that’s simply because a RTC is once again been used. You will also note that instead of using a pin from digital pins 10 through 13 I have used A0 and A1 and declared them as digital pins D14 and D15, the reason for this is stability. I initially used two of these pins (from 10 through 13) and found that the output to the motor was sporadic, I tested the code on the Arduino UNO R3 and the same issue was found. Since I only use the generic boards due to cost I cannot confirm this weird behavior on the original Arduino UNO or Nano.
In the code I have used the 40mm and 50mm limitations so that the VL53LOX can signal open and close conditions to the Arduino,you will have to measure the distance from the actual sensor to the blinds for the "Closed" limit and from the sensor to the wall for the "OPEN" limit. Adjust the code accordingly.
There are also two safeguards that have been coded to make sure that the “open” and “close” times don’t match and the final safeguard where all three time don’t match.
Should you wish to alter the number of predefined presses on D2 to get to a specific menu please feel free to do so as there was no special reason for the counts that I used to get to a specific item to “set”. The link to the code is here: https://github.com/BegMN/Youtube_C3/tree/main/TimeControlledBlinds
Implementation
This project works well and will not harm your property if used correctly but I cannot be held liable and neither can the INSTRUCTABLES people. To view this project in action please goto my youtube channel:
https://www.youtube.com/@Circuit3-MNB there is little content so getting to the landing page won't distress you also because it's the landing page your data will not be depleted. Anyways, i hope you find this build useful.