Check out my video to learn what HTML is, how to create a simple page, and how to use cmx.io:
Monday, 18 February 2013
Create your own comic strip using HTML markup
Check out my video to learn what HTML is, how to create a simple page, and how to use cmx.io:
Saturday, 19 January 2013
Electronic Textiles with Geek Gurl Diaries & LilyPad Arduino
What you will need:
- LilyPad Arduino Simple or main board
- FTDI Basic Breakout and a USB cable
- ProtoSnap LilyPad Sewing Kit
- LilyPad Coin Cell Battery Holder
- LilyPad Button
- LilyPad Slide Switch
- 5 LilyPad White LED
- A bobbin of conductive thread
- A coin cell battery
- A cushion cover and some felt sheets
- Sewing needle, pins, and scissors
Sewing:
First decide on your design and create it using felt and fabric. I decided to use the Geek Gurl Diaries logo and recreated it by printing a template onto paper first, cutting it out, pinning it to felt before cutting it out and gluing it together. I also sewed a background star shape cut from cotton fabric onto the cushion cover.
Once your cushion cover is prepared sew the LilyPad Ardunio Simple Board to the inside of the cushion cover using conductive thread and the Lilypad coin cell battery holder from the ProtoSnap kit. It's very important that you sew a connection between the coin cell battery holder's minus (-) ground to the LilyPad Ardunio simple board minus (-) ground and again for the positive (+) between both boards. Once you have finished sewing you can test that the connection is good by putting your battery into the battery coin cell holder. Your simple board should flash to indicate that it is working.
The next step is to decide where you want your LED lights to be and sew them in place. Much like producing a standard circuit, you must connect the positive (+) of the LED to a number on the LilyPad arduino board and the negative (-) or ground to the negative (-) of the LilyPad simple board. Once you have sewn one LED you should test to ensure it is working by placing your coin cell battery into the holder, and the light should come on if your circuit is good. Continue to sew all your LED lights onto your cushion cover being careful not to have the threads crossing each other or touching as it will short the circuit. Sometimes it's just best to sew the long way round!
Connecting to a computer to program the lights:
Now that all the sewing is complete and we have tested that our circuit is good and the lights work, we need to connect the Lilypad board to a computer using the FTDI Basic breakout and a USB cable. Once connected you will need to install the Arduino software to be able to program the lights. This tutorial explains how to install and configure the software for your Lilypad. Once installed run the arduino software, and select Tools, Serial Port, COM3 and then select your ardunio board from Tools, Boards. We want to test if we can upload a program to our board. Click on File, Examples, Basic, Blink. When the example code loads you will need to make sure that you change the number of the LED pin to match the numbers on the Lilypad board that you have sewn the leds to. Then compile the code and upload it to the board.
Once you are happy that your LEDs are working, we can start to generate our own code. In a new Arduino window write the following:
void setup() {
pinMode(19, OUTPUT);
pinMode(17, OUTPUT);
pinMode(10, OUTPUT);
pinMode(6, OUTPUT);
pinMode(5, OUTPUT);
}
pinMode(19, OUTPUT);
pinMode(17, OUTPUT);
pinMode(10, OUTPUT);
pinMode(6, OUTPUT);
pinMode(5, OUTPUT);
}
Making sure to change the pin numbers to match the numbers on your Lilypad board that you have sewn the LEDs to.
Now we have told our program which pins to use we need to tell them what to do. I want mine to come on in order one after the other so underneath the first part of code I need to add:
void loop() {
digitalWrite(19, HIGH); //This turns on the LED
delay(1000); //Waits for a second
digitalWrite(19, LOW); //Turns of the LED
delay(1000); //Waits a second
}
digitalWrite(19, HIGH); //This turns on the LED
delay(1000); //Waits for a second
digitalWrite(19, LOW); //Turns of the LED
delay(1000); //Waits a second
}
Now I've written it for one LED, I can copy and paste the code, changing the number of the pin as I go along, so that finally all my LEDs connected to the Lilypad board will come on in sequence. Compile the code and upload it to the Lilypad.
Ta da, your very own electronic textile project! Now you know some basic tips and tricks you could work out how to program the Lilypad to have the lights come on for a second randomly rather than in sequence or you could add more functionality with sensors.
Have a go and see what fun you can have! Please support my work getting more teenagers (especially girls) into tech, by watching, liking, commenting and sharing my videos
Thanks,
Carrie Anne.
Sunday, 30 December 2012
GGD on RaspberryPi.org
Today the 'Little Box of Geek' Raspberry Pi and thermal printer project featured on the front page of the Raspbbery Pi Foundation official website.
http://www.raspberrypi.org/archives/2953
It's been a very exciting and busy day with many people getting in touch via twitter, facebook and YouTube to offer their support for my work.
If you want to get in touch, have ideas for episodes or suggestions for improvements check out:
Subscribe to the Geek Gurl Diaries YouTube Channel
Facebook Page
Twitter accounnt @GeekGurlDiaries or @MissPhilbin
Check out the Geek Gurl Diaries Website
Many thanks to everyone at Raspberry Pi for their kind words and support, and welcome to all my new viewers and followers, I hope I do not disappoint!
http://www.raspberrypi.org/archives/2953
It's been a very exciting and busy day with many people getting in touch via twitter, facebook and YouTube to offer their support for my work.
If you want to get in touch, have ideas for episodes or suggestions for improvements check out:
Subscribe to the Geek Gurl Diaries YouTube Channel
Facebook Page
Twitter accounnt @GeekGurlDiaries or @MissPhilbin
Check out the Geek Gurl Diaries Website
Many thanks to everyone at Raspberry Pi for their kind words and support, and welcome to all my new viewers and followers, I hope I do not disappoint!
Friday, 28 December 2012
Little Box of Geek Project - Part 2
Using the printer base as a template, draw around the printer using pen onto the cardboard box where you want your printer to be. Using a screwdriver or pencil, pierce the box so that you can comfortably get scissors inside to cut out the hole for your printer to sit in.
Do the same again for your button. (I found that a one pound coin was the same size as my button so I used it as a template to draw around.) Wrap your box in colour paper or print some labels to make it look more interesting.
We need to create a program to print on the Raspberry Pi:
First test that the printer works by writing a simple 'Hello World' style statement. Save as printer1.py (in the same directory as the printer.py file we used in Part 1 of this tutorial because it is importing from this file) and execute the program by typing python printer1.py in a terminal window) making sure that your printer is attached to your pi:
import printer
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
p.print_text("\nHello Geek Gurl Diaries viewers!\n")
p.linefeed()
p.linefeed()
p.linefeed()
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
p.print_text("\nHello Geek Gurl Diaries viewers!\n")
p.linefeed()
p.linefeed()
p.linefeed()
If that works, great! But what happens if we write a really long string? Will it go over multiple lines, or will the text be cut off? We should test it by modifying our code and saving it as printer2.py and executing it.
import printer
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
p.print_text("\nHello Geek Gurl Diaries viewers!What happens if we try to print a longer sentence or paragraph? Will it go over multiple lines or will the text just be cut off? It's good to test these things you know!\n")
p.linefeed()
p.linefeed()
p.linefeed()
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
p.print_text("\nHello Geek Gurl Diaries viewers!What happens if we try to print a longer sentence or paragraph? Will it go over multiple lines or will the text just be cut off? It's good to test these things you know!\n")
p.linefeed()
p.linefeed()
p.linefeed()
It seems clear that we need to use a text wrap module to ensure that all the words fit onto each line and are not split down over multiple lines on the printout. Adapt the code in printer2.py to include the textwrap module and save it as printer3.py:
import printer, textwrap
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
wrapped_text = textwrap.fill("\nHello Geek Gurl Diaries viewers!What happens if we try to print a longer sentence or paragraph? Will it go over multiple lines or will the text just be cut off? It's good to test these things you know!\n")
p.print_text(wrapped_text)
p.linefeed()
p.linefeed()
p.linefeed()
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
wrapped_text = textwrap.fill("\nHello Geek Gurl Diaries viewers!What happens if we try to print a longer sentence or paragraph? Will it go over multiple lines or will the text just be cut off? It's good to test these things you know!\n")
p.print_text(wrapped_text)
p.linefeed()
p.linefeed()
p.linefeed()
I wanted my box to print geeky statements at anytime. I decided to use the fortune program. First Install Fortune and then install fortunes to get options to select categories of fortunes:
sudo apt-get install fortune
sudo apt-get install fortunes
sudo apt-get install fortunes
By looking at the manual for fortune it is possible to use only short statements which are more suitable for my thermal printer using -s and to get specifically scientific fortunes I can use 'science'
man fortune
In a terminal window I can check to see what statements the fortune program will give me by typing:
fortune -s science
Now let's modify our program to move away from using a fixed string and instead use a Unix shell to direct the output of the fortune program to the input of our printer program. We can also add some functionality to wrap the text over 32 characters (thats how many the printer prints per line!) so that our printout looks even better. Save as printer4.py and execute:
import printer, textwrap, sys
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
unwrapped_text = sys.stdin.read()
wrapped_text = textwrap.fill(unwrapped_text, 32)
p.print_text(wrapped_text)
p.linefeed()
p.linefeed()
p.linefeed()
p=printer.ThermalPrinter(serialport="/dev/ttyAMA0")
unwrapped_text = sys.stdin.read()
wrapped_text = textwrap.fill(unwrapped_text, 32)
p.print_text(wrapped_text)
p.linefeed()
p.linefeed()
p.linefeed()
Test out this idea by running a terminal and typing:
fortune -s science | python printer4.py
Adding a button:
Now that our printer is printing what we want it to we need to add the button. Using a breadboard, a 10k resistor, and 6 jumper cables attach the button to the breadboard to the raspberry pi GPIO pins (I learned everything I needed to know from Adafruit Raspberry Pi GPIO Setup and Adafruit Sounds and Buttons Tutorial):
We need to write a script to detect when the button is pressed. Using a text editor type the following and save as GPIO_test.py (remember indentation is important in python!) :
#!/usr/bin/env python
from time import sleep
import os
import RPi.GPIO as GPIO
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.IN)
while True:
from time import sleep
import os
import RPi.GPIO as GPIO
GPIO.setmode(GPIO.BCM)
GPIO.setup(23, GPIO.IN)
while True:
if ( GPIO.input(23) == False ):
print("Printing")
os.system("/usr/games/fortune -s science | python ggd_printer4.py")
print("Printed")
sleep(1)
Finally, we want the printer program to run whenever the button is pushed and the Pi is on. Therefore we need to modify the /etc/rc.local file to reflect this by using a terminal window:
sudo nano /etc/rc.local
Add this before exit0 making sure it points to the correct location of your GPIO_test file:
cd /home/pi/printer/ && python gpio_test.py &
Once you have tested that it all works, transfer your pi, printer, and breadboard into the prepared cardboard box and make sure everything is plugged in and sits well. Power it all up, give is a few minutes, then press the button and receive a piece of Geek wisdom.
I hope you have found this tutorial useful and enjoyable to do. My box was an idea born from seeing @blogmywiki's Little Box of Poems which he created using an Arduino. It would not have been possible without the support of Giles and @asbradbury (the best Pi Code Monkey)
Please support my work getting more teenagers (especially girls) into tech, by watching, liking and sharing my videos.
Thanks,
Carrie Anne.
Thursday, 27 December 2012
Little Box of Geek Project - Part 1
You will need:
- A Raspberry Pi, power supply and peripherals (including up to date image on SD card)
- A thermal printer, a 7.5v/2a power supply, and roll of paper
- A cardboard box
- A button
- Cables
- Breadboard
- A resistor
- A solder-less DC connector
- A small crosshead screwdriver
- A cable striper
- Scissors
- A pen
- Some help from an adult for the fiddly bits.
Prepare the thermal printer by connecting the cables. First plug in the data cables (green, yellow and black) to the printer. Next connect the power cable (red, black).
Cut off the end of the power connector and replace it with the solder less dc connector so that it can be plugged into a dc power supply (must be between 5 and 9v, 2a). Make sure that the red wire is put into the positive (+) and the black wire into the negative (-). Screw in tightly.
Test that the printer works with your power supply by plugging it in. If the green light flashes and when you press the paper feed button, the paper comes out, the printer is ready to be plugged into the Raspberry Pi GPIO pins.
Using male to female jumper cables attach the RX of the printer (yellow) to pin 8 and the ground of the printer (black) to pin 6 on the Pi. GPIO layout Note: Make sure you read this first :)
Connect your pi to a keyboard, mouse, monitor etc. You should have already setup your raspberry pi, if you have not done this yet check out GGD episode 5.
We need to first setup the Raspberry Pi serial port and change some settings.
Install the required files by typing the following into a terminal window.
sudo apt-get install python-serial
sudo apt-get install python-imaging-tk
sudo apt-get install python-imaging-tk
Next give the serial port permission to dialout using:
sudo usermod -a -G dialout pi
We also need to edit this file:
sudo nano /boot/cmdline.txt
By deleting:
dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 rootwait
and replacing it with:
dwc_otg.lpm_enable=0 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 rootwait
Finally remove the last line of /etc/inittab and restart your raspberry pi using:
sudo shutdown -r now
(With thanks to natemcbean.com tutorial)
Next we need to download the python files needed to print from github. First you will need to install git-core onto your pi using:
sudo apt-get install git-core
create a directory on your pi to download your files from git hub to using:
cd~/git
to download the printer repository use:
git clone git://github.com/luopio/py-thermal-printer.git
Finally we need to edit the following file:
sudo nano printer.py
To add this line at the top:
#!/usr/bin/env python
and to check that it is pointing to the correct port:
/dev/ttyAMA0
Run Printer.py and a test page should print.
What are you waiting for? Hot foot it to Part 2 for more fun!
What are you waiting for? Hot foot it to Part 2 for more fun!
Friday, 23 November 2012
Thursday Club: The Girls Hacking Club present a 'women in technology' panel.
On Thursday 22nd November I was invited to speak and be part of a panel of experts at by the Girls Hacking Club, part of Goldsmiths' Thursday Club.
The Thursday Club is an open forum for anyone interested in the theories and practices of technologies and state-of-the-art culture.
I was very excited to be invited to be part of a 'women in technology' panel discussing various projects developed to empower women in the IT industry. The panel included a stunning line up of fantastic projects in the UK:
Nela Brown is a sound artist/ technologist and researcher. She is currently doing her PhD at Queen Mary, University of London where she is also a Chair of G.Hack and WISE@QMUL. G.Hack is a collective of female researchers at the School of Electronic Engineering and Computer Science focusing on sharing knowledge and developing interactive media projects through collaboration with other universities, art organizations and industry partners. In 2011 G.Hack received funding from QMUL which kick-started a series of public engagement activities.
http://nelabrown.blogspot.co.uk http://ghack.eecs.qmul.ac.uk
Pollie Barden is a visual artist, game designer, web designer and technophile. She earned an M.S.P. from the Interactive Telecommunication Program at New York University and is currently doing her PhD in Media Arts and Technology at Queen Mary, University of London where she is also a member of G.Hack and in charge of co-ordinating departmental qMedia Hack Days.
http://pabadesigns.com
Anna-Maria Spehar-Deleze and Salzitsa Anastasova-Ivanova are postdoctoral researchers at the School of Engineering and Material Sciences at Queen Mary, University of London and members of the WISE@QMUL committee. WISE@QMUL (The Women in Science and Engineering Society) was set up in 2008 as an informal group for discussion and networking amongst QMUL students interested in the role of female participation in science. The society currently has 130 members spread across the Faculty of Science and Engineering and the Faculty of Medicine and Dentistry and welcomes men as well as women from undergraduate level to professors. In 2012 the society received substantial funding from QMUL, which enabled them to organize seminars, talks, workshops and socials in 2012 and will ensure sustainable growth in years to come.
http://wiseqmul.wordpress.com
Paula Graham is a director of Fossbox; a non-profit offering consultancy on collaborative working, peer support and peer training and co-founder of Flossie; a collective of women from digital and arts organisations sharing a common commitment to celebrating and enabling women’s contribution to FLOSS culture. The first Flossie conference was held in May 2012 at Queen Mary University of London and was followed by a 3 day ‘Career Taster’ in October 2012 at The National Museum of Computing in Bletchley Park.
www.fossbox.org.uk www.flossie.org
Heidi Harman is a serial entrepreneur, mentor and speaker and also co-founder of Geek Girl Meetup. She is currently working on her new startup in the mobile finance sector.
www.geekgirlmeetup.com
Carrie Anne Philbin (yours truly) is a KS3 ICT Subject Leader & Google Certified Teacher at Robert Clack School in Dagenham. She is a Creator of the Geek Gurl Diaries, a youtube video series designed to inspire more teenage girls to take up STEM and Computing subjects.
www.geekgurldiaries.co.uk @geekgurldiaries
I was excited to network with these projects to hopefully collaborate with in the future. I'm excited to find female role models in STEM subjects who would be willing to do interviews and perhaps help me run workshops. If you love technology I would recommend getting involved with any if not all of the projects and groups listed above.
The Thursday Club is an open forum for anyone interested in the theories and practices of technologies and state-of-the-art culture.
I was very excited to be invited to be part of a 'women in technology' panel discussing various projects developed to empower women in the IT industry. The panel included a stunning line up of fantastic projects in the UK:
Nela Brown is a sound artist/ technologist and researcher. She is currently doing her PhD at Queen Mary, University of London where she is also a Chair of G.Hack and WISE@QMUL. G.Hack is a collective of female researchers at the School of Electronic Engineering and Computer Science focusing on sharing knowledge and developing interactive media projects through collaboration with other universities, art organizations and industry partners. In 2011 G.Hack received funding from QMUL which kick-started a series of public engagement activities.
http://nelabrown.blogspot.co.uk http://ghack.eecs.qmul.ac.uk
Pollie Barden is a visual artist, game designer, web designer and technophile. She earned an M.S.P. from the Interactive Telecommunication Program at New York University and is currently doing her PhD in Media Arts and Technology at Queen Mary, University of London where she is also a member of G.Hack and in charge of co-ordinating departmental qMedia Hack Days.
http://pabadesigns.com
Anna-Maria Spehar-Deleze and Salzitsa Anastasova-Ivanova are postdoctoral researchers at the School of Engineering and Material Sciences at Queen Mary, University of London and members of the WISE@QMUL committee. WISE@QMUL (The Women in Science and Engineering Society) was set up in 2008 as an informal group for discussion and networking amongst QMUL students interested in the role of female participation in science. The society currently has 130 members spread across the Faculty of Science and Engineering and the Faculty of Medicine and Dentistry and welcomes men as well as women from undergraduate level to professors. In 2012 the society received substantial funding from QMUL, which enabled them to organize seminars, talks, workshops and socials in 2012 and will ensure sustainable growth in years to come.
http://wiseqmul.wordpress.com
Paula Graham is a director of Fossbox; a non-profit offering consultancy on collaborative working, peer support and peer training and co-founder of Flossie; a collective of women from digital and arts organisations sharing a common commitment to celebrating and enabling women’s contribution to FLOSS culture. The first Flossie conference was held in May 2012 at Queen Mary University of London and was followed by a 3 day ‘Career Taster’ in October 2012 at The National Museum of Computing in Bletchley Park.
www.fossbox.org.uk www.flossie.org
Heidi Harman is a serial entrepreneur, mentor and speaker and also co-founder of Geek Girl Meetup. She is currently working on her new startup in the mobile finance sector.
www.geekgirlmeetup.com
Carrie Anne Philbin (yours truly) is a KS3 ICT Subject Leader & Google Certified Teacher at Robert Clack School in Dagenham. She is a Creator of the Geek Gurl Diaries, a youtube video series designed to inspire more teenage girls to take up STEM and Computing subjects.
www.geekgurldiaries.co.uk @geekgurldiaries
I was excited to network with these projects to hopefully collaborate with in the future. I'm excited to find female role models in STEM subjects who would be willing to do interviews and perhaps help me run workshops. If you love technology I would recommend getting involved with any if not all of the projects and groups listed above.
Friday, 2 November 2012
Talk Talk Digital Heroes Award 2012
I'm very excited to announce that Carrie Anne Philbin of Geek Gurl Diaries has been nominated for a Digital Heroes Award by Talk Talk and is on of three fantastic finalists in the London region.
She needs your votes! So please vote and tweet about it to your friends:
She needs your votes! So please vote and tweet about it to your friends:
Subscribe to:
Posts (Atom)
