Monday, December 19, 2011

TV is broken. Here's how we "fix" it.

I pay a content provider a subscription for a show. For instance, $0.75 for a season of House without ads, or $0.05 for a season of House with ads. $1.50 for a season of "The Daily Show" without ads. $0.50 for a season of the British show Red Dwarf, without ads. New show ideas can be funded with a kickstarter-like system. So, for example, you could donate $10.00 for a restart of Firefly without ads (Yes, I went there). If the fund reached the required amount, the project goes forward, and those who donated automatically get a season subscription for when the show airs. If it doesn't, the donators get their money back, no harm no foul. The greater the demand, the less the cost to the consumer (and, obviously, the greater the show run, or the more cost to create, the higher the subscription cost). "Reality" shows, where you call in to a premium-rate number to place your vote, could be entirely funded from this revenue stream alone, and would probably be "free" to subscribe to. This will put much more money in the hands of the content providers directly, rather than having the cable middlemen taking a large chunk, and will still keep all but the most obsessive tv-watcher's cable bill at about the same price as it already is. Watching 40-50 shows regularly (and that is a lot, TBH) would cost around $40, still less than the average cost of a home user's cable bill.

Content providers can poll me on my interests for new shows. They can also use those interests to customize the ads I get, if I am agreeing to get ads. This would make the ads both more attractive, relevant and interesting to consumers, and more appealing to advertisers.

The content provider releases episodes on their regular schedule via a private BitTorrent tracker (or similar methods) in a DRM-unencumbered format, so I can watch it on any device I choose. This releasing is done using a customized-to-the-user RSS feed (only the shows I subscribe to from that provider appear in that feed), which is secured using HTTPS and a unique "user key". Trailers and pilot episodes for new shows can also be published on the RSS feed (especially if they may match my recorded interests). Keys cannot be shared, and abuse of such will result in the key being revoked (or at least, changed, so the user has to update his client with the new key if he wishes to continue, which will make it difficult enough to make sharing of feeds like this unfeasable). Downloads could also be "Tagged", so that if a file is shared, it can be traced back to who shared it. Though, with prices like this, it's doubtful that would happen. Sharers could be penalised if they go too far (Like uploading an entire series, for example), but small-scale sharing between friends should be encouraged – it spreads the word about a show that might otherwise be overlooked, and can bring increased revenue for everyone involved. Don't punish your most fervent fans for encouraging others to enjoy what they are – they're doing your advertising for you!

News channels and sporting/current events can be subscribed to for live streaming using Multicast (preferably) or Unicast systems, in much the same way.

Cable companies can then become "content aggregators" or local CDNs, So rather than having to go to hundreds of different content providers, you can just subscribe through your cable company, and they aggregate all the available feeds for you and serve your content to you from local servers. Of course, going directly to the source is still an option, if you wish to track more directly, you don't want to support your local cable provider, or if your particular cable company doesn't carry that provider's content. Cable companies can then either add a small surcharge to the price of each subscription, or charge a "content distribution" fee for running the local cache.

Emergency broadcasts can be implemented with special RSS feed items, or signed and timestamped playlist files that point to a live stream, to be picked up and (dis)played immediately by boxes or computer systems. This is about the only part that isn't possible right now, and I shouldn't think it'd take that much work to implement.

This way, when you go to the TV, there's always something you're interested in watching available. You never miss an episode of your favourite shows, and you directly support the people who make it. You don't have to get, and don't have to watch, anything you don't want to, and you can do whatever you like with what you've paid for. It also means that niche shows don't get canned, and providers have a completely accurate dollar-based view of just how popular shows really are (rather than having to rely on a very limited number of Nielsen households), and it also means that shows aren't competing for ratings by being forced into a timeslot, giving a false impression of popularity (or lack thereof). It would also make it easier for indie TV producers to get up and running. You'd probably also have a fast addition to Google in the form of "Which provider makes this TV show".

If you're thinking this all sounds terribly complicated and difficult for (for example) your elderly grandparents to comprehend, it really needn't be. A set-top box with a friendly interface can hide all this "complexity".

