Monday, September 28, 2009

"Curing" cancer

I ran across a YouTube video of Lewis Black calling for more research into curing cancer.

Let's look into this a little bit.

Everybody's going to die of something someday.

According to this page Google found me, vascular disease (combining the cerebrovascular and coronary categories) accounted for almost 31% of deaths in 2006 in the US. Cancer caused 23%.

But when you talk to people about what they really mean by "finding a cure for cancer," what they really are talking about are the cancers that cut young lives short unexpectedly.

According to this page, cancer deaths in those under 54 years of age accounted for less than 15% of the total deaths due to cancer. Between 55 and 64, a further 17.5%. More than 2/3rds of cancer deaths are people over the age of 65.

The number of people who die of cancer every year under age 65 is about the same as the number of people who die every year from accidents - and accidents, unlike cancer, are a cause of death that is heavily biased towards the youth and away from the elderly. Should we not spend at least as much time, effort, energy and money stumping for accident prevention if we want to reduce the rate of untimely death?

Besides, we do have cures for cancer right now - early detection, genetic screening, surgery, chemotherapy, radiation therapy - all of these things have given people diagnosed with cancer far, far more hope than they ever have had in the past. And to be sure, incremental gains can be made going forward. And that's not to mention the reduced risk of cancer afforded to those who make healthy lifestyle choices in the first place.

But it's not like deciding we're going to spend X amount of dollars and launch a mission to the moon - and once we land, it's "mission accomplished." It's not like there's something that the scientists have just plain missed that's going to make cancer stop killing people. But that's the case for cardiovascular disease, and dementia, and everything else that kills us too.

Sunday, September 27, 2009

Open colector output

Perhaps it's obvious to most electronics experts reading this, but I thought I'd pass along something I learned today.

