Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Electric curtain for a complete outsider

Status
Not open for further replies.

Ayce47

New Member
Hello everyone! First of all let me point out that I have 0 knowledge in any of this, so where could I read some basic "tutorials". Let's presume I am not an utter moron just for a moment, and I want to start a project to controll the curtains and door lock, via PC. I got everything figured BUT the PC part, first thing I need is to figure out how to make a three position switch(which acts as a polarity inverter) WHICH is...well..electrical, like no finger pushing electrical. This thing will be used for a couple of things, not only closing curtains. The second part, is how to controll this all via PC. I would really appreciate if anyone could point me to what I should learn(and where could I learn it:p)! If it helps I will describe the whole desgin, I just thought not to waste anyone's time.
 
I am assuming that you are running a version of windows on the PC. That makes it difficult to talk to I/O ports. If it was running DOS it is easy to write some simple code in assembler to change I/O signals. There has been a recent thread on the subject. This is a link to the thread.

Les.
 
Hi Ayce47,

Welcome to ETO. I see you are from Romania.

What you want to do is quite simple in technical terms. The hardware would be low cost and off-the-shelf, apart from the mechanics for controlling your particular curtains. Probably you best source would be ebay and the software would be simple too. But as you say that you have no experience in this area you would have a great deal to learn. If you view this project as mechanism for learning that is fine but if you are hoping to quickly get a curtain control system going quickly, I'm afraid that would not be feasible.

OK, that is the lecture over, so this is how I would suggest that you would realise a curtain control system.
Hardware
(1) Arduino microcontroller board
(2) Bridge motor driver shield (input output board in general terms)
(3) DC motor geared down
(4) USB to mini USB cable
(5) Power supply 5V at 5A say but maybe 12V

Software
(1) Arduino Integrated development environment (free to download from the net) and run on your PC

System Configuration
(1) Connect the power supply to the motor driver shield.
(2) Connect the Arduino to a PC with the USB cable.
(3) Plug the motor driver shield into the Arduino.
(4) Connect the outputs from the motor driver shield to the motor with a cable

Writing Sketch (Arduino talk for program)
Just write the program in the IDE to control the motor, including direction.
Download the program into the Arduino.
(Don't be discouraged by the thought of writing a program- it is dead easy, especially if you are computer literate. Also there are many books and tutorials on the net to help you.)

And you are done.

Of course, you would have to design/construct a mechanism to allow the motor to control the curtains and that is probably the most difficult part.:)

You could also consider controlling the motor/curtains, rather than from your PC, but via a human interface to the Arduino- push buttons or touch screen for example. All of this would be pretty straight forward, when you are experienced that is.:happy:

spec

PS: if you just want a curtain opening and closing system best to buy one.:)

LINKS
(1) Arduno Home: https://www.arduino.cc/
(2) Arduino Uno:**broken link removed**
(3) Motor driver (just illustration- not necessarily optimum for your application):**broken link removed**
https://www.ebay.co.uk/itm/12V-36V-...244880?hash=item211ab8e210:g:XP4AAOSwNSxVXny8
(4) Power supply: **broken link removed**
 
Last edited:
How about a cheap solution that's controlled by a smart phone app? Not exactly what you asked for, but a workable solution that you can have working in short order without too much trouble.

iTead Studios in China has an impressive line of smart home remote control modules. For about $6, you can control a lamp or appliance from around the world with your smart phone....or from in your house with a phone or tablet. I have about a dozen of these in my house controlling lamps and they are awesome. The amazing part is that for the price some companies want to control one lamp, I can control my house.

To control draperies, you'd need two modules. The first is a motor reversing module. This is usually called an H-bridge, and it controls the direction a DC motor turns by swapping the polarity of the power connections. This module can only control the direction the motor turns. It can't turn the motor on/off.

SmartSelectImage_2016-11-21-08-03-25.png


To turn the motor on/off, another module is needed, a inching, self-locking module. Translating that name into something that makes sense, this module is an on/off switch. This module would feed DC power to the motor direction control module to run the motor.

SmartSelectImage_2016-11-21-08-10-02.png



Check out the links to see if these modules would make sense for your project.
 
ya, bit too big of a project for a "utter moron" to diy, best off to google "home automation" where wireless door locks are available