So your mother turns on her TV, looks through the list of travel shows, or movies, or whatever, on her box, and chooses one to watch. The RSS and BitTorrent aspects are entirely transparent. She goes into the menu and chooses "Get more shows" and picks what she's interested in (by genre, alphabetically, by actor or director, search, whatever). If necessary, she puts in her Credit Card number (I know some elderly people prefer not to keep those details stored), and the box starts getting her new shows straight away, downloading in the background entirely unattended, ready and waiting for her to watch at her convenience.

It's not rocket science. And if she is really indecisive, she just hits the "pick something for me" button/option, which will select an (new, if she wants, or repeating if necessary) episode of a show and start playing, using the "next" button to skip shows she doesn't want to see right now (which is remembered for that playback session).

Just because it involves tech, doesn't mean it has to be technical, or difficult to use. A box with just 2 wires (Power, HDMI to TV) is dead easy to set up, and the prevalence of WiFi means it doesn't have to be any more complicated than that. Initial setup can be done with a nice, simple step-by-step wizard, which can also include initial selection of subscriptions. Trailers and ads for shows (if downloaded) can even have a "fast subscribe" option, so you just press the "Ok" button while a trailer's on and it'll add it to your list of downloads (Or present you with a "you asked for x while watching this, please confirm (and provide your credit card details)" screen after the show's finished).

So, rather than having to scroll through the programming guide on her cable box, she has a list of new, relevant TV always available for her to watch. She sits down, turns on the TV, and hits the "play something for me" button. The TV is at her command, rather than trying to fight it to find something interesting to watch.

Unfortunately, the way Hollywood, and the MPAA/RIAA/Media fatcats see the TV industry, and television consumers as a whole, this will never come to pass. They are so much more fond of their walled gardens and "Prime time slot"s that the idea of abandoning them and allowing people to live their lives not beholden to their scheduling whims is abhorrent. It would be so very nice, but I hold out little hope in it happening. And barring the emergency broadcast system, this is all completely possible to do RIGHT NOW. RSS aggregators, BitTorrent clients, streaming set-top-boxen and simple networking are all available now. This would be completely system agnostic, working equally well with AppleTV, GoogleTV, XBMC, Boxee, Plex, PopcornHour, WD TV Live and so much more.

That's what I think is "Wrong" with Television at the moment. And how you fix it. But, unfortunately, nobody that can do anything about it will listen to me, or is stuck in a non-compete, exclusive contract. This kind of scheme would effectively put the "TV Channels" out of business, or would force them to change their business model, and as they have all the money at the moment (Thanks to huge ad revenues), they really won't want anything to change. I'm sure the actual producers (Chuck Lorre Productions, Mutant Enemy, Stoopid Monkey, and morem for example) would like this system. They'd get rewarded for making popular shows, and wouldn't have the threat of cancellation hanging over their head constantly (I'm looking at you, Fox!). So I shake my fist in impotent rage, and continue to use eztv, FlexGet & Transmission instead.

Wednesday, November 16, 2011

E-Mail, DNS, IPv6, and much more...

Well, I've been having a conversation with Paul Murphy about how IPv6 is going to kill SMTP as we know it. I was arguing that it really wasn't. Yes, there is more complex work involved because you're dealing with a much larger IP base, but it's still not THAT hard to do. Here's some pseudo-code (emphasis on pseudo, it's all sketched out in Notepad, nothing more, and conforms to no known language thus far) that should give you the gist of my point.

