Saturday, December 3, 2011

hippopotamus for Christmas

For some reason there's been talk of hippos this season, so I thought I'd print one.

The model was this one from Thingiverse. It printed as a top half and bottom half (10% infill, one shell). I used a heat gun to warm up the faces to stick them together.

Saturday, November 26, 2011

a Rock Band or Guitar Hero instrument hanger

I've found myself with a number of video game instruments, some of them just for parts, so I thought I'd get them out of the way and display them in the basement.

That is a 2x4 with 4" screws spaced 2" apart. It's 11" from the left screw of one guitar to the left screw of the next guitar.

The strap closest to the camera is how I've hung my Rock Band keyboard (keytar).

Thursday, November 24, 2011

metal Makerbot spool holder

A common issue with the Makerbot 3D printer is setting up something to hold the spool of plastic as it is being fed into the machine. I decided to cut a spool stand out of metal using a CNC plasma cutter that I have access to.

The spool is about 8 inches across, with a 2 inch hole in the middle (I know, metric measurements are preferable, but the plasma cutter workflow is easier in inches). I wanted something quick and easy that would hold the spool vertically, so I came up with this:

I drew it in Inkscape for cutting out of flat sheet of 1/8th inch steel, exported the drawing using Better DXF Output for SheetCam to turn it  into g-code for the CNC plasma cutter. I'm currently looking into PyCAM, heekscnc, and PartKAM as free alternatives to SheetCam, but that's another post.

After cutting it out, I bent it on a brake to an angle of about 135 degrees (about 3π/4 radians) and cleaned up the edges using a bench grinder. In hindsight it would have been easier to do those steps in the opposite order, but I guess that's part of the learning process.

And here's the (mostly) finished product. I still need to add a piece of plastic or slippery tape where the spool rests on the metal in order to allow it to spin more freely.

If I build another version of this, I'll round the corners a little more and cut some sort of design into the base.

Plasma Cutting with Inkscape, SheetCam, and Mach3

1. Start up Inkscape and under the File menu choose Document Properties. Change the default units and the document size units to Inches (in). Then close that window.

2. Make your drawing, the colors don't matter.

3. Select everything you've drawn and under the Path menu choose Object to Path.

4. Save your drawing as a Better DXF Output file.

5. Start up SheetCam. It should already be set up for plasma cutting, but check this by clicking on the Options menu and choosing Machine. The Machine type should be Jet Cutting and the Post Processor should be Mach 3 plasma pauses. Click OK.

6. Under the File menu choose Import drawing. Find your drawing (you may need to change the Files of type to DXF files). You can leave the default scaling as 1 (metric) on the next screen that comes up.

7. Under the Options menu select Job options and click the checkbox for Use drawing.

8. You should now have a preview of what your work will look like once it has been cut.

9. If for some reason you don't have any tools defined on the left side of the screen, under the Tools menu select New jet cutting tool and set the options as you see in the image below.

10. We're now set to create a new cutting operation. Under the Operation menu select Plasma cut. Decide whether you want an Inside Offset where the tool cuts on the insides of your lines, or an Outside Offset where it does the opposite.
Inside Offset
Outside Offset

11. I'd recommend a 0.2 inch lead in and lead out, as shown in the image below. Check with your teacher on what the feed rate should be for the material you're cutting and the torch setting.

12. Click the P button at the top left to run the post processor which outputs the Gcode for Mach 3. Save it as a .tap file. Put that .tap file on a USB drive if you're not sitting at the plasma controller computer.

13. On the plasma controller computer, start up Mach 3. Under the File menu, choose Load G-Code and find the .tap file that you had just created.

14. Line up the machine as demonstrated by your teacher, make sure everything is ready and safe, and start the cycle. You'll have to start it again each time it pauses. Remember to follow all of the proper safety procedures.

Friday, November 11, 2011

100 posts

Not specifically technology related, but an interesting convergence of numbers that I'm making my 100th post on this blog on the date 11/11/11.

Fun stuff.

Thursday, November 10, 2011

ideas for sending multiple text messages

