Wednesday, April 30, 2008

F-keys as control characters

It's somewhat easily found online that control characters map onto a keyboard easily. Take the numeric value of the control character, add 64, and you get a letter. Press Ctrl and this letter, and you get the control character.

However, one thing I couldn't fine anywhere online was how the F-keys mapped to ASCII. I needed a way to send them over a serial connection, and couldn't find a way.

Turns out that F1 is sent in three bytes; in decimal they are 27, 79, 80. For the other F-keys, the last byte is incremented, up to F4 (27, 79, 83). HyperTerm doesn't seem to send anything if you press F5 and beyond.

Tuesday, April 29, 2008

Dell notebook fans

I was working with a Dell laptop (Inspiron 1150, to be specific) last week whose fan had stopped working. The computer was going into auto-shutdown in a matter of minutes, even with an Antec cooling pad (a very nice pad, by the way), because it happened to be a particularly hot day. I looked up the price of a new heatsink/fan assembly, and found it to be somewhat reasonable ($20-30 on ebay), and was getting ready to order a new one, and attempt to install it myself. I've never fully taken apart a notebook before, only minor disassembly for the purposes of removing dust or doing minor upgrades, like adding RAM.

Fortunately, it wasn't necessary to order the new fan, because I stumbled across a third-party Dell fan control utility, which allowed me to adjust the fan speed manually. I'm aware of SpeedFan, but it didn't seem to recognize the fan. The fan wouldn't run at any speed less than full anymore, so I had to use the utility to set the fan speed to max on startup, and just leave it at that. I guess the fan isn't dead, but maybe the internal fan controller is malfunctioning?

XP SP3

Microsoft has released Windows XP Service Pack 3 today. As a side effect of the increased security features though, some people have seen a couple of instances of trouble related to the increased security features. For example, downloading files over a LAN has been made more secure, which has caused at least a few people issues. Fortunately, there is a workaround for those who need this functionality.

Update: Scratch that...

In before title change

Hey there! I'm not really one for blogging in a huge way, but I comment on some blogs on a regular basis, so I figure I might as well make one, and then occasionally post stuff that piques my interest. I imagine most of it will be related to computers, networking, and programming, but I may go for other topics if I feel like it. I may change the title, cause I'm not sure I like it, but I hope something I post here is useful to someone else. If not, then at least I have a good archive for stuff that's interesting to me, like stupid C tricks.