// Connection Opens
If (dSeenHosts.Contains(sFullIPv6Address)) {
    If (dSeenHosts(sFullIPv6Address).IPBanned) {
        dSeenHosts(sFullIPv6Address.Connections++;
        Connection.Write(sConnectionBannedMessage);
        Connection.Close();
        return;
    } Else {
        dSeenHosts(sFullIPv6Address).Connections++;
    }
} Else {
    string sPartialHost = sFullIPv6Address.SubString(0,28);
    If (dSeenHosts.BeginsWith(sPartialHost).Matches.Count > 0) {
        // We've found at least one previous connection from within 4 nybbles
        // of the full address.
        //
        // We can make an assumption then that this is the same ISP as the
        // previous connection.
       
        If (dSeenHosts.BeginsWith(sPartialHost).Matches.Count > 1) {
            // There's more than one match to this partial host.
            // Hosting site? or perhaps spammer?
            float fBannedPercentage = 0;
            ForEach (var oHost in dSeenHosts.BeginsWith(sPartialHost).Matches) {
                If (oHost.IPBanned)
                    fBannedPercentage++;
            }
            fBannedPercentage = fBannedPercentage/(dSeenHosts.BeginsWith(sPartialHost).Count + 1));
            // Add an additional one to allow for this (unprocessed) host.
            If (fBannedPercentage > 0.7) {
                // More than 70% of hosts seen from this group have been banned.
                Connection.Write(sConnectionBannedMessage);
                Connection.Close();
                dSeenHosts(sFullIPv6Address).Connections = 1;
                dSeenHosts(sFullIPv6Address).IPBanned = True;
                dSeenHosts(sFullIPv6Address).BannedDate = Now();
                dSeenHosts(sFullIPv6Address).BannedTimes = 1;
            } Else {
                dSeenHosts(sFullIPv6Address).Connections = 1;
                dSeenHosts(sFullIPv6Address).BannedTimes = 0;
            }
        } Else {
            // There's only one previous connection from within this nybble.
            dSeenHosts(sFullIPv6Address).Connections = 1;
            dSeenHosts(sFullIPv6Address).BannedTimes = 0;
        }
    }
}

If (!Connection.IsOpen()) return;
Connection.SendBanner();
string sHostName = Connection.GetHELO();
bool bHostNameChanged = False;
If (dSeenHosts(sFullIPv6Address).HostName.Length > 0) {
    If (dSeenHosts(sFullIPv6Address).HostName != sHostName) {
        // That's not what you said last time.
        dSeenHosts(sFullIPv6Address).HostName = sHostName;
        dSeenHosts(sFullIPv6Address).HostVerificationFailed = False;
        bHostNameChanged = True;
    }
} Else {
    dSeenHosts(sFullIPv6Address).HostName = sHostName;
}
If (!VerifyHostNameMatchesIP(sHostName,sFullIPv6Address)) {
    // Function only returns false if it gets a result that doesn't match
    // No result is not false.
    // Not banning for this. You could, if you really wanted to be strict, but
    // The disconnection error should show up on a poorly configured server
    // And a spammer gets disconnected here.
    Connection.Write(sHostNameDoesntMatchIPError);
    Connection.Close();
}
If (!Connection.IsOpen()) return;
MailMessage mMail = Connection.ReceiveMail();
If (!SPFVerify(mMail)) {
    Connection.Write(sSPFFailedError);
    Connection.Close();
    dSeenHosts(sFullIPv6Address).IPBanned = True;
    dSeenHosts(sFullIPv6Address).BannedDate = Now();
    dSeenHosts(sFullIPv6Address).BannedTimes++;
}
If (!Connection.IsOpen()) return;
If (!DKIMVerify(mMail)) {
    Connection.Write(sDKIMFailedError);
    Connection.Close();
    dSeenHosts(sFullIPv6Address).IPBanned = True;
    dSeenHosts(sFullIPv6Address).BannedDate = Now();
    dSeenHosts(sFullIPv6Address).BannedTimes++;
}
If (!Connection.IsOpen()) return;
If (!VerifyRecepient(mMail)) {
    Connection.Write(sNobodyByThatNameHereError);
    Connection.Close();
}
If (!Connection.IsOpen()) return;
If (!RunSpamScore(mMail)) {
    If (dSeenHosts(sFullIPv6Address).SpamScore > iUserSpamScore) {
        Connection.Write(sSpamScoreExceededError);
        Connection.Close();
        dSeenHosts(sFullIPv6Address).TimesSpammed++;
        If (dSeenHosts(sFullIPv6Address).TimesSpammed > iUserSpamTimes) {
            dSeenHosts(sFullIPv6Address).IPBanned = True;
            dSeenHosts(sFullIPv6Address).BannedDate = Now();
            dSeenHosts(sFullIPv6Address).BannedTimes++;
        }
    } Else {
        If (dSeenHosts(sFullIPv6Address).TimesSpammed > 0) {
            dSeenHosts(sFullIPv6Address).TimesSpammed--;
        }
    }
}
If (!Connection.IsOpen()) return;
Server.Store(mMail);
Connection.Write(sMessageReceivedOK);
Connection.Close();

