Thursday, February 26, 2009

Safety at the Santa Clara CalTrain station

Since I got hit by CalTrain, it appears that just possibly CalTrain has stopped routinely running trains on the wrong track past the Santa Clara station. I haven't seen a Southbound train pass on the far track in quite some time now. It used to be that the trains had a 50:50 chance of being on opposite tracks at the 8:00 AM hour. That's a good thing. It will improve safety at Santa Clara, but not as much as it needs.

Things should still be improved. I believe Santa Clara may still be one of the least safe stations left on the CalTrain line. Most stations either have two outside platforms with grade separated ingress/egress (that is, a tunnel or a pedestrian overcrossing), a single shared platform between the tracks with grade-separated ingress/egress, or two outside platforms with crossing gates protecting the tracks.

In the latter case, the crossing gates serve an extra purpose which they perhaps were not designed to do, but do anyway: they warn people in the station about an approaching train.

This morning, I got to Santa Clara a little bit later than usual, and presumed that I missed the Southbound express that normally roars through at about 8:20. That train was a little bit late. I was standing on the platform (a safe distance from the tracks, of course), when I heard a train whistle from the North and turned around to see the Southbound express only a couple seconds away from the station flying at 79 mi/hr. Part of the reason this is such a surprise is that just North of the station, the tracks curve to the left a bit, which means that people in the station can't watch for trains approaching, like they can from the South. And, of course, the Southbound trains approach the tracks closest to the platform.

This, in my view, is a dangerous setup.

Now, this isn't really an issue in and of itself. You could argue that people should presume that a train can fly past at any moment, and should give the tracks the respect they deserve. But just saying that isn't going to make people do the right thing.

The damning thing is that this would be really, really easy to fix. All that needs to happen is pouring a concrete slab to act as a Northbound platform on the far side of that track, putting a fence down the middle between the two tracks, and add a pair of crossing gates at either end. I'd expect to pay, what? $10,000 to have that work done? Even if you triple that (because the government is involved), that's $30K. The crossing gates will keep people off the tracks when trains are approaching, but more importantly, they'll warn people on the platform that a train is approaching, particularly from the North since otherwise there is no warning at all. Governments piss away bigger sums of money daily on dumber stuff than that.

Sometime in the next 20 years, BART is going to put a station in and the whole place will get gentrified. But the BART station is hardly going to invalidate the idea of fixing the safety issues now. It's not as if they're going to move the CalTrain station anywhere else.

UPDATE: Thanks to Dan in the comments, and google, I've discovered this announcement of CalTrain's plans for improving the Santa Clara station. Interestingly, the plans include a tunnel rather than gated crossings, and (combining Dan's comment) it would appear that the new outside platform is actually going to serve both the current Northbound CalTrain track, but also the next track East of that, which will make it easier (I won't say possible since there are switches that would route trains from the Northbound CalTrain track to the next track to the East, which branches off in the Fremont-bound direction) to allow Capital Corridor and ACE trains to once again stop at Santa Clara.

Wednesday, February 25, 2009

Safari 4 beta breaks Back-To-My-Mac

The Safari 4 beta is very, very nice, except for one thing: if you install it on a machine that you intend to use remotely via Back-to-my-mac, it won't work. While the beta is installed, the BTTM service tab in the preferences will have a yellow dot and caution triangle that simply says that there is a problem with your connection to MobileMe.

UPDATE: It looks like they fixed this sometime yesterday without a software update. It's possible that this was unrelated to the Safari 4 beta, but I did test it simultaneously with two machines - one with, one without - before announcing it.

Monday, February 23, 2009

Robin Hood didn't play poker

Today's lesson: don't be a Robin Hood - steal from the poor.

So, you're playing a Full Tilt Super-Turbo. Just to remind everyone, those are just 9-handed Turbo structure SnG tournaments, but with a 300 chip starting stack. That's right, 2700 chips on the table total. And the blinds start at 15/30 and go up every 3 minutes.

