Time to setup my machine. First of all I drilled holes for the 3 pumps, 3 bottle holders and the 3 holes in the top of the dispenser to pump in the syrup.
Connect the pumps up with the Arduino
Time to setup my machine. First of all I drilled holes for the 3 pumps, 3 bottle holders and the 3 holes in the top of the dispenser to pump in the syrup.
Connect the pumps up with the Arduino
Setting up my circuit with a relay was simple and now it is setup i can use it to power most 12v appliances with my wireless arduino
8) Some more things to know about strings are the multiple ways of escaping double quotes in a string such as the /n character.
/n = put’s text after it on a new line
/t = tab’s in the following text on the same line
\\ = add’s in \ into the string
“”” = multiple lines of a string
* = creates a list
So we bought a pump and a 12v power supply with 1 amp output and connected the pump up to my relay circuit and pin 8 of the Arduino.
Note* solder header pins onto the wires of the pump for easier connections.
Using my wireless board and code from pervious tests I created a wireless pump that turns on when you press the button on the website and turns off when you press the off button on the site.
http://learnpythonthehardway.org/book/ex1.html
A great guide to help start up with python.
1) print (“this is a string”)
It will print to the Python Shell or if you want to run in in the terminal you can by typing in: python followed by the file name. (Make sure your in the right directory).
Any errors in your code will be brought to your attention by the terminal when you run your script and it will also print the line the error is on.
2) Commenting out on python is just like any other programming language and uses a # to comment out single lines.
3)
To do maths or equations with python, you can write in the numbers and use the expressions above.
4) Variables in python are the same as any other programming language and are set above the code for global use. Multiple word variables can be written with _.
Also an = is an assigning expression assigns the value on the right to the variable on the left, eg, car = 5.
5) Format strings, these are like normal strings but have variables embedded into them. To use a format string you have to use “string” rather then the ‘string’ , and to write one in the program you”
“string here” % variable name
The % is a module key which add’s in variables to the line.
6) Strings and text, this section describes how we can use combine strings””, variables, numbers and operations all together for example:
hilarious = False joke_evaluation = "Isn't that joke so funny?! %r" print joke_evaluation % hilarious
This would print “Isnt that joke so funny False”
7) “text\ntext\n”
This will output text into a new line /n stands for newline character
Another extra to strings is the :
""" There's something going on here. With the three double-quotes. We'll be able to type as much as we like. Even 4 lines if we want, or 5, or 6. """
Setting up LED ‘s in parallel is extremely simple and the best way to power on multiple Led’s. It means you only need 1 connection to the negative and one to the positive.
It also means each LED gets the full 3v to it rather then a section of the 3 volts.
Something I should have started learning a long time ago is python, and now this project is starting to enter python territory it seems like the best time to learn it.
There is a massive difference between Python 2 and Python 3 in terms of the syntax used:
http://ptgmedia.pearsoncmg.com/imprint_downloads/informit/promotions/python/python2python3.pdf
In this post I shall be noting down the differences AC voltage and DC voltage.
AC: Stands for alternating current and travels in whats called an sinusoid or wave like pattern. This allows the current to flow in an alternating repetition, with the up curve being positive and the down curve being negative.
Ac is what powers your mains or anything that gets powered from far away as the wave pattern can travel further then DC’s straight line current flow.
DC: Stands for direct current given it’s flow of current which can be visualised by a straight line which moves in one direction. This current travels at a constant speed which makes it perfect to control the voltage output which is why batteries are DC voltage and that’s why a lot of components/toys take DC voltage.
http://engineering.mit.edu/ask/what%E2%80%99s-difference-between-ac-and-dc
How to use a multimeter. In this post I am going to quickly inform you how to correctly use a multimeter.
So I went to maplin and bought a 6 pin relay which works like :
To set up a circuit with this type of relay you need:
To set this up you:
Now when you press the switch the LED comes on