Monday, October 17, 2011

Saksatchewan, land ripe for entrepreneurship, but unfortunately backwards in technology...

A recent piece in the National Post has Saskatchewan and Alberta claiming Canada's top 9 for entrepreneurial cities, but unfortunately this pretty graph doesn't give the whole story, at least not for Saskatchewan.

Saskatchewan is, it's true, experiencing unprecedented growth, and is one of the only Canadian provinces that hasn't had an increase in unemployment. However, from a technological and ecological standpoint, Saskatchewan is really quite behind the times. There are a few indicators of this, so let's take them one-by-one.

SaskTel's monopoly makes external companies establishing a telephonic presence in Saskatchewan difficult.

What do I mean by that? Well, it seems that SaskTel is reluctant/refusing to give out Saskatchewan (306) area code numbers to anyone who doesn't have a firm Saskatchewan presence. This makes it very difficult to get any kind of VoIP service, barring the one "Open" VoIP provider operating within Saskatchewan itself and which SaskTel has a majority holding, and Access Communication's "Closed" VoIP service for access customers only. While they've not explicitly stated so, I believe this may be the stumbling block that has kept such innovative services as Google's "Google Voice" service out of Canada, despite the fact that Canada and the US share a phone system. If you look at any VoIP provider out there, it's impossible to get a large provider to give you a 306 number, because they just can't get them.

Business internet connectivity is woefully lacking.

With any other city (Edmonton, Winnipeg, Toronto, Vancouver, Montreal), there are multiple providers and multiple connection lines running throughout. It's a simple(r) matter to get a high-bandwidth high-speed line (or several) running into an office, and it's dead easy to find a whole slew of Co-Location providers for hosting all manner of services. In Saskatchewan, you have 2 options, SaskTel and Access, and neither is what you'd call "Big". All internet-related and co-lo services go out-of-province. Establishing a cloud-based service here is difficult, at best.

Home internet connectivity is poor, and the good stuff is held back by the equipment provided.

There are 2 choices of home internet provider. Access, who's service tops out at 5Mb/1Mb, and who incorporates a limit on their supposedly "Unlimited" high-speed internet. SaskTel has recently introduced it's (fantastic) 25Mb/2Mb VDSL package, which is totally unlimited in every way, but is held up by one major hiccup. The 2Wire gateways all share the same software, and that software has something of a fatal flaw – If there are more than 1,000 connections active, the gateway will start randomly dropping connections to get back under the 1,000 connection ceiling. Watching a movie on Netflix and someone decides to open WoW? There goes your streaming movie. Trying to have a conversation on Windows Live Messenger? Watch the connection bounce up and down. SaskTel do acknowledge this is a problem, and if you want to pay out of your own pocket, they can replace their ADSL gateways with a Westell modem providing basic connectivity only, and you bring your own router. The problem is that top tier package (The VDSL 25/2 one) won't work with the Westell modems. So it's 2Wire or nothing. Meanwhile in the US, with similar infrastructure, providers are offing 100MB packages for similar prices as we are paying for our 5Mb ones, and in Europe, Gigabit connections are coming in thick and fast, for incredibly reasonable rates.

SaskPower's short-sighted attitude to providing power services holds back green energy solutions.

Pretty much everywhere else in the world, power companies support green solutions. Time-of-use charging to even power loads and use excess capacity during off-peak hours, for instance, and buying back excess power from customers who have invested in green solutions like photo-voltaic cells and wind turbines. In fact, in the UK, you can "Rent your roof" to 3rd party companies, they will fit and maintain for 25 years (for free) the PV array and equipment, and take the buy-back profits from the power supplier, which you reap the benefit of considerably cheaper power bills.

