OpenWRT-Bedtime

I’ve put together a script to schedule the kids’ wifi network on our OpenWRT router.

We have a D-Link DIR-835 (with two radios), running OpenWRT Barrier Breaker 14.07. The 2.4GHz network is set up for the kids on radio0, and only the grownups have access to the 5GHz network. I wanted a way to shut off the wifi at Finn’s bedtime (which is later than I usually want to stay up) and have it running again in the morning.

Initially I set up cron jobs to stop & start the wifi at appointed times, but that means editing the crontab when Finn has a day off school.

Next I wrote a simple script to check the time and bring the wifi up/down based on that, unless the current date is listed in a config file.

I finally updated the script with configurable up & down times, weekends, and config files.

The script and sample code are up on BitBucket, at https://bitbucket.org/eroosenmaallen/openwrt-bedtime. Feedback and improvements are welcome.

Triskaidekaphobia

Inspired by @TheBloggess, I have put together a simple WordPress plugin to fix dates for those with triskaidekaphobia.

Inspired by @TheBloggess, I have put together a simple WordPress plugin to fix dates for those with triskaidekaphobia. Right now it’s pretty trivial; as I refresh myself on WordPress development, I’ll add a few options, etc. In the meantime, all it does is replace the year “2013” with “The Library” (see In the Library) and the date “13” with “12+1”.

Download: triskaidekaphobia-0.1

On solipsism…

If a solipsist kills himself, is it suicide or genocide?

Two thoughts on the subject:

If a solipsist kills himself, is it suicide or genocide?

If you kill a solipsist, does that count as suicide?

My thought on this one is that it depends on your own philosophy – If you agree with the solipsist in question, that the whole of reality is what they perceive, then yes.

On existence

I’m presently reading Age Of Spiritual Machines by Ray Kurzweil, and came across an excellent quote that speaks to my own thought on the “immortal soul.”

I often dream about falling. Such dreams are commonplace to the ambitious or those who climb mountains. Lately I dreamed I was clutching at the face of a rock, but it would not hold. Gravel gave way. I grasped for a shrub, but it pulled loose, and in cold terror I fell into the abyss. Suddenly I realized that my fall was relative; there was no bottom and no end. A feeling of pleasure overcame me. I realized that what I embody, the principle of life, cannot be destroyed. It is written into the cosmic code, the order of the universe. As I continued to fall in the dark void, embraced by the vault of the heavens, I sang to the beauty of the stars and made my peace with the darkness.
– Heinz Pagels, physicist and quantum researcher (as quoted in The Age of Spiritual Machines)

As time goes on, I hope to put more of my thoughts into enough of an order to put them in words here.

Advertising Gone Mad

From http://www.tommyvallier.com/2009/07/23/digg-advertising-gone-mad/ –
The ads are therefore taking up 49.35% of the viewable space. Let me repeat that: fourty-nine point three five percent. For advertisements. That’s MASSIVE.

Tommy Vallier gives a breakdown of space use on Digg’s homepage, and it’s not flattering.

The ads are therefore taking up 49.35% of the viewable space. Let me repeat that: fourty-nine point three five percent. For advertisements. That’s MASSIVE.

~ Tommy Vallier

It gets even worse once the white-space is accounted for, with two thirds of the screen real-estate dedicated to advertising.

Kingston Weather – Twitter feed

Some time ago, I set up a Twitter account to relay the local weather report to my cellphone. The plan was to use TwitterFeed to relay the RSS from The Weather Network to the Twitter account, then follow it via SMS.

Lots of sabots in the works. First and foremost the RSS from The Weather Network is no good (incorrect/invalid/inconsistent date formats, some other brokenness). Twitterfeed offers two ways to detect a new posting – the GUID, or the pubDate. As mentioned, the pubDates used in the feed are just plain wrong, so no help there. The GUID for each post, also not helpful – it’s the static link to the current weather page; long-term forecast is indicated by ref=day1, ref=day2, etc in the URL – so that doesn’t change, even when the content does.

I have meant for a long time to fix it (before today, the last post form Twitterfeed was July 18), but aside from a few quick hacks, never completed it. Lately, the explosion in Kingstonians using Twitter has inspired me to fix it, especially the new followers @KingstonWeather has gained.

After some trial-and-error, I ended up building a php script to write an entirely new RSS feed, based on the one provided by The Weather Network – this one is valid, has proper (unique) IDs for the posts, and appears to work in Twitterfeed.