Home
Dave

Blog
Archives
By Subject

Recent:

Dead Fish
Hand
Colettes Pets
Thermometer
Reading List 2025
Tamper Resistant
Claire
Multibus
Leek and Annatto
New Book
Repointing
Ansel Adams
Ubik Fashion
Nautilus Shard
Betty Boop Dance
Reading List 2024
Ready for 2025
Shuttle Computer
Abstract Arcs
Election Night

SMS

I really love playing with text messaging from my computer. It's such a simple interface: phone number & one line of text. Writing code that sends or responds to sms is like 80s programming. The web has gotten so complex that I really don't want to deal with it anymore (in terms of programming). sms though... sms is still fun.

This is my "phone":

It's a 3g modem board in a Cisco router. The router is configured so that telnetting to a specific tcp port gives you access to the modem's AT command level prompt. My sms-daemon program runs on a server running OpenBSD.

This is the script for my twitter bot:



#!/bin/sh

cd /home/dave/sys/lib/bowie
f=lyrics.txt
n=`next`

send-sms twitter `sed -n ${n}p $f`

Trivial, yet functional. It's called from crontab every night at midnight, and posts one line of text from a Bowie song to twitter. Lovely. I have a year and a half worth of lyrics queued up.

For incoming sms, my sms-deamon lanches the "process-sms" script for every message received. This allows for all sorts of fun things, home automation, etc.