A quick summary of a conversation I had today about sending text messages to multiple recipients. is set up more for individual teachers, but it may do what you need.

Twilio is a platform for building sms and phone call apps/applications.

If you know which wireless provider each of them subscribes to, you can use email to sms, and even set up a Google Spreadsheet to do that.

Or you could build an Android App (using the App Inventor if you need) that sends multiple messages from your smartphone.

Just a few of my thoughts, hopefully that helps.

Edit: I was reminded that Edmodo allows students and parents to subscribe via email or SMS.

Sunday, October 23, 2011

a fix for PowerPoint slideshows

If you find yourself using PowerPoint's feature to show on one screen while you edit on the other, you may get tired of having to switch to the "show" program to advance slides. I wrote a little AutoHotkey scrip that will switch to the PowerPoint slideshow before firing the page or arrow keys:

#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.

MsgBox, The PgDn, PgUp, and arrow keys will now switch to the PowerPoint show before enacting. Close the H in the taskbar to quit.

WinActivate, PowerPoint Slide Show
Send {PgDn}

WinActivate, PowerPoint Slide Show
Send {PgUp}

WinActivate, PowerPoint Slide Show
Send {PgDn}

WinActivate, PowerPoint Slide Show
Send {PgUp}

WinActivate, PowerPoint Slide Show
Send {PgDn}

WinActivate, PowerPoint Slide Show
Send {PgUp}

IfWinActive, PowerPoint Slide Show
Send !{TAB}
Send {WheelDown}

IfWinActive, PowerPoint Slide Show
Send !{TAB}
Send {WheelUp}

Tuesday, September 27, 2011

spreadsheet formula for getting domains from email addresses

In case you're using Excel, Google Spreadsheets, or another spreadsheet program and you have a list of email addresses that you'd like to use to get a list of domains, you can use the formula:

=RIGHT(A1, (LEN(A1)-(FIND("@", A1))))

What this gives you is the characters from the RIGHT of the text in cell A1 up to the @ sign. FIND tells the equation where the @ symbol is from the left, which is then subtracted from the LENgth of the text in cell A1.

Thursday, September 8, 2011

Vernier Sensors and Arduino (or Teensy) for Data Logging

I've been thinking for a while about inexpensive data logging with Vernier educational sensors and a microcontroller development board. I played around with the TI MSP430 LaunchPad for a while, since it is only $4.30, but it's not quite as beginner-friendly as the Arduino. I eventually settled on the Arduino-compatible Teensy for its low price ($16) and small size.

Vernier does a good job of documenting sensor pinouts and calibration values in each sensor's manual, so I knew that this was a fairly easy project.

Unfortunately the sensors use a BT631A connector, which is difficult to find outside of the UK. I ordered this BT to RJ11 adaptor from DealExtreme, but unfortunately it's only 6P4C and we need 6P6C (6 conductors). All six pins are used by the sensor, but we really only need pins 2, 5, and 6. I'll try ordering something from UXCell or Vernier, but for now I've just used some breadboarding wires stuck into the back of the connector.

The required connections from the sensor are
pin 2 to ground (GND)
pin 5 to +5V (VCC)
pin 6 to an analog in (A0)
(I haven't gotten around to trying out the auto-ID function, but that's not an extremely useful function for my purposes anyway.)

Since this my first real microcontroller project, I followed the tutorials on the Teensy site regarding connecting something to the analog input. I modified some example code by Tom Igoe and came up with:

 Analog input, serial output
 Reads an analog input pin and prints the results to the serial monitor.
 The circuit:
 Vernier probe pin 2: Ground (GND)
 Vernier probe pin 5: +5 V (VCC)
 Vernier probe pin 6: Sensor output (A0)

 created 2011-09-08 by David Hay (misterhay)
 Some code borrowed from example by Tom Igoe

 This code is Creative Commons Attribution (

// Constants, used to give names to the pins used
const int analogInPin = A0;  // Analog input pin that the probe is attached to
const int ledPin = 11; // The Teensy on-board LED is on pin 11

// Variables
int sensorValue = 0;        // value read from the probe

// The setup, which runs once when the sketch starts
void setup()
  Serial.begin(38400);     // initialize serial communications at 38400 bps,
                           // not that this matters since it runs at USB speed
  pinMode(ledPin, OUTPUT);  // set the digital pin as an output

// The actual loop that does the sampling and output to the serial monitor
// This will continue to run as long as the Teensy is plugged in
// Use the Arduino Serial Monitor or some fancy GUI to see the output
void loop()
  // read the analog in value:
  sensorValue = analogRead(analogInPin);           
  // print the results to the serial monitor:

  // wait 10 milliseconds for the analog-to-digital converter to settle

Watch the output in a serial monitor program on your computer, and paste it into a spreadsheet program for graphing. Eventually I'll build a GUI for adjusting sample rates and number of sensors and maybe some live graphing, add some calibration, and put it in a better enclosure.

Wednesday, July 13, 2011

thoughts from ISTE 2011

Here are some of my observations and thoughts from the recent ISTE Conference.

Links I came across: videos for students (Rushton Hurley)

Met at the dinner reception:

Free children’s audiobooks:

Google Apps Education Training Center

National Oceanic and Atmospheric Administration kids games

JASON Science

Open Education Resources

Topics I was interested in:
game-based learning
3D design/printing/CNC
student-owned devices
citizenship / online identity
science data collection
programming/computing science
girls in science/tech
flipped instruction

sturdy headset for language labs
distance/asynchronous/blended learning
asynchronous/flipped professional development
Administrators as technology leaders
open source
online collaboration
just-in-time teaching (versus just-in-case)
open content
student media creation (and portfolios)

Thursday, June 23, 2011

bringing technology to #ISTE11

We've had some discussion in my office about what technology to bring to the ISTE conference. Here are my thoughts and what I'm bringing.
  • iPad (or other tablet) for attending sessions
    • with audiobooks, books, and videos
  • laptop or netbook for writing and Skype/Google Talk
  • iPod Touch for walking around at night, and probably for the plane rides
    • also with audiobooks, books, and videos
Calling home:
Skype - for video calls between computers, iPad 2, iPhone, TVs, etc
Google Talk - free calls to Canada and US phones from within Gmail, free video calls to computers

And I'm leaving my phone at home, since even with a US plan it's still about $40 for 40 minutes and $30 for 0.01 GB of data.

While I'm at #ISTE11, I'll be posting to Twitter (@misterhay) and this blog.

Monday, June 13, 2011

amusement park accelerometer data

I collected some data with my phone accelerometer using the app AccDataRec. I've graphed all three axes on each of the spreadsheets in this Google Docs folder.

The best one is the Flying Galleon. I cropped off the messy data at the start and end so it's a nice sinusoidal curve.

Feel free to share and use these however you'd like.

Creative Commons Licence
This work is licensed under a Creative Commons Attribution 3.0 Unported License.

Friday, June 10, 2011

setting up Moodle Language Lab

Moodle Language Lab is an activity module developed (and being developed) by Campus Saint-Jean and that:
replaces the traditional cassette tape language lab. There is a module for students to record themselves and teachers to review and grade the work. This version also includes a class monitor. So, if a teacher uses it inside the classroom, he/she can monitor student progress the same way they used the traditional language lab by listening to live streams of the students, responding live to students, giving a thumbs up and so on.
It also offers an integration with the Moodle WYSIWYG, allowing recordings to be done virtually in any activity or resource wihtin Moodle. This feature has been used in our classes throughout the past year. For example, we had an oral forum instead of a written forum. Professors would leave spoken messages in the grade book.
It requires three programs running on a server (on the same server or separate ones):
  1. Moodle 2.0.x
  2. Red5 Media Server (version .8)
  3. Palabre XML Socket Server edit: Palabre is no longer needed
Here's how you can set up the three parts of Moodle Language Lab on a Windows server. The process will be similar for other operating systems.

  1. Download version .8 from (I recommend the ZIP file, and 1.0 RC1 worked for me)
  2. Unzip the files into some folder (not publicly accessible)
  3. Install Java, if it's not already installed, and make sure your JAVA_HOME variable is defined
  4. Run Red5.bat
  5. Go to http://localhost:5080/ to test that Red5 is running, and click "Install a ready-made application"
  6. Install the oflaDemo
  7. Make a note of the server's Internet-accessible IP address (or FQDM)
  1. Download the source files (Windows installer didn't work for me), untar into some folder (again not a publicly accessible folder)
  2. Install Python (2.7 or so)
  3. Edit the Palabre\etc\palabre.conf file, these are the two lines that I changed
    • ip = 
    • alloweddomains = #put your own value(s) on this line
  4. Run
  5. Test by running one of the Palabre clients
  6. Make a note of the server's Internet-accessible IP address (or FQDM)
Moodle (this is just pasted from the Developer's readme file)
  1. copy all folders (filter, mod, lib ) into the appropriate moodle(root) folder.
  2. Login to Moodle with admin rights.
  3. In the Site Administration block, click on Notifications. This will setup the database tables for the languagelab module
  4. In the settings block, select Site administration -> Plugins -> Activities Modules -> Manage activities -> Language lab -> settings
  5. Enter the IP address or the FQDN that you noted previously in the appropriate fields and save changes.
  6. You're done. Go into a course, turn editing on and add a language lab activity.

Tuesday, April 26, 2011

Xbox 360 tool control mat

Inspired by a blog post about making tool control mats with a CNC router, I made a "tool" control mat for a video game club's shelf.

Using Inkscape I imported a vector drawing of the 360 gamepad by grumbel on the Open Clip Art Library as the basis for the outline of the controller, resized it to the dimensions on the Wikipedia page, and made 12 copies of it (since that's how many controllers the club owns).

The slots for the games were just rectangles using the dimensions from another Wikipedia article. I discovered that I had to convert these objects to paths (under the Path menu in Inkscape) before I saved the file as a DXF file (or PDF file, depending on which CAM program you're using).

I converted the drawing to G-code for a 1/2 inch end mill as a roughing pass, thinking that I'd then do a finishing pass with a smaller bit, but decided that it was good enough after the first pass. I milled it from two inch thick extruded polystyrene foam (Styrofoam), then cut it down to size on a radial arm saw (which explains the mistake you see on the side in this last photo).

Not bad for my first successful CNC project, if I do say so myself.

Tuesday, April 19, 2011

CAD CAM CNC routing workflow

After experimenting with many different programs for CAD (3D design) and CAM (turning that design into code for a CNC router), I've come up with a good workflow using easy and free tools:

The process that works for me is
  1. design a 3D model in Sketchup
  2. export the model to an STL file using the plugin
  3. load that STL file into FreeMill
  4. generate the toolpath and post it to a G-code text file
  5. import the G-code into Mach3 and run it on the CNC machine
Hopefully this will be simple enough for students to start designing and cutting things.

Thursday, April 14, 2011

notes from the tablet symposium

I recently attended a Tablet Symposium hosted by the ATLE (Alberta Technology Leaders in Education) where a number of vendors presented their current or upcoming tablets. While there we added information to a specifications spreadsheet, and what follows are my personal impressions from that symposium, in the order that the presentations occurred.

WebOS is very cool, and I think they will be a major player. Good integration with their smart phones, similar to RIM. I'll be interested when these products finally come out. I really like their inductive charging.

They seemed to say, "We'll also be making tablets in the future, both Android and Windows."

Eee Pad Transformer is awesome. $400, decent specs, and a keyboard dock that turns it into a laptop and doubles the battery life. My favorite of the event. The Slider and MeMO look decent too, but I'm not interested in their Windows 7 tablet, even though it's available now.

Integrates with your BlackBerry, works without it too. Committed to the seven inch size for thumb typing and portability, which I like.

I'm not impressed with the Dell Streak 5 and 7. Android 2.2 and relatively low resolution makes them seem like big phones. The convertible Inspiron Duo netbook/tablet is not bad if you're wanting a Windows netbook anyway.

The current Galaxy Tab is overpriced and not competitive any more, there's not much information available about the attractive upcoming Android 3.0 tablets.

Android 3.0, Windows 7, decent specs, not much information on price or availability.

The Xoom is nice, good specs, Android 3.0, cheaper than the equivalent iPad, and available now.

So if I had to rank my favorites, off the top of my head based on my impressions, I'd say:

  1. Asus Eee Pad Transformer
  2. Motorola Xoom
  3. HP TouchPad
  4. BlackBerry Playbook
A number of the things we saw were pre-production, so don't hold me to this list, but I just wanted to write some quick off-the-cuff remarks.

Edit: One of my colleagues wanted to add that although his overall impression was positive, it would have been beneficial for us to have more play time with the devices, rather than just passing them around the room. He also wanted to note that he too was impressed with the Motorola Xoom and the Asus Eee Pad.

Friday, April 8, 2011

disabling user input

For example, if you are running Xibo for digital signage and don't want anyone to be able to close the program (or do anything on the computer).

Using AutoIT, the following script (which can be compiled to an .exe file) will block user input until a Notepad window is detected, which is just my way of saying BlockInput forever.

WinWaitActive("Untitled - Notepad")

Unfortunately this does not block the "three finger salute" (Alt Ctrl Delete). Using AutoHotkey, which I am somewhat more familiar with, you can disable the task manager. Again this can be compiled into an executable.

; This script disables the task manager, and re-enables it with the key combination Windows + 1

Regwrite, REG_SZ, HKEY_LOCAL_MACHINE,SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\taskmgr.exe, Debugger, Hotkey Disabled

gosub Enable

RegDelete,HKEY_LOCAL_MACHINE,SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\taskmgr.exe

RegDelete,HKEY_LOCAL_MACHINE,SOFTWARE\Microsoft\Windows NT\CurrentVersion\Image File Execution Options\taskmgr.exe

And to call this compiled script from the AutoIt script that we first talked about:

RunAs(username, @ComputerName, password, 2, DisableTaskManager.exe)
WinWaitActive("Untitled - Notepad")

It seems that AutoIT has RegWrite and RegDelete functions, of course. I rewrite the script(s) accordingly.

Saturday, April 2, 2011

transferring videos to my 5th generation iPod (with video) on Ubuntu

This is more for my own notes, so that I remember if I have to do this again.
  1. HandBrake to transcode the videos to a format appropriate for playback on the iPod
  2. install gtkpod
    • sudo apt-get install gtkpod
  3. install support for m4v files in gtkpod
    • sudo apt-get install libmp4v2-0
  4. transfer the files by drag and drop onto the iPod in gtkpod

Monday, March 14, 2011

ideas of things to build

I have a number of projects on the back burner, or in most cases still in the cupboard, so I wanted to write some of them down here. You know, in case anyone is interested in helping or can point me to where these have already been constructed. Some are software, some are hardware, most are related to education.

  1. web app for bulk deleting users from Google Apps for Education (using Google App Engine)
  2. application allowing users to automatically add anyone who uses a particular hash tag to a Twitter list, similar to blastfollow (using Oauth, and perhaps Google App Engine or Chrome Web Store)
  3. something similar to Blippy for automatic sharing of which library books you have signed out
  4. an Android tablet app similar to Proloquo2Go for augmentative and alternative communication
  5. interfacing Vernier probes and sensors with a LaunchPad or Teensy
  6. locking shelf for securing (and syncing) multiple iPods in a classroom (using just a 2x4, a door hinge, and a lock plate)
  7. iPad cart or shelf similar to the Bretford Mobility Cart
  8. locking carrying case for six netbooks (for WISEST)
  9. real time control of a Mitsubishi Movemaster RM-101 robot arm using a keyboard or joystick (in BASIC)

I'm no Ben Heck, so I'd appreciate any help or direction with any of these.

Friday, March 11, 2011

iPad Guitar version 3

On episode 1422 of Buzz Out Loud, JC from San Diego suggested an iPad guitar with iPhones as frets. I only had one iPhone lying around, so I had to use my Android phone and my old iPod Touch. I used Lego for the neck, since Mega Bloks are a little bit big.

I think the next step will be to carve something like this out of a 2x4.

Monday, March 7, 2011

iPad Guitar from Mega Bloks version 2

I built a better version of my original iPad Guitar with Mega Bloks.

(Dis)Assembly video

I'm learning how to drive a CNC router, so a wooden version may be forthcoming.

Friday, March 4, 2011

iPad Guitar with Mega Bloks

Playing with Mega Bloks tonight with my kids, I remembered Brian Tong mentioned on Buzz Out Loud about iPad GarageBand needing a guitar-shaped case. So we built something.

(Dis)Assembly video

Maybe I'll build something out of wood after GarageBand comes out. With pegs for a guitar strap.

Update I've built a better version.

Thursday, March 3, 2011

Moving photos from a camera card with AutoHotkey

Just wanted to share a somewhat rough script I wrote using AutoHotkey (since my Python skills are weak and Windows-only is fine) for moving files from a camera SD card to folders organized by month.

I also set up an AutoRun.inf to run the compiled script when the card is inserted, similar to these instructions.

; AutoHotkey Version: 1.x
; Language:       English
; Script Function:
; Moving files from camera card (E:\DCIM\{etc}) to photos folder (H:\Photos\{date}) and then deleting them
; You may want to change H:\Photos\ throughout the code to something that actually exists on your computer.
#NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.

; Since the script is running from the camera card, we can use the variable A_ScriptDir to tell which drive letter the card got mounted as
SetWorkingDir %A_ScriptDir%\DCIM\

IfNotExist %DriveLetter%:\DCIM\
 MsgBox, 1, PhotoMover, Something is wrong, perhaps the camera card is not in the card reader.
 IfMsgBox, Cancel

; show a (sort of fake) progress bar and set the initial variables to zero
Progress, b,, Moving Photos, Moving Photos
Progress, 0
PhotoProgress = 0
VideoProgress = 0

; move the JPG files
; the 0 means don't include folder names, the 1 means recurse into subdirectories
Loop, *.JPG, 0, 1
; trim the date variable to the format YYYY-MM
StringLeft, FileDateYear, A_LoopFileTimeCreated, 4
FileDateMonth := SubStr(A_LoopFileTimeCreated, 5, 2)
FileDateYearDashMonth = %FileDateYear%-%FileDateMonth%

; make a month folder, if it doesn't already exist
IfNotExist H:\Photos\%FileDateYearDashMonth%\
 FileCreateDir H:\Photos\%FileDateYearDashMonth%\

; move the file to the appropriate folder in H:\Photos
FileMove, %A_LoopFileFullPath%, H:\Photos\%FileDateYearDashMonth%\

; Show (and increment) a progress bar
PhotoProgress+=1 ; increment the PhotoProgress variable
Progress, %PhotoProgress%

Progress, Off
if ErrorLevel
MsgBox, Well that didn't work... %ErrorCount% photos were not moved.

; and now move the MOV files
; first the progress bar
Progress, b,, Moving Videos, Moving Videos
Progress, 0

; the 0 means don't include folder names, the 1 means recurse into subdirectories
; we should probably do this for *.AVI files too
Loop, *.MOV, 0, 1
; trim the date variable to the format YYYY-MM
StringLeft, FileDateYear, A_LoopFileTimeCreated, 4
FileDateMonth := SubStr(A_LoopFileTimeCreated, 5, 2)
FileDateYearDashMonth = %FileDateYear%-%FileDateMonth%

; move the file to the appropriate folder in H:\Photos
FileMove, %A_LoopFileFullPath%, H:\Photos\%FileDateYearDashMonth%\

; Show (and increment) an approximate progress bar
VideoProgress+=1 ; increment the VideoProgress variable
Progress, %VideoProgress%

Progress, Off
if ErrorLevel
MsgBox, Well that didn't work... %ErrorCount% movies were not moved.