Category Archives: Uncategorized

Capturing individual frames from a USB webcam at full quality


Here’s the method I’m using to create a set of images from a webcam (at 1920×1080) as reliably as possible.

I’m using a simple 2 step process:

First, I’m capturing from the webcam at a constant bitrate with a rather lossless quality
Duration is set to 15 seconds, writing to capture.mp4, overwriting existing files.

ffmpeg -f video4linux2 -input_format yuyv422 -an -i /dev/video0 -r 30 -c:v libx264 -qp 18 -t 15 capture.mp4 -y

Secondly, I’m simply converting the video clip to png:
ffmpeg -i capture.mp4 image_%04d.png

This gets problematic at this quality though:
My 15 seconds video clip is ~13 MB
The 450 png files total over 1.1 GB

Be careful!

The purpose for this is to eventually make animated gifs from a purpose built crank camera similar to Otto


PCB design to do list

  • USB to RS232 adapter.
    • Not a cable, just a metal jacket with DB9 connector on one end and a USB-B micro / Mini or maybe Type C
    • FTDI 232R
  • EPS8266 breakout to adapt its header to the quasi-standard FTDI header
  • Front panel USB3 ports for my CoolerMaster Centurion 534+ case
  • RGB LED controller, powered by Atmega 328p or better (Arduino)
  • EPS8266 IR blaster (adapter board)
  • Relay board with Intel Galileo header for sprinkler controller.

Building UEFI for the Galileo


It would seem to me that finding the correct and most up to date components for building UEFI firmware for the Intel Gelileo (1 or 2) would be much easier if all of the code was at (actually sourgeforge / github, but close enough).

Unfortunately, the folks who created the QuarkBSP have either decided to not do that or the legal at Intel has not approved.

Either way, I am keeping notes here for the most straight forward and future-proof method of obtaining the needed components as well as procedures for actually building an EDKII based UEFI firmware for the Galileo Boards.

First, Intel seems to have the most official document here:

This is Intel Doc 329687, as of April 2015, it seems to be at revision 329687-008US
(Hopefully, this link is future proof. If not, just go to and search for “329687”)

This guide has a section called “downloading the software”, which points here:

Download the “Board Support Packages for Intel Quark”, you’ll have to agree to honor the Open Source Licenses. Don’t be a jerk, OK? Again, In April, 2015, teh link looks like this:


Inside the tar.gz, you’ll hopefully see Quark_EDKII_v<x.x.x.x>.tar.gz. Right now, it is “Quark_EDKII_v1.1.0.tar.gz”

This is what you need to build the UEFI firmware for the Galileo.



Essay Analogies


I recently found an old email that I sent to my wife (a teacher) in June of 2006, before we started dating. The email is below.

Every year, English teachers from across the country submit their collections of actual analogies and metaphors found in high school essays. These excerpts are published each year to the amusement of teachers across the country. Here are last year’s winners…..

1. Her face was a perfect oval, like a circle that had its two sides gently compressed by a Thigh Master.

2. His thoughts tumbled in his head, making and breaking alliances like underpants in a dryer without Cling Free.

3. He spoke with the wisdom that can only come from experience, like a guy who went blind because he looked at a solar eclipse without one of those boxes with a pinhole in it and now goes around the country speaking at high schools about the dangers of looking at a solar eclipse, without one of those boxes with a pinhole in it.

4. She grew on him like she was a colony of E. Coli, and he was room-temperature Canadian beef.

5. She had a deep, throaty, genuine laugh, like that sound a dog makes just before it throws up.

6. Her vocabulary was as bad as, like, whatever.

7. He was as tall as a six-foot, three-inch tree.

8. The revelation that his marriage of 30 years had disintegrated because of his wife’s infidelity came as a rude shock, like a surcharge at a formerly surcharge-free ATM machine.

9. The little boat gently drifted across the pond exactly the way a bowling ball wouldn’t.

10. McBride fell 12 stories, hitting the pavement like a Hefty bag filled with vegetable soup.

11. From the attic came an unearthly howl. The whole scene had an eerie,surreal quality, like when you’re on vacation in another city and Jeopardy comes on at 7:00 p.m. instead of 7:30.

12. Her hair glistened in the rain like a nose hair after a sneeze.

13. The hailstones leaped from the pavement, just like maggots when you fry them in hot grease.

14. Long separated by cruel fate, the star-crossed lovers raced across the grassy field toward each other like two freight trains, one having left Cleveland at 6:36 p.m. traveling at 55 mph, the other from Topeka at 4:19 p.m. at a speed of 35 mph.

15. They lived in a typical suburban neighborhood with picket fences that resembled Nancy Kerrigan’s teeth.

16. John and Mary had never met. They were like two hummingbirds who had also never met.

17. He fell for her like his heart was a mob informant and she was the East River.

18. Even in his last years, Granddad had a mind like a steel trap, only one that had been left out so long, it had rusted shut.

19. Shots rang out, as shots are known to do.

20. The plan was simple, like my brother-in-law Phil. But unlike Phil, this plan just might work.

21. The young fighter had a hungry look, the kind you get from not eating for a while.

22. He was as lame as a duck. Not the metaphorical lame duck, either, but a real duck that was actually lame, maybe from stepping on a land mine or something.

23. The ballerina rose gracefully en Pointe and extended one slender leg behind her, like a dog at a fire hydrant.

24. It was an American tradition, like fathers chasing kids around with power tools.

25. He was deeply in love. When she spoke, he thought he heard bells, as if she were a garbage truck backing up.