Pew Pew Laser Blog

Code. Glass art. Games. Baking. Cats. From Seattle, Washington and various sundry satellite locations.

Jim's Artichoke Spinach Dip.

4.25.2017

Artichoke spinach dip in a casserole dish I've got a friend named Jim who is pretty skilled in the kitchen. I've stolen and modified this recipe for artichoke spinach dip from him; it's a creamy warm dip which I often make when hosting friends for the yearly gluttony and football game extravaganza. Reminder to self - many of the ingredients can be bought at Trader Joe's.

The STEMTera Breadboard and Johnny-Five's five.Leds.

4.7.2017

The STEMTera Breadboard is a nifty combination Ardunio (Uno R3) / breadboard. It has a Lego-compatible backside and it's available in black, white, and pink. When I got mine, of course the first thing I did was get it set up to run with Johnny Five. The StemTERA breadboard with some resistors and LEDs installed.

Basic Functionality / Hello world

Making an LED blink is the Hello world! of hardware. It's common to just use an Arduino's onboard LED on pin 13. Here's what you do to get up and running from scratch:

Red and Green LEDs

Fritzing diagram of StemTERA breadboard with LEDs and resistors installed. Now let's add external LEDs (and protective resistors of course). Build your circuit as shown here, using 2 330? resistors, two 3mm LEDs, and two jumper wires. This is the magic of the StemTERA breadboard - the circuit doesn't need to hop back and forth between the breadboard and the external Arduino.

Here's the code - store it in a file and run it as with the first block of code.

var five = require("johnny-five");
var board = new five.Board();

board.on("ready", function() {

  // We can address them separately, or together in leds
  var red = new five.Led(6);
  var green = new five.Led(5);
  var leds = new five.Leds([red, green]);

  green.off();
  red.on();
  leds.blink(1000);

  this.repl.inject({
    leds: leds
    // leds.stop() // Stop the strobing
    // leds.off // Turn them both off
    // leds.stop().off(); // Combine!
  });

});

You should see the red and green LEDs alternating between on and off every second, and only one of the LEDs will be on at a time.

The interesting thing about this code is that it uses the Leds class - which allows us to control all the LEDs at the same time. At first, the green LED is off, and the red one is on. Then we blink the leds class; flipping the on/off state of each LED at the same time. You could use this to easily control many more LEDs.

Things that Matter To Me As a Speaker.

3.20.2017

Beyond the basics such as an enforced code of conduct and covered travel and lodging, there are a few things that I really appreciate as a speaker:

Sublime Text ColorHighlighter Tips.

2.24.2017

Sreenshot demonstrating ColorHighlighter for Sublime Text ColorHighlighter is a pretty nifty package for Sublime Text which can display the color of CSS colors values right in the text editor. Here are a few usage and configuration tips if you want to use it yourself.

Print vs. Online Products.

2.2.2017

Let us take a little time to compare and contrast printed products with their online counterparts - such as a printed newspaper and the same newspaper's website.

The printed version is tangible and tactile. Once printed, it can't be revised by the creator, though the user can make notes on the paper. Since it's a tangle product, the user must find a way to dispose of the used product; which may be repurposed as combustion or packing material. Each newspaper will probably only be used by one or two users.

The online version is interactive: searchable and sharable. It is easily updated. The website is much more likely to be seen by users outside of the physical area of the newspaper. Many users will use the same "version" of the paper, which can generate comments and discussions.

These are completely different products, even though they share the same content.

Creaming in Baking.

1.10.2017

Creaming is one of those weird terms you see in baking recipes. It does have a specific meaning though, and doing it correctly can really improve your baked goods.

Creaming means mixing the butter (or the main fat of the recipe) and sugar (white or brown) until "light and fluffy". This process puts a bunch of tiny bubbles into the proto-cookies, which help with leavening. You should see the volume of the mixture increase by about a third, and has lightened in color, due to all that air. You shouldn't be able to see any sugar granules, but you should be able to feel them if you rub the creamed mixture between thumb and forefinger. Creaming will take somewhere around 3 minutes with a mixer (I like to use a paddle with a scraper or edge beater in my stand mixer), and just about forever if you're mixing by hand.

Real Talk About Conference Speaking.

12.20.2016

Not to be a downer, but that "free" trip you got by having your conference talk accepted is pretty far from free. TANSTAAFL, and all that. Here some additional "costs" you may have to consider. (Organizers: think about the huge commitment your speakers are making when they agree to speak. Try to make things as easy for them as possible.)

Related: