## An LTSpice screencast using screentoaster.com

I was trying to remember how I did screencasts before, but instead discovered the interesting online service at screentoaster.com. It doesn’t require that you download any software: you can quickly record what occurs on the screen and upload it either to youtube.com or their own server, and then embed in a blog post. Here is my first attempt: demonstrating a simple astable multivibrator circuit that I cribbed from Hans Summers’ low powered QRSS beacon project. Using LTSpice, you can easily reproduce the schematic and then find out how it varies the voltage and current.

This is really just a test, I hope to have some more interesting circuit examples in the not too distant future.

## Wolves And Rabbits

I really like programmpraxis.com. Today, they had an interesting little task, not so much for the program itself, but for what it reminded me of. But first, the task: basically to simulate a simple set of differential equations which model a predator prey relationship. It’s not that hard really, this just implements the model using a Runge-Kutta integrator.

```#!/usr/bin/env python

# http://programmingpraxis.com/2009/12/01/wolves-and-rabbits/

def population(r, w, rg, wg, rd, wd):
def dr(x, y):
return rg * x - rd * x * y
def dw(x, y):
return wg * x * y - wd * x
while True:
yield r, w
rh = r + dr(r, w) / 2.
wh = w + dw(w, r) / 2.
r = r + dr(rh, wh)
w = w + dw(wh, rh)

g = population(40, 15, 0.1, 0.005, 0.01, 0.1)

for x in range(201):
r, w = g.next()
print r, w
```

If you plot out the data, you get curves looking like this:

This reminded me of an article by A. K. Dewdeny from Scientific American back in December of 1984, entitled Shark and fish wage an ecological war on the toroidal planet Wa-Tor. Wator was an implementation of a shark/fish predator prey model, but displays a similar set of interleaved periodic population changes. Unlike this program though, it works by directly simulating the world by creating individual sharks and fish, and modeling their interactions. It was a fun, simple project which didn’t require any real understanding of mathematical methods.

Courtesy of Zeid, I finally got an invite to use Google Voice. I’ll write more about this when I figure more about it, but at a minimum, it gives you a real phone number (amazingly, for free) which anyone can call and leave voice mail. You can configure it to ring a different phone (say, your cell phone) or send it directly to voicemail. You can access your voice mail in the conventional way, or by using a computer online. It even automatically transcribes the message into text! Very cool, and thanks Zeid for hooking me up.

Here’s an example of what you can do. This is a little flash widget. If you click on it, you can type your own name and a number that you can be reached at. Google will then call you back and hook me to my voicemail (or, if I configured it differently, ring my cell). Give it a try if you like. I’m just starting this, and it seems that you can’t select the “Conceal my number” checkbox if you want this to work. It also won’t work from international numbers.

Addendum: Here is an example of what Google Voice can do with a voicemail message.

## LM3909 Oscillator

I was wandering the net at random, following various links, and ended up researching a rather interesting integrated circuit that I’ve used before: an LM3909 LED flasher chip. It’s an interesting chip which can flash a regular LED with a 2v voltage drop using only a single 1.5v battery. I used to have this breadboarded up on my bookshelf ages ago, and it would flash for months using a single AA cell, and probably for years using a D cell. The problem is that this chip is kind of hard to find these days, and when you can find them, you end up paying \$5 each. What’s cool is that someone actually worked out the circuit from the databook and drew up a completely discrete version.

Discrete LM3909 Oscillator

## From the Brainwagon Archive: Silly Arduino Project #1: A Trivial Beacon

One year ago tody, I tinkered together a very simple program and keying circuit to use my Arduino to send out a simple Morse Code beacon message.

brainwagon » Blog Archive » Silly Arduino Project #1: A Trivial Beacon

It seems like complete overkill to me to use a \$30 microcontroller to do this task though. A couple of different groups have created PICs and the like which can be used to do the same, with a total cost of well under \$10 (the chips are probably around \$2 or so a piece). I keep thinking that what I should do is code up a simple version of this kind of application in ATMEL AVR assembly code and make it available. I can envision a simple web based application that would enable you to enter a list of beacon messages you want, and then hit a button and download the necessary firmware, all assembled and ready to go. Just burn and go…