As you all know, I'm trying to build a digital ATV repeater. One of the things I needed was a system to key the amp on and off so that it doesn't have to stay biased 24/7 (a waste of power, unnecessary heat and shortens the amp's service life). Fortunately, the amp has a short-to-ground PTT line.

Well, it turns out that the modulator has a TTL "PTT" pin on one of its headers. How do you turn this into a short-to-ground output?

The answer is open collector. I installed an RCA jack in the chassis and simply dead-bug soldered an NPN transistor to the jack, emitter to shell (and ground) and collector to center. I then soldered a 10K resistor to the base, and the other end to a wire to a "pin clip" to clip on to the PTT pin.

And it works perfectly! When I use the menu item to take the transmitter from stand-by to on-air, it keys the amp! Yay!

Football blackout rules?

I guess I don't understand the NFL's blackout rules. CBS has the doubleheader this week, and we will get 3 games here in the bay area - meaning CBS will put on a competing game against the 9ers @ Vikings.

Well, I thought that KPIX wasn't allowed to compete with the home team's away games. Is that not the case?

Meanwhile, I can't wait for Fox to get the doubleheader. Perhaps then I'll get to test out the KCBA extra game theory.

Update: Well, the schedule on the TV was wrong. We didn't get the 2nd game. Instead, we got an infomercial. :(

Next week will be the first big test. Fox has the doubleheader and the morning game on KPIX will be Radiers & Texans. If I am right, that means that there will be no competing game on KTVU, but there will be one on KCBA.

Thursday, September 24, 2009

Gearing up

Next month, I'm going to order a DVB-S modulator (for me) and a DVB-S receiver for the repeater.

Stefan (from SR Systems) says that you can set up a repeater simply by connecting the receiver directly up to the modulator. The modulator will turn on automatically when the receiver detects good reception. Not only that, but it has a "PTT" logic indicator pin that can turn into an open collector output with one transistor and one resistor to key the amp!

After that's done, the MPEG encoder board will be paired with the new DVB-S transmitter board as my user station.

The bad news is that they don't make a DVB-S receiver for 70 cm. Too bad. We'll have to receive on 1.2 GHz. But, of course, we'll be able to do so in a 2 MHz wide channel so we should not have the same interference problems we do with FM TV on K6BEN/R.

All I need besides that is a 15A power supply for the whole thing, a 23 cm antenna, some coax.... and a place to put it all.

For the receive antenna, I'm looking at the Diamond F1230A. It has 13.8 dBi gain. With about 3 dB of coax loss and 9 dB of loss for operating on 1.2 GHz, you should be able to use the PC Electronics ATV DX chart as it is - without having to correct for being on 1.2 GHz. Just assume that the receive site has unity gain. So, for example, if you can generate 5 watts into a Directive Systems 14 element loop Yagi, you'd be able to hit the system from about 15 miles away.

Tuesday, September 22, 2009

Digital amateur TV for the rest of us

I've been concentrating on the ATSC repeater output all this time and have neglected considering the user uplink side of the equation. In a single e-mail with the SR Systems folks, I think I see the way forward.

NARCC, the local repeater coordination body here in Northern California, has not been friendly to ATV in the 70 cm band. And you can't really blame them - it's 6 MHz of real estate that is sorely needed for other things. The big problem is that generating power at 70 cm is vastly less expensive and easier than for the higher bands. Given that state of affairs, it would be very, very nice to be able to use 70 cm as a user uplink band for a DATV repeater.

Well, it turns out that according to Stefan, the europeans have had great success with DVB-S in a 2 MHz wide bandwidth at about 2 mbps encoding! That's excellent news! I'd be shocked if we couldn't find a 2 MHz channel somewhere between 420 and 440 MHz for this.

Not only that, but the DVB-S encoder board is less than half the price of an ATSC one. That means that a user station can be had for €590. Add to that the cost of a Downeast Microwave 7025PACK and you're on the air with about 8 watts of transmitter power for just over $1000! That's not bad for digital ATV!

Friday, September 4, 2009

CalTrain: cellphone boosters, please!

I have trouble with the iPhone under two circumstances: At home and on CalTrain. Our house is made of stucco, which is a giant faraday cage. The workaround has been to install a cell booster. CalTrain is a giant metal box going 79 mi/hr - a worst case scenario for any cell phone on any carrier.

Now, I know that CalTrain just announced service reductions and parking fee increases, so maybe it's not totally apropos to talk about improving things, at least not "in this economy" (how many times in one day do you hear that phrase?). But still... They could add a two band repeater to the luggage cars as a test.

According to Wikipedia, CalTrain was considering adding WiFi service back in 2006. The problem with WiFi is that it doesn't help anyone make phone calls, and it's more expensive, since it means that CalTrain has to obtain mobile Internet access itself somehow.

A cellular repeater in a train car isn't the same thing as microcells in airplanes. There, the signal is back-hauled over satellite links since cellular phones are actually not licensed for use in the air (their widespread visibility to multiple cell sites causes interference).

Thursday, September 3, 2009

Java and the Impossible Generic List

Since Java 1.5, I've been used to writing List<Class>, allowing the compiler to insure type safety of collections.

There's one issue with this, however.

let's say you have an interface. We'll call it TheInterface.

Java is more than content with allowing you to say List<TheInterface>

So what?

The problem with that syntax is that it says that the contents of the List will always be items whose exact type is TheInterface.

But it's an interface. So there will never be any of those.

Stupid Java.

The solution is simple: you're supposed to say List<? extends TheInterface>. This lets the list contain any objects that implement the given interface, which is almost assuredly exactly what you want.

So why isn't List<TheInterface> a compile error?

Bueller?

Wednesday, September 2, 2009

I hate it when this happens

I hate it when you have something fairly simple to do, that can be done a hundred different ways, but every goddamn one fails for some simple reason. Case in point: I have set up my laptop to act as an alarm clock. It opens up the XM Radio online streaming from a cron job.

I have an html file that does the right thing. It has some javascript that performs the "login" step, and then opens the player gizmo inside of an iframe. It works perfectly.

Well, it did. Snow Leopard seems to have broken XM streaming in Safari.

Ok. How about Firefox? XM streaming works fine there, and if I open up a firefox window and type in the file: URL, it works.

But the problem is that Firefox isn't scriptable! There appears to be no way at all, from a shell script, to open up a firefox window onto a URL of your choosing.

What about Camino? It's scriptable, and uses Gecko.... But alas, XM streaming doesn't work there, either - but for a different reason than Safari (looks to me like a cookie issue, but I can't be sure).

So I'm fucked. And by my count, it took the failure of 5 different vendors to get us here. Outstanding.

The return of Channel 1

Some people wonder what happened to TV channel 1 here in North America.

Well, TV broadcasting actually began before World War II, but with the outbreak of war, it was suspended. In 1945, when the war was over, the bands for both TV and FM were realigned (much to the detriment of Edwin Armstrong's fledgling FM radio network - all of the FM receivers sold before that time were instantly obsolete). Channel 1 was from 44-50 MHz, and channel's 2 through 6 were as they are now.

That had the rather uncomfortable distinction of sandwiching the amateur 6 meter band right between two TV broadcast channels. Fortunately for us hams, channel 1 was reallocated to land mobile services. Since by that time people had already bought a nontrivial number of TVs, the channel numbers were not changed, and so to this day, channel 2 is the bottom of the TV band at 54-60 MHz.

Spring forward to today. KAXT switched on their ATSC transmitter a few weeks ago, putting out 12 streams of video and 3 of audio on virtual channel 22 (RF channel 42). This collided with KRCB, which was also using virtual channel 22 (via RF channel 23). Back in the days of analog broadcasting, the two used to collide with each other, since they were both on channel 22. The net result was to deny those of us here in the South Bay any chance at all of receiving KRCB, even though with a good enough antenna we had a good shot at it.

Well, the long and short of it is that virtual channel number "collisions" between broadcasters are undesirable. Some receivers get very confused when there are multiple 22-1 streams. Some prefer the most recently tuned one, some allow two to exist... It's very messy.

Well, KAXT has asked the FCC to change their virtual channel number to 1. The FCC more or less said, "well, if that'll fix it, sure." The PSIP TVCT spec does allow for a channel 1. It'll be interesting to see how many tuners balk at it, though.

It'll be interesting to see what KTVJ decides to do. In theory they have three choices of virtual channel - 4, 20 and 36 - all of which are already in use.

My suggestion? They should pick 37. It's one up from 36, which is their current branding identity (which they can't use since it's taken by KICU), and TV channel 37 has traditionally been unallocated because it is actually a radio astronomy quiet channel (there's some interesting physics that manifests itself at or near 49 cm).