Sunday, July 29, 2012
GRRR
It's been almost three weeks since I tested the digital temperature sensor and then extended it using twisted pair ethernet cable. In that length of time, I've lost a lot of ground knowledge-wise. And the damn thing isn't working! It's not working, and I can't tell what I'm doing wrong. I can't even tell if I'm supposed to set the data pin to INPUT or not. The tutorial doesn't do it, but I can't see how it would work if they don't do it. I would reference the code I was using, but my computer ran out of battery and shut off without warning, and apparently I never saved my work, which boggles my mind. I'm very frustrated! I really don't want to remove my heat-shrink tubing and solder that I fought so hard to make. These wires are really tedious! But I'm going to do it because otherwise there are too many stupid variables to tell whether my code is right or not.
GRRRR!!!
Tuesday, July 10, 2012
Extending the digital temperature sensor
This was the really difficult part with my last analog sensor, which was analog. Anything beyond being plugged directly into the Arduino would cause the sensor to give me all sorts of unreliable readings. This digital sensor is supposedly immune to this issue, which is why it costs $4 instead of $2 like the analog sensor. The only thing I'm not quite sure about is the pull-up resistor that needs to go between pins 2 and 3 (basically connect pins 2 and 3 via a 4.7K resistor). I'm guessing it needs to happen where the pins enter the Arduino and not up near the sensor itself. Hopefully I'm right.
In terms of the larger plan, this step will allow me to measure the temperature of the water coming out of my sink, and the servos will adjust it to compensate for changes. Once it's all working, I should be able to move the apparatus to my shower! Of course, then I'll have to deal with waterproofing, loosening up the knobs so the servos can turn them, and a few other things.
But first things first: I'm going to extend the new digital temp sensor about 18 inches.
Update: I did it! Although I haven't tested it yet. I took two twisted pair strands from a solid-core ethernet cable, twisted them together, and attached the sensor to the end. It's a little stiff, but it should conduct really well. I'll let you know when I start testing it. The step after that will be to attach it to my sink!!
In terms of the larger plan, this step will allow me to measure the temperature of the water coming out of my sink, and the servos will adjust it to compensate for changes. Once it's all working, I should be able to move the apparatus to my shower! Of course, then I'll have to deal with waterproofing, loosening up the knobs so the servos can turn them, and a few other things.
But first things first: I'm going to extend the new digital temp sensor about 18 inches.
Update: I did it! Although I haven't tested it yet. I took two twisted pair strands from a solid-core ethernet cable, twisted them together, and attached the sensor to the end. It's a little stiff, but it should conduct really well. I'll let you know when I start testing it. The step after that will be to attach it to my sink!!
Monday, July 2, 2012
Digital Temperature Sensor!
A quick update: I've just gotten my new digital temperature sensor working! It's supposed to be better at transmitting over distances. It looks exactly the same as the analog one.
Sunday, July 1, 2012
It verks!!
I'm super excited to report that I did everything I set out to do!! I implemented multiple settings and also a new power supply so the arduino can finally function without the computer attached!! I'm totally psyched because it's actually useful!!
I'm totally living in the future!!
I'm totally living in the future!!
Getting the sink controller to be useful
In my last post, I had created a setup with a single switch that only had full-blast warm or full off. This doesn't encompass the full range of use for my bathroom sink, so I'd like to flesh that out a little more. I also found what I thought was the perfect power supply, but for some reason everything behaved very erratically, possibly due to de-coupling. This means that I may need to put capacitors between my power supply and my servos and/or arduino. However, this isn't a critical issue at the moment, as I can always just use the power setup I had previously. What's important at the moment is getting the apparatus to be useful.
If I can make it easier to get the right temperature using the device than it is manually, I will consider the project successful. I think that by having several of the most common settings rigged to buttons, I'll be able to achieve this.
I bought a breadboard and a bunch of clicky buttons. Each button will be one setting. After talking with Kerry, my first iteration of this idea will have the following settings:
I'll need 5 pins as inputs, and I'll need to make a "state" that changes when each pin is activated. I had the issue before where pins that weren't getting an input would return random values, but I've just read about enabling the Arduino's internal pull-up for digital pins! This means I don't need to waste time adding pull-up resistors to all my pins. Thank goodness. Here I go!
If I can make it easier to get the right temperature using the device than it is manually, I will consider the project successful. I think that by having several of the most common settings rigged to buttons, I'll be able to achieve this.
I bought a breadboard and a bunch of clicky buttons. Each button will be one setting. After talking with Kerry, my first iteration of this idea will have the following settings:
- Full cold - filling water bottles, rinsing a glass
- Medium cold - putting a small amount of water in a glass
- Low cold - wetting a toothbrush
- Medium warm (full-blast hot to make it heat up quickly, then reduce)
- Off
Monday, June 18, 2012
It's different, but it works!
Instead of doing temperature control, I focused on mounting it on my sink and having something that turned the water on and off. Success!! Right now it only does off or full blast warm, but it works great. Check out my mounting hardware that I salvaged from that broken paper shredder I mentioned a few posts ago!
Monday, June 11, 2012
Mounting, refining, and pivoting?!
My Set Temperature switch is much more sturdy, and it is now detachable! I would still like a switch that just plugs into the Arduino's headers, so I ordered this one off Adafruit, along with some more wires, headers, and other connectors. My next steps are to figure out how to mount the servo on the sink knob, and to further waterproof the sensor and also mount it on the sink. This way I don't have to hold either of them during testing, and I can hold my computer instead.
I still have to deal with the issue of extending the temperature sensor. The further it gets from the Arduino, the more screwy the readings are. Apparently you have to add a resistor, but even that wasn't giving me great results. My wiring was pretty crappy too though, so I'm hoping that was the main issue. Perhaps CAT5 would help... it's designed to keep the signals as fresh as possible during their travels. I also just ordered a digital temperature sensor and also a pre-waterproofed thermistor temperature sensor. If I can't get the one I have to work, I'm sure one of those two would work great.
I also have an idea that will make use of what I already have going: pivot (slightly)! This is startup language for "change the direction of the product to accomodate current trends". I'm thinking that since I already have one servo mounted on my bathroom sink, I could just mount the other one and then bind them together, which would mount them in place! Then I could turn the project into a sink controller, and have presets for "cold", "hot", and "warm" and maybe a couple others. When someone wants to wash their hands, they can just hit "warm" and take a piss or something while the unit calibrates the water temperature, and then it will beep when it's ready! I can continue later with controlling the shower. Yay!
I still have to deal with the issue of extending the temperature sensor. The further it gets from the Arduino, the more screwy the readings are. Apparently you have to add a resistor, but even that wasn't giving me great results. My wiring was pretty crappy too though, so I'm hoping that was the main issue. Perhaps CAT5 would help... it's designed to keep the signals as fresh as possible during their travels. I also just ordered a digital temperature sensor and also a pre-waterproofed thermistor temperature sensor. If I can't get the one I have to work, I'm sure one of those two would work great.
I also have an idea that will make use of what I already have going: pivot (slightly)! This is startup language for "change the direction of the product to accomodate current trends". I'm thinking that since I already have one servo mounted on my bathroom sink, I could just mount the other one and then bind them together, which would mount them in place! Then I could turn the project into a sink controller, and have presets for "cold", "hot", and "warm" and maybe a couple others. When someone wants to wash their hands, they can just hit "warm" and take a piss or something while the unit calibrates the water temperature, and then it will beep when it's ready! I can continue later with controlling the shower. Yay!
Subscribe to:
Posts (Atom)