I need more hours in the day.

Addendum: K1EL makes a \$6 Keyer chip. Expanded Spectrum Systems makes a nifty “Freakin’ Beacon” controller that includes the ability to sync with a GPS for timing.

## Using the 74HC240 in radio applications…

There are a number of interesting radios based upon using things like hex inverters or octal drivers as both oscillator and amplifier. In digging around, I found the most common chip used in this application is the 74HC240. Here’s a link to a page which contains many interesting links:

Testes com 74HC240

Another link to a similar design which points at a QST article which you can access if you are a registered ARRL member.

## PROPNOMICON: From the Mountains of Madness

Shifting gears a little from my normal subject matter, I’ll confess to a certain literary guilty pleasure: I like the writings of H. P. Lovecraft. I’m not saying they are the highest literature: I just find them to be an interesting style, creating a mythos that I find a compelling backdrop for a collection of creepy stories. I also like things like fossils and the like (I keep an Elrathi kingii on my desk). So, I find the following craft project strangely compelling: to create Lovecraft-themed props.

Gads. Next, I’ll be making steampunk stuff…

PROPNOMICON: From the Mountains of Madness

Every few months, I read about some one who embarks and completes a homebrew CPU project. A few months have gone by, and here’s another. Someday, I really, really, really am going to have to do this myself.

Recently I decided to take on a very ambitious project to design my own microprocessor from scratch. A couple of things inspired me on this project, the first being a book I finished, Digital Apollo by David A. Mindell. This book details the design and engineering behind the AGC (Apollo guidance computer) and I was amazed to learn how well designed both the hardware and software were for it's time. The fact that it was designed completely with 3-input nor gates made it even more amazing. The second reason is the fact that several other people have done the exact same thing, built entire computers from basic TTL logic. A few blog posts have been floating around the internet detailing other peoples CPU designs, looking at these I knew it was something I could easily do myself and would be a very fun project.

## Bokode @ Home – Recreating MIT’s bokode tech with everyday materials

One interesting paper I read from this years SIGGRAPH paper on the creation of an interesting real life tagging technology called Bokode. Here’s a DIY page detailing an implementation. It’s really quite simple (and neat!) I might have to code this together.

## Small caution on using PyEphem…

My previous post on using PyEphem to compute satellite locations was based upon my experience with the latest version (3.7.3.4). Apparently this includes a fairly serious change to previous versions: by default my FreeBSD box seems to install 3.7.3.3 still, and the `next_pass` method for observers doesn’t exist. So I thought I’d go back and use whatever calls they did, but `next_rising` followed by `next_setting` didn’t seem to return what I would expect. For example, this little program (first find the next rising, then, after that, return the next setting):

```#!/usr/bin/env python

import sys
import os
try:
import ephem
print "Using pyephem version", ephem.__version__
except:
print "couldn't find an installed version of pyephem"
sys.exit(1)

"1 25544U 98067A   09270.93046296  .00012316  00000-0  87133-4 0  6870",
"2 25544  51.6378 139.3506 0009010 136.5725  48.2903 15.74423743622138")

obs = ephem.city("San Francisco")

iss.compute(obs)
print "ISS is currently at alt %f az %f" % (iss.alt, iss.az)
rise = obs.next_rising(iss)
set = obs.next_setting(iss)
print rise, set

sys.exit(0)
```

When I run this rather simple little program, I get this:

```Using pyephem version 3.7.3.3
ISS is currently at alt -1.181396 az 4.241607
Traceback (most recent call last):
File "./iss", line 22, in <module>
rise = obs.next_rising(iss)
File "/usr/local/lib/python2.5/site-packages/ephem/__init__.py", line 385, in next_rising
return self._riset_helper(body, start, True, False)
File "/usr/local/lib/python2.5/site-packages/ephem/__init__.py", line 363, in _riset_helper
d1 = visit_transit()
File "/usr/local/lib/python2.5/site-packages/ephem/__init__.py", line 317, in visit_transit
% (body.name, d))
ephem.NeverUpError: 'ISS (ZARYA)' transits below the horizon at 2009/10/2 07:44:16
```

