Thursday, July 30, 2009

Taxpayer-funded Playground

I spend a lot of time on various government websites. NASA, USGS and NOAA, for example, have provided me with hours of opportunity to learn the esoteric and fascinating things we've paid for with our tax dollars. Nothing prepared me, though, for something what I ran across today.



This site could easily absorb every hour in the day for an indefinite period of time. It has tools and datasets from the DoD to the CDC to the USGS all in one place! Hundreds of thousands of images, web widgets, charts, graphs... It's exhausting in extent. If you like data, lots and lots of data, take a look.

Labels: , , ,

Monday, July 27, 2009

Periodic Table of Videos

Just a pointer to a really great website with a really great concept: the Periodic Table of the Elements with a video for each one. The videos range from narratives to demonstrations, and are all interesting and a lot of fun.


Warning! Dangerous(ly fun) Chemicals!


The site is great for kids or adults. Just be sure you set aside some time before visiting because you won't want to stop watching.

Labels: , , ,

Thursday, May 14, 2009

Google Maps Hates UC Santa Barbara

I don't know why but it appears the Google is trying to keep people from getting to UC Santa Barbara, at least people from Torrance. Has Google finally begun to use their hegemony for evil?


You'll need this...


Read the "driving" directions carefully. I'd still like to know the real explanation.