Saskatchewan is perfect for wind generation – huge open flat prairie makes for long days and nights of strong, consistent winds. And on those rare days it isn't blowing to beat the band, it's hot and sunny all day long, with the "Living Skies" bathing the province in free sunlight. But without a buy-back option from the power provider, the investment in turbines and photo-voltaics is extremely heavy – you have to have enough to power your house & lands, and enough capacity to store during the leaner times, living entirely "off-grid", or you have to "throw away" the excess capacity you have during abundant times (Which SaskPower will gladly take off your hands for nothing) and eat the cost during lean times. With buy-back you make money during your abundant times, providing power back to the grid and your neighbours and offsetting the cost of the installation, and you're able to fall back on the grid when your system doesn't make quite enough.

As it stands, there are a few minor wind generating stations in Saskatchewan, though no solar stations that I am aware of. And this is a real shame. With all the open space, abundant sunlight and ever-present wind, Saskatchewan could become the power-generating capital of Canada, which would open huge employment opportunities across the province.

Agriculture has a firm hold on the economy and governmental attention, and almost nothing's going to change that.

Yes, farming and farming-related industries are big here. Huge, in fact. Indeed, I'd estimate that 55-70% of the jobs in Saskatchewan are in farming, the next 10-15% of the jobs are in service industries related to farming, 5-10% are mining and oil, and the rest are retail. There is no real technological center for Saskatchewan, and it seems that the Saskatchewan government isn't interested in any way in fostering any kind of high-tech infrastructure. Instead, they seem keen on squeezing every last dollar out of the farming industry, and draining the province dry of it's planet-killing hydrocarbons. While agriculture is a steady economic engine, and oil is a good short-term high profit business, neither really advances the province in any way, and neither is particularly attractive for outside investment or the growth of the province as a whole. As a child in Saskatchewan it seems there are only four realistic career options: Farming, Construction, Retail or Nursing. If you have the right blend of ethnicity and/or (dis)ability you may be able to meet quotas for RCMP recruitment. But any modern jobs are simply out of reach, or not worth pursuing as there's virtually no market for them.

In conclusion.

Wow, did this ever turn out to be WAY longer than I thought it would. Anyway, in conclusion, from a purely numerical standpoint, Saskatchewan looks like a great place to set up a new business. But when you look at the details, it becomes apparent that Saskatchewan is being held back, dragging it's feet on entering the modern era, and thus is destined to be left way behind. Modern businesses are in short supply, and very low demand, and what would be common services and industries anywhere else are demoted to niche markets. With a governmental and economic tendency towards stagnation and social conservatism, Saskatchewan is in serious danger of becoming even more of "the big empty space between Edmonton and Montreal". Perhaps it was a sign when the passenger trains stopped coming here all those years ago. I'm reminded of the Simpsons movie, when Springfield gets covered in a dome to protect the rest of the US from it's hideous environmental record – "[GPS announcer] Coming up on your right... Nothing...".

I'm not sure if Darren's going to read this (It's him to whom this will be tweeted first, as it was he that let me know about the above-mentioned chart), but I'll put it out there anyway. Do feel free to comment and correct anything in here that's wrong. It's written from my personal experience living here in Regina for the past 7 years after moving over from England, so it may not be entirely accurate, it is merely the impression I have received, and something that needs to be changed post-haste.

Saturday, April 9, 2011

Culinary quirks

It seems that every country has it's selection of culinary quirks. From the PB&J to Lutefisk, these dishes are often things that would make you scratch your head and ask "Whoever would have thought of doing THAT? What were they thinking?". But for all their strangeness, some (not all, I'll admit, but some) creations come under the "Now that's actually not half bad" part of the spectrum. So let's take a look at a few of these, shall we?

Starting off with the American classic, the PB&J. That's "Peanut Butter and Jelly (sandwich)", though that's the (Am.E) version of Jelly (A preserve not dissimilar to Jam, made entirely of juice, without pips, seeds or pulp of any kind, though oddly enough in this particular "dish", using Jam is just as appropriate). The mixture of dense protien, dry starch and sweet fruit (often also with a crunch, depending on the type of peanut butter used) makes this a dish of wildly clashing contrasts, which shouldn't work at all. And yet, it does, with the sweetness of the jam mellowing the gluing action of the peanut butter. And this can be extended. My wife is quite the fan of peanut butter and honey sandwiches, which is a little too much to my British palate.