-you need to consider each driver - h-bridges and motors/solenoids as mentioned
-then how to relay data & power to/from pc, either run wires or go wireless, either way you will need a cpu of sort to connect and interpret the interface instructions before sending to the PC.

- which requires some programming skills.

I can see curtains alone being simple enough for a project, but door lock, cant see you wanting to run wires there, which means wireless and where/why you will really want to get the pre-built stuff.

EDIT: Sorry just re-read post! for Not Utter Moron, the simplest medium for your non-wireless drivers as questioned is Arduino, simple programming after you learn c++
... could swing it with wireless too, but a bit steep learning curve for newb! since you would need to know about wireless networking protocols and security... Link posted is simple on/off switch, needs 2or 3 more lines of code to control a single h-bridge... and few lines more if multiple bridges

Also, sorry spec/jonsea, just realized i basically repeated you there!
 
Last edited:
Thank You so much! For now I will look into the arduino micro board more, but the H-bridge thing caught my interest too, as that logic can be translated into many other fields. The door lock mechanism is quite simple and easy to build. Just put a gear on the existing key, add a motor, add some transmission to optimise speed and torque, add a case, smart wire placing and done. The curtains system will use a basic system I thought of: put a magnet on the end of the curtain fabric, and two coils at the ends of the window, the small current should be picked up by the coils, and use that info to know the location of the curtain, so it knows when to stop the curtain.......rriigghtt?xD(please Tell me this isn't completely stupid)
 
OK.. if you feel confident with the door lock i will leave you to it .. but I learn that prebuilt is usually better than a doggy design! Depends on your mech. eng. skills i guess,

Jonsea 1st pic is a great little device, never noticed it runs on wi-fi! May be the easiest... might be easy to program with too... depending on how it accepts instructions..

Arduino is good if wifi is n/a. and/or power and data wires are easy to run.. also good choice for more independent and custom control from PC, ie.. custom modes such as lockdown, or all open or timers when PC is off.

Your magnetic theory is sound, that is what most security systems use....need to watch out that your distance from magnet falls in to range of sensor though as I discovered recently with a door sensor.
again I like prebuilt, a little more digital , simpler to work with, but really this one is nothing with only 3 simple components, not sure of trigger range:
https://www.lightinthebox.com/hall-...-61865531738&gclid=CJro-Mb-vNACFY9KDQodbc0LUA

End stops are a good idea!
 
I think the magnet is going to have to be pretty close to detect it.
 
ya, typically.. we needed an industrial sensor when our door warped 2 full cm20161122_145231.jpg
stronger magnets may help too..
 
Many moons (>35 years) ago, I built I curtain mover and I did have access to a machine shop. I made a dual bracket for each sensor which was a small roller microswitch. On one side, there was an "L" that attached to the wall. There was a slot that allowed the distance from the wall to be adjusted. On the rod, I glued an aluminum "wedge" that activated the microswitch.

Limits can easily be done now electronically when using a DC motor.

For the drive, I replaced part of the rope with ladder chain. The motor distance to the rod needs to be slightly greater than the (curtain movement)/2.

I used a 24 V AC synchronous motor and made the motor able to move vertically. The motor was pulled down with a spring. Bead chain is another method and it would work for larger openings.

A small control box was added that accepted a 120 VAC timer and had open/close and auto/manual switches.

If for some reason the curtains had to be moved by hand, it was easy to release it from the drive gear.

Search for "chicken coop door" for some ideas.
 
Is there a module for the arduino to have more of those programmable pins?
Edit: actually, is there such a thing like a small board with a lot of in/out pins that you can plug in the PC? Or a way to sync the arduino so it can use the PCs processor and stuff?
 
Last edited:
There are I2C GPIO expanders and I2C a lot of stuff. I2C is a fast simple serial bus thats called Inter IC Communications.

What sort of role do you want the "PC" to have?

The Arduino Yun https://www.arduino.cc/en/Guide/ArduinoYun is an interesting device. It has both Linux and The Arduino IDE on the board. Linux has indirect access to the Arduino so Linux can be running a webserver for instance.
 
Hi A,
Welcome to the forum.
Lots of different ideas for you so far.
I would try to use a radio control yacht servo to move the curtains controlled by a PIC or Arduino via HC12 radio module to your computer serial terminal.

Hope that helped,
Camerart.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top