I haven’t tracked down what the deal is with this yet, but maybe I should keep on with my Python Plan13 code a bit longer.

## Why work for a game any company like this?

This link is making the rounds of a couple of different mailing lists I’m on.

Activision games to bypass consoles – News at GameSpot

When he wasn’t promoting the company’s games or technology, Kotick was celebrating its laserlike focus on the bottom line. He pointed to changes he implemented in the past as being particularly beneficial, such as designing the employee incentive program so it “really rewards profit and nothing else.”

“You have studio heads who five years ago didn’t know the difference between a balance sheet and a bed sheet who are now arguing allocations in our CFO’s office pretty regularly,” Kotick said.

He later added, “We have a real culture of thrift. The goal that I had in bringing a lot of the packaged goods folks into Activision about 10 years ago was to take all the fun out of making video games.”

Oh, goody. And…

The executive said that he has tried to instill into the company culture “skepticism, pessimism, and fear” of the global economic downturn, adding, “We are very good at keeping people focused on the deep depression.”

In a way, I do understand. We are all in business to pay for our housing, our food and our health insurance. If we are lucky, we get to put some away for retirement, and even get to enjoy some of life’s little pleasures (many of which, despite the claim that the best things are free, often seem to require money). We have to look at things like costs in our planning, and we have to be aware of global changes in the market for our products to ensure that we remain employed. That kind of planning isn’t always the funnest thing to do, nor does cheerful optimism keep companies afloat.

But seriously, it needn’t be a death march. Fear can be a strong motivator, but it’s not sustainable, and it’s no great muse when it comes to creativity and innovation. Kotick’s entire strategy is to acquire and market sequels to existing products, and to milk them on every platform in every way possible. I can understand why bean counters like this: it’s essentially a low risk way to maximize profits. And, in fact, he’s been pretty darned successful doing precisely that. And, he’s not alone: a great deal of the film industry works precisely this way.

I’ve recently gained a slightly more charitable view toward sequels. They are successful, and it’s not entirely because people are sheep. It is because they saw something in the original work which they liked, and they want more of it. Their desire to slap down money on sequels is a compliment to the original work, and to their trust in you to continue to deliver that kind of positive experience that they originally remembered. But here is the tricky thing: it doesn’t last. We see this time and time again in the film industry. A great movie becomes a good franchise, then an okay franchise, and ultimately peters out into a dreadful mess. Occasionally, these franchises can be resurrected, but it usually takes a completely new approach by a completely new director/producer who isn’t afraid to bring something new to the table and take risks. Witness Abrams’ revival of the moribund Star Trek franchise if you need a recent example.

Great movies (and great games) are the result of great direction and great technical staff doing the work they love. People who are that good at their job aren’t going to be content with just doing the same thing over again: they are going to be looking for ew challenges and new opportunities. Hence, you generally end up with paler and paler imitations of the original painting, until it’s just something to wrap your fish and chips.

Bleh.

## Project Icarus

A group of MIT students did a high altitude balloon launch. That’s really not all that unusual: radio amateurs do similar launches several times per year. What is unusual is the price tag: \$150 total. They used an inexpensive Canon camera running the CHDK firmware to snap images, and a cheap no-contract Motorola phone to communicate coordinates back. It’s not the greatest engineering choice really: the cell phone lost contact after gaining only 2500 feet in altitude, but it is a pretty interesting idea. They managed to do just about the minimum possible and still create a recoverable high altitude payload. There was no custom hardware at all. Check it out:

## HAKMEM 175

HAKMEM is a legendary technical memo from MIT that’s packed full of interesting bits. On this occasion, I ran across item #175, which you can find here:

HAKMEM 175

This is a little chunk of code which given an integer, computes the next highest integer with the same number of one bits. This code is expressed somewhat sub-optimally for modern audiences, since it is PDP-10 assembly code, but encompasses a neat, but subtle algorithm. One might ask what use such a seemingly esoteric function is, but it is quite useful in quickly generating all subsets with a given number of elements. Nifty.