(Part of the explanation is that there is a Santa Barbara in NZ, but this seems like an amateurish joke-gone-bad thing I wouldn't expect from Google. The query is reasonable.)

(screen shot here in case they've "fixed" it.)

Labels: , ,

Tuesday, March 24, 2009

The Best Use for Java

In theory, I like Java. Strongly object oriented and platform agnostic, I want to like it. Unfortunately, I don't. Almost* every application I have used written in Java is quirky, bloated and has an unpleasant interface. But, there is one use of Java that I have always applauded: web-based applications for scientific visualization.




Visualizing a ripple tank, animated and fully interactive fascination


Java turns out to be a great way to provide simulations on web pages, and there are quite a few very nice ones out there. Recently, a colleague asked me about antenna radiation visualization software and in the process of researching the question I stumbled into a veritable treasure trove of just the kind of Java applet I appreciate.

Paul Falstad in a fit of prolificacy has produced an impressive menu of math and physics visualization applets and put them on the web for all of us to mesmerize ourselves with. They are very well done, and offer interaction and both 2- and 3-dimensional views. Warning: You might want to be sure you don't have anything important to to do for a while before you visit that link.

__
* Cyberduck, the very nice OS X FTP/SFTP client was written in Java but used the Cocoa API to make it indistinguishable from a native OS X application. Cyberduck lives on here but I don't think it uses Java any more. However it is really spiffy and worth checking out as it has grown many new abilities.

Labels: , , ,

Thursday, November 01, 2007

Relatively Monstrous

Today, Shlomo (our youngest, at 6), came walking stiff-legged into the room and up to my wife.



Where did Igor get that brain?


Shlomo:  I am acting like Frankenstein. E equals M C squared.
Shoshi:   That's Einstein.
Shlomo:  Oh.


Sometimes Shlomo says things that leave us scratching our heads. I still don't know where he learned about E=MC².

Labels: ,

You Are What You Eat

Around here the squirrels can be a bit nutty. They get used to humans and lose much of their fear. This leads to odd behaviors. I have seen squirrels do this in the trees but never like this, on the ground.


In spite of appearances, the little guy did not just come from the tree


It is very hard to avoid assigning human emotions to animals. I don't know if this squirrel was really having fun but it certainly looked that way.

I like squirrels, I think I will take more photos of them.

Labels: ,

Thursday, October 18, 2007

Undoing INSERT COIN and Related Ideas

YOU CAN FIND THE ORIGINAL POST HERE.


Wow. This post has seen more than 50,000 hits in less than two days (UPDATE: it has now exceeded 110,000 in three days). To say that it was unexpected is completely insufficient to describe my reaction. In any case, thanks for sharing my fun. And that's exactly what this is meant to be, fun. Not malicious, not mean-spirited, not damaging in any way. Almost all the comments I have received reflect that spirit. There are a few, however than don't make me smile (and didn't make the comments page).


Un-"hacked", and READY


First, if you came here because you were "hacked" there is an easy solution. Power-cycle your printer. That is, turn it off, wait a few seconds, turn it on. The program uses a documented, supported feature of HP's product to do something very ephemeral and undoing it is as easy as a restart.

Second, please have fun but think before you act. If it is against the culture of your office enviroment to have this sort of fun, consider not trying. You will be the only one having fun. More serious may be a violation of your company's Acceptable Use Policy which could get you in real trouble.

So, please, practice "safe hacking" and use your entire brain when choosing how to use this information.

Have fun.

Labels: ,

Tuesday, October 16, 2007

Get the Weather on your HP 4200

I mentioned, here, that I wrote a program to put the weather on the HP 4200 in our office. The program uses the perl Geo::METAR module to parse METAR weather information from NOAA. You'll need to install the module if you don't already have it (and you probably don't). Install it using ActiveState's PPM for Windows and the CPAN program (or OS package manager) for everything else. You will also need to know your ICAO airport code and the IP address of your printer.


How does it know?


You can use some sort of cron job or the Windows "at" service to run it periodically. The METAR data doesn't actually change more than once an hour so more frequent updates won't buy more accuracy. This program requires a little more assembly than the earlier one but the comments in the source should be sufficient. The code itself was a 10-minute hack and is not intended to be lovely, but it has performed flawlessly for years now. The program targets the HP 4200 but it is very possible that it will work with other large display printers as well—it can certainly be modified to do so.

I like this one because it is hackish and useful at the same time.

NOTE: Windows users installing Geo::METAR via PPM may find that the temperature variables need to be edited. If you get errors you can try making them C_TEMP and F_TEMP. I haven't tracked down why this is true, but it appears to be.

Labels: ,

INSERT COIN

PLEASE READ THIS BEFORE USING THE PROGRAM (or if you are not amused)


Can this silliness be used for good? Perhaps...


It is amazing how unaware some people can be. This little perl program allows you to set the "Ready Message" on HP printers to whatever you'd like. (if you want to run it under Windows, and don't know how, read this.) I wrote it after coming across the command in an HPPJL (HP Printer Job Language) reference manual I was reading for some reason that I now forget. Thanks to the flexibility and power of perl, it was a no-brainer to play with the new information. (Maybe you should consider learning perl?)



I want my ready back!


Well, of course I couldn't ignore such an opportunity, and it turns out to be a lot of fun. You can think up your own funny, confusing or scary messages. My personal favorite is "INSERT COIN" which fits perfectly on the small LCDs. You can even sit in sight of the printer and change the message while watching the reaction of your victim (or reading about it). Don't be surprised, though, if a large fraction don't even notice. I was quite surprised myself but, it appears, some people don't look at what is in front of them.

I wrote a more elaborate version that takes advantage of the HP 4200's larger, four-line display. It sends the current weather conditions which I grab from NOAA using the perl Geo::METAR module. It updates every 10 minutes. Amazingly, while many people noticed the report on the printer display, no one questioned it!

People are endlessly surprising. Isn't it great?

NOTE: There have been many requests for help with this. Non-networked printers, running the script, etc. While I cannot guarantee anything, you might find help on FreeNode's #perl IRC channel, here. In about three days this post has garnered more than 105,000 unique visitors. If a few of you can lurk there and help out it would be great. Apparently many of us share a sense of humor. Maybe there is an "INSERT COIN" community. Who knows?

A Philosophical Comment


The anonymous comment below, accusing me of considering myself "king of the hacker elite" made me re-read this post. I originally thought he was responding to a comment I made, not the post itself. After thinking about it I realized he might not have read any of the comments at all. That being the case, let me be very clear about something: while I definitely enjoy being extremely extroverted in my attention, and noticing all sorts of details and peculiarities in the world around me, I do not believe that such a tendency is exclusively meritorious or inherently superior. I work with many people who do not share this cognitive style but are intelligent, insightful people who have taught me a lot. Please don't take the observations above as belittling people who don't share my natural fascination with the things in the world. That would be much different than my intention.

Labels: , , ,