And speaking of British palates, here's something entirely from my homeworld, which often has people looking at me askance: The Crisp and Salad Cream Sandwich.

Let me translate. Br.E Crisps are Am.E Potato Chips. In this particular regard, they should be "Ready Salted" flavour. Fortunately, Walkers crisps do exist in the US and Canada, though they use the brand name "Lays", and in this case "Lays Classic" chips are a perfect substitute. As for "Salad Cream", I found it here in Canada in Safeway, labelled as "Heinz Salad Cream English Dressing", with the interesting french version underneath being (translated back into English) "English Salad Cream Vinaigrette". So you take two slices of plain bread, add butter or margarine to taste, then layer on the Br.E Crisps/Am.E Chips. You need at least 3 layers, as they compress as you squash/hold the sandwich (in fact, some pre-compression may be required before assembly), and even coverage with large and unwieldy slices of potato is very difficult to manage with a single layer (Not impossible, I'm sure someone could engineer broken pieces of crisp/chip to fill the holes, but the flavour is a little too subtle with just a single layer). Then drizzle with the salad cream. This is easier said than done, of course, as a full bottle will produce a massive rush once you have gotten it going. Indeed, when the bottle is new, a much safer technique would be to insert a knife into the bottle and spread the salad cream in a thin layer on the un-coated piece of bread. Once you have creamed your sandwich, you assemble, pressing down with a flat hand on top to break down the crisps/chips into small chunks. Then you eat.

Crunchy, salty, smooth and tangy flavours and textures flood the mouth, and you know you have reached the pinnacle of sandwich nirvana. The crunching sounds continue unabated as you eat mouthful after mouthful of ingredients that were never in a million years meant to be used together, and you find it is good.

Switching gears a little, though still talking about things on bread, let's move our attention to Bitumen. Or to give it it's brand name: "Marmite".

Technically speaking, Marmite is a yeast extract, a residue of the brewing process, and many foods out there have marmite in them, albeit in it's more raw state. It's also one of the most divisive of foodstuffs out there – whole advertising campaigns have been based around the simple fact that you either love it, or hate it. So what do you do with this substance that looks not unlike road tar? Well, you spread it on bread, of course. But there is a VERY important point to make here – If you cannot see the texture of the bread through the layer of marmite, you have spread it TOO THICK! For beginners, especially, you will want to try and scrape the marmite off the bread again. the thin layer of residue that is left is more than enough for your first try. This is intense stuff, packed with flavour, and a major source of Umami, the taste that is strongly associated with meatiness. The other main source of Umami is, of course, Mono-Sodium Glutamate, or MSG.

So, what does it taste like? That's incredibly difficult to describe. Salty is certainly a contender. If you have ever had (Br.E) Beef Stock/(Am.E) Beef Broth or Consommé, imagine that, but concentrated at least a thousand times. That's what happens in your mouth, and you either love it, or hate it. Other notables in this family of substances are Bovril (Beef Extract, and not the brand of concentrated cooking stock in the US supermarkets) and Vegemite.

What else? How about "Chips on a Baguette"? Again, we're firmly in Br.E territory here, so let's expand. (Br.E) "Chips" would be (Am.E) French Fries, though "Steak Cut" fries are closer to a proper British Chip than the shoestring things the Americans typically call "Fries". And a Baguette would be a (Am.E) French Loaf or (Am.E/Br.E) French Stick, or perhaps a (Very Am.E) Submarine bun (Though those, again, aren't quite right. If you've ever seen a woman carrying shopping in a Hollywood film, she'll have a long thin loaf of bread sticking out the top of her paper bag of groceries – That's a Baguette). So, you slice your Baguette (Not all the way through, enough to make a hinge), you butter the inside (optionally), you fill the newly-made cavity with (Br.E) Chips/ (Am.E) Steak-Cut fries, and you sprinkle grated cheese over the top. Then you eat it quick as the cheese melts and your mouth exclaims in joy.

And they say we Brits have a bland palate!