So anyway, you've been treading water for a couple orbits, and have 280 chips and the button in front of you. The blinds are 25/50. You look down at KTo, and it's folded around to you. What do you do?

Well, if I'm in your shoes, I don't know what to do yet, because I've left out from the setup the size of the stacks that are in the blinds.

You're certainly not going to limp. The problem with that is that limping is going to cost you almost 20% of your stack, and if you then get raised by one of the blinds, you'll have a quandary. No, this situation is all-in or fold.

Two factors matter:

1. How committed are your opponents? If one or both of them have more than a quarter of their stack out there, they're probably calling with all but the very worst hands. If they have half or more committed in the blind, they're calling with 27o. Yes, you're ahead of 27o, but, as they say, they have 2 live cards.

2. How much damage can they do to you if the call and win? If one or more of the blinds has you out-chipped, then they can end you immediately. If one or both of them has more than 50% of your stack, then not only are they capable of landing a crippling blow on your stack, with 150 or so chips, they are more likely to feel committed to the pot (particularly the BB, who has a third of his stack in).

There is a third factor - how committed are you to this pot? There are never any antes in Super Turbos, so the answer is quite simply that you're not at all committed to any pot unless you're one of the blinds. But at the same time, if you're short stacked, you're looking for a good situation to try and double up to keep going. If, with the above setup, you had, say, only 150 chips, you'd probably think that KTo with only two opponents left was probably a good enough place to take a stand. Waiting for a better hand will only put you further out of position, reducing your hand range and your likelihood of having an acceptable hand come your way before you're in the big blind (and will likely be committed).

Another thing to note is that button raises are going to be viewed by the blinds with some suspicion. The good news is that you've got a better than average hand, meaning that if they put you on a pure garbage steal, they'll have a nasty surprise. You're certain to get called by any ace in this spot, and by any pair. The good news is that those situations are likely to be fairly close to coin-flips for you (A4o vs KTo is 56/42, 44 vs KTo is 51/47). The bad news is that statistically, you're going to lose half of those.

And that's where the lesson comes in. Short stacks will call with crappier hands, which improves your odds, and even when the odds don't fall your way, they can't hurt you as much. So take their lunch money and give them a wedige every chance you get.

Sunday, February 22, 2009

The White Stripes tank on Conan's last show

I just watched the last episode of Late Night with Conan O'Brien. I'm really looking forward to Conan taking over the Tonight Show, but that won't happen for a few weeks. So Friday night's show is the last we'll see of Conan for a while. It also puts the cap on 16 years and more than 2000 shows (Conan jokes that 41 of them were actually good).

Musical guests on the show were The White Stripes, which really means Jack White (he was born Jack Gillis and, unusually, took Meg's last name when they wed) and his former wife Meg.

Now, Jack is a fairly talented writer and musician. His most recent claim to fame is as part of the duet that performed the most recent James Bond movie theme.

So why the hell did they phone it in the other night? They've had some really great hits over the years, and that's the song they chose to play? Does anyone even know what piece of shit song was? Even if you were more familiar with their catalog than I am, I'm not sure you'd recognize it anyway given how off-key the singing and off-tempo the playing was.

Wednesday, February 18, 2009

And thus, it begins

Probably only those of us who are RF hobbyists noticed, but KCNS-TV channel 38 is now off the air, and KOFY-TV and KICU-TV are, for now, running "nightlight" service (no programming, just messages about the analog shut-down). Unfortunately, according to reports I've heard, the KICU translator in Monterey is retransmitting the nightlight message rather than KICU's digital programming. Oops. Hopefully, whoever runs the translator will buy a CECB for the thing. :)

