Log in

No account? Create an account

t3knomanser's Fustian Deposits

That was stupid...

How Random Babbling Becomes Corporate Policy

run the fuck away

Mad science gone horribly, horribly wrong(or right).

That was stupid...

Previous Entry Share Next Entry
I wrote a program that makes the scroll-lock LED blink on and off every second. No reason.

Though I think I'm going to setup my xserver so that I can control all three keyboard LEDs, and do something mathematical and geeky with them.

This was inspired by Cryptonomicon, by Neal Stephenson, in which the main character surrpetitiously communicates with a computer while being spied on (he can't put the data on screen, he can't type in commands without it being monitored by someone). So, he writes a program that allows him to give commands using morse code and the space bar, and get output using morse code from the scroll lock button.
  • How'd you go about doing that? Which language/library did you use?
    • Perl and just used the system() function to call xset on the command line.

      xset led 3 turns it on, xset -led 3 turns it off. If you make a few changes in your XF86Config file, you can control all of the LEDs-

      in your keyboard section, add
      Option "Xleds" "1 2 3"

      and restart your xserver.

      There's obviously a better way- one that actually allows you to control it, but this was quick and easy. If you do a google search for xtleds, that's an open source project that uses the keyboard LEDS to monitor network traffic- you can probably find the better way in that source. If you don't, I'm gonna, because I'd kind of like to do it right.
      • Well, I'm not going to, so go for it. I am a bit curious to know what you find, but I've got plenty of other research to be doing. :D
  • OK, that is awesome! I feel I need to read that book! Cool idea for a program too :D
    • It's a great book- very neat. Not nearly as fast paced as Snow Crash or Diamond Age, the other two books by him I've read- and enjoyed thoroughly.
      • The problem is that it needs a strong editting.

        For instance, can you explain to me the usefulness of describing eating Cap'n Crunch in PAGES of detail?
        • That scene was great! Of course, that was only because I am much the same way with my cereal- the milk should be _very_ cold, and you have to eat it as fast as possible, no talking, no reading, otherwise it gets soggy and nasty.

          My biggest editting complaints were in continuity- he'd leave one plotline, go to another, come back to the first plot six months later, without letting you know he just jumped time like that.
Powered by LiveJournal.com