So those three stations join KCSM (sort of. KCSM still does have an analog station on channel 60, it's just that its coverage area is the size of a postage stamp) in the all-digital age.

None of this helps me any. TV still has some suckage:

1. Even if all the analog stations were to shut down immediately, the rules are that they have to stay on their pre-transition channels, meaning that KRON and KTVU are stuck at 56 & 57 until June.

2. Because of the rule above and because KDTV-TV is still on the air, KTNC-DT is still off the air. They shut down channel 62 operations early to start the work to convert their transmitter to channel 14, and then the transition got put off.

3. KSBW-DT can't transition to channel 8. Not that that matters all that much, except that since they're on channel 10, they're getting shit on by KXTV. As is KCBA-DT by KOVR-TV.

Thanks, Obama.


Monday, February 16, 2009

iLife '09: Garage band artist music lessons are awesome

Scarlet expressed an interest last year in learning to read sheet music again. To that end, we asked for an M-Audio KeyRig 49 for Christmas.

Since I was a teenager, I've had a sort of background interest in music. I used to sing in choirs, and have been in operas and operettas on and off. I can read music well enough to plunk out vocal parts on the piano and can hack out chords and the like, so I thought I'd be able to teach Scarlet a little bit about how to play the piano as a way to help her read music better.

I still have my old synthesizer keyboard from 1984. It doesn't have velocity support, but it can act as a MIDI source, and I have a MIDI to USB adapter that has been demonstrated to work correctly with GarageBand in the past, but the newer USB music keyboards are lighter and more portable, so they make a lot more sense for our office space. Besides, GarageBand running on a mac is far and away a better synthesizer than that old Seiko keyboard could have ever hoped to be.

So that was the plan, and that's fine. But when the MacWorld keynote in January demonstrated the Learn To Play features of iLife '09, I was intrigued. Well, we finally got our hands on a copy of iLife '09, and I was so impressed with the free lessons (they really got Scarlet started on the right foot), that I bought an artist lesson for myself: Sara Bareilles' Love Song.

It's not really my genre of choice - I'm more of an alternative rock fan than a pop fan - but in the limited selection available, it was the lowest difficulty piano choice available.

Sara is an excellent teacher, and the song is certainly both playable, interesting, and reasonably approachable. I don't play it exactly the way the sheet music says I should. I play the chords and I simplify the rhythm a little bit to suit me (I'm not sure she would really approve, but I don't have enough left-hand / right-hand disconnect to do it her way).

There are a few improvements I would make, and they're minor:

1. While you can choose to replace the sheet music with the chords, it would be really nice to display the chord names above the staff the way you often see in real print music. I'd be able to see the chords more easily, while still pulling rhythmical cues and the vocal lead off the page. As it is now, the only prayer I have of keeping up with the full speed track is just with the chord track and winging it.

2. They really, really need to not let the time pointer get so far to the right before they scroll the music. I need to read ahead a little bit, and I pretty often get to the end of the screen and wind up getting surprised by what comes next when the next measure finally scrolls in.

3. The selection in the artist store is obviously too limited to be realistic. Not only is it obvious that this will change as more artists get on board, I'd be stunned if artists don't start tripping over themselves to get into the store.

But apart from those minor complaints, I have to say, the whole concept is really a blast. It's the best $5 I've spent on computer software of any kind in at least a year.

Friday, February 13, 2009

Fantastic pork/chicken recipe

ATK gets credit for this. They had an episode on this week with a recipe for crunchy baked pork chops. I adapted the recipe for skinless, boneless chicken breasts (which are, more or less, equivalent to boneless pork chops). You take 4 pieces of bread (I used sourdough) and run them through a food processor to make crumbs. Toss them with a couple tablespoons of oil and spread them on a cookie sheet and toast them for 15 minutes or so at 375.

Meanwhile, take two egg whites and add a teaspoon of mustard, or so, and a couple tablespoons of flour. Whisk all that together. Set out another few tablespoons of flour in a dish.

When the crumbs are done toasting, add a couple tablespoons of some sort of spice rub (we used curry-cumin, but lemon pepper or poultry seasoning would also work) and a couple tablespoons of grated parmigiana (let the crumbs cool a bit before doing this so the cheese doesn't melt) and a couple tablespoons of parsley. Mix it all up and put it in a flat bowl.

Pat the chicken dry, dredge it in the flour, then the egg wash/batter mix, then coat it with crumbs. You really want to pack the crumbs on to make a substantial coating.

Bake for 20 minutes at 425, or until internal temperature is 160 (for chicken. For pork, 150).

Wednesday, February 11, 2009

VoIP traffic shaping with FreeBSD IPFW + Dummynet

We have an Airport Extreme, and while it is a good router, it isn't perfect. Among the deficiencies in it, it lacks support for traffic shaping (sometimes called QoS).

Using the FreeBSD machine as the firewall instead of the AirPort is one option, but the problem with that is that FreeBSD lacks support for uPNP or NAT-PMP, which would seriously complicate things like Back-to-my-Mac.

The best compromise is to keep the AirPort Extreme in the routing role for the inside machines, and use the FreeBSD machine as a traffic shaping bridge.

It's fairly simple:

ipfw pipe 1 config bw 640kbps
ipfw queue 1 pipe 1 weight 100
ipfw queue 2 pipe 1 weight 1

queue 1 is for Vonage traffic, and queue 2 is for everything else.

ipfw queue 1 ip from voip to any xmit re0
ipfw queue 2 ip from not voip to any xmit re0

in this case, re0 is the "outside" LAN interface (connected to DSL).

The issue is in figuring out what the number for the bandwidth is. It's not actually the same as the DSL connection's uplink line rate. The problem is that there are several layers of encapsulation. The best way to figure out what to put in there is to start with a number far higher than the uplink bandwidth and run a speed test. Reduce the number until the speed test shows a reduction in the uplink bandwidth. In our case, the line is a 6M/768K one and the right number to use is 640kbps. The speed tests show an actual data throughput of closer to 600 kbps. The Ethernet and ATM framing for the packets takes up the rest of the bandwidth.

Tuesday, February 10, 2009

Monday, February 9, 2009

An amusing recipe

My wife Scarlet sent me this link. We haven't tried it yet, but just the post amused me greatly. It reminds me of those crappy pyrotechnic "snakes" that we used to get to celebrate Federal Occupation Day when we were kids.

Sunday, February 1, 2009

Need a cordless phone jack - any help?

Here's the situation:

We have one cat 5 line running to the living room. I used to run 100baseT Ethernet over it plus a phone line. I really want to stop doing that - instead to run all 4 pairs as Ethernet so I can do gigabit. The problem is that I need a phone jack in that location as well for the DirecTV receivers.

My first attempt at a solution was the RCA RC940 wireless phone jack. It runs a signal through the building's power lines. It is almost completely worthless. I could get a dial-tone without difficulty, but the line is so noisy that the self-test inside the receiver fails every time. I tried about 19 different configurations and the only way it wasn't so noisy you wouldn't even want to make a regular phone call with it is if the base and extension units are plugged into the same socket, which is obviously not very helpful.

We have a 5 GHz cordless phone system, but of course it doesn't have a remote jack, so that's no help. Google gives me nothing but the powerline variants when I search for 'cordless phone jack,' which is not helpful.

Attempting to search for phone / POTS over ethernet gives me either VoIP stuff, which is way, way over engineered for what I want, or gives me Ethernet over Phone line wiring, which is, of course, the exact opposite of what I need.

Are there any wireless phone jacks that do not use the power lines for transporting the signal?

Why, yes! There is the RTX DualJack... except that you can't buy one anywhere. Best of all is WalMart. "Not sold online" and "not sold in stores." Why fucking bother listing then, retards?

It seems like it would be something that would be both easy to do and useful. Surely there are lots of situations in this world where ethernet is already run and you have an analog phone device you need to use. Doesn't anyone make a dumbed-down raw Ethernet POTS line bridge system? There's no need in this circumstance to even use IP networking.

The other irony here is that virtually every google result where I see this question asked, the first response is, "I don't understand what it is you want to do."

So I'll say it again: I have a fully functional gigabit Ethernet network. I have a POTS phone line in one place. I have a need to plug in a POTS device (a DirecTV receiver) in another place. I attempted to use powerline phone extenders and it was an unmitigated disaster. Is there no way that a pair of boxes could use Ethernet to transport the POTS line?