Yahoo Screen on FireTV

Its pretty rough, but if you’re craving some Community, it is possible to install Yahoo! Screen on your FireTV. This quick run through is for reference, and assumes you’ve got standard Android Developer SDK on your PC or Mac, and have enabled the Developer capabilities on your FireTV.
You’ll also need the Google Play Services (but not the store) which you’ll sideload, to get rid of some (but not all) annoying dialogs while using Screen. This YouTube video, which shows a similar process for Fire Phone (but over-complicates it significantly!) has a link to the necessary Google APKs.
Finally, you’ll need to get the Yahoo! Screen APK off the Google Play store on another device, then extract it for sideloading. There are lots of tutorials for this, so I won’t repeat them.
Once you’ve got all the necessary bits, here are the adb commands (the order is important):

adb connect <IPAddressOfFireTV>
adb install <GoogleAccountManager>.apk
adb install <GooglePlayServices>.apk
adb install <GoogleServicesFramework>.apk
adb install <YahooScreen>.apk

On your FireTV, go to Settings > Applications > Manage Installed Applications.
Scroll until you find Screen, and launch it (it won’t show up in the normal FireTV App launcher — use Llama to fix that.)
Now that its launched, you have an input method problem. Yahoo Screen (as of this writing) was not made for TVs (or, apparently for Accessibility) so you have to connect a USB mouse to your FireTV (yes, it works just fine!) Alternatively, you can use adb to fake screen taps from the command line on your computer.
The mouse is easiest, but if you prefer the command line approach, this website has some good input instructions, but a quick example:
adb shell input touchscreen tap "200" "200"
This will tap the top left tile in the Yahoo Screen grid and start the video. Change the second number to “400” to get the next tile down, change the first number to “800” to get the next tile over, etc…
When you start a video, tou’ll get a warning about Google Play services not being supported, but you can use your FireTV remote to hit OK and the video will start. The back button on your FireTV remote will work, as will Home, but the video control buttons will not.
Hopefully Yahoo will update their app for other form factors and control mechanisms soon — when they do update the app, of course, you’ll have to re-install it.

All the best, Steve

When I was 15, I wrote my first really useful program. I’d written lots of cute little distractions, and followed tutorials to write code that made computers do neat things — my first when I was 11, I think. But during a 10th grade Computer Science class, when the assignment was to write a program that drew 4 different shapes on the screen, I decided to instead write a MacPaint clone. Using Turing. And not even Turing OOP, just crude old procedural code.
Of course I was no Bill Atkinson (nowhere close!) and my teacher, permanently frustrated with my lack of focus, actually failed me on the assignment. But it was pretty functional, and I was proud of it. So I e-mailed it to a guy I knew of, working at this computer company called NeXT, and told him I was going to come work for him some day: stevejobs@next.com
This was years after he’d been ousted from Apple, and while NeXT’s technology was amazing, and hugely impactful behind-the-scenes in the technology world — NeXT workstations running in labs and at universities — they were never the press darling that Apple was. Still, I was very pleased when he replied:
“I’ll be keeping my eye out for you.
Steve”
These days, Steve’s one-liner replies to apparently randomly selected e-mails he receives, of which I’m sure there are thousands daily, are still exciting enough to make most of the gadget sites and geek blogs. For a 15-year old kid, failing computer science because I couldn’t “follow instruction” it was the encouragement I needed to keep going.
When Steve Jobs came back to Apple as the “interim CEO“, bringing NeXT’s revolutionary operating system with him, and charging the brilliant designer Jonathan Ive to differentiate Apple’s sea of samey products in a marketplace full of beige and boring, he re-sparked the imagination of an industry. What he’s done since: from the iMac, to the iPod to the iPhone, delighted all of us, but surprised none who’d used the original Mac. We reasonably expect Steve to shake things up. It is his demanding, sometimes tactless, but visionary genius that shaped his company — and helped shape the industry.
I won’t pretend to be emotional about a man I don’t really know resigning from a company I don’t work for — unlike some of the press. But I will acknowledge that this is the end of an era. When Bill Gates resigned from Microsoft, the industry lost a brilliant thinker, engineer and businessman. As Steve winds down his presence at Apple, the industry is losing a brilliant creator, leader and artist.
I’m a little disappointed that I was too young to end up working for either of them — having missed Bill by a few years at Microsoft, and having followed a path not likely to end in Cupertino (save for that one night I crashed the bar where Apple employees hang out, Windows Mobile phone in tow!) But I’m proud to have the opportunity to occasionally stand in the shadows these titans still cast.

The loser now will be later to win

(or: “Why I fell out of love with Apple”)
You could chalk it up to a preference for the underdog — and you’d probably be right — but even that considered, you’d have to admit, Apple is not the company it once was. And if you’re an Apple fan/user/cult-member now, it’s not likely for the same reasons that us faithful few were 10 years ago.
The original Macintosh was a dream — or rather it was the combination of dreams seized by one charismatic, but arrogantly demanding young leader, then shaped into something he saw as perfect (even in the spots it wasn’t.) It was a rag tag group of creative engineers and code poets, flying a pirate flag, working insane hours, and pouring parts of their soul into a little computer that changed everything… even while it was scorned by the industry it would re-create.
Steve Jobs was that imperfect perfectionist, and the team he assembled were some of the brightest ever to put a product together. Their names were engraved inside the case of every Mac that shipped in its first few iterations — something only the privileged would see, because Mac’s weren’t designed to be opened by their users. (Why would you need to open it? It was already perfect. Never mind that the first version barely had enough RAM to boot!)
Although it never got the respect it deserved, and although the CEO Steve brought into to run the company that grew so fast he couldn’t control it had him ousted fairly quickly, throughout the 80s and 90s, the Mac remained different. And different is good. It stood as a challenge to beige, boring and impersonal. It made technology beautiful, and delightful to use. Even in their darkest years in the mid-90s, when vision drift, product confusion, leadership paralysis and technology stagnation all added up to some less-than-stellar computers baring the Macintosh name and the aging Mac OS, a Macintosh computer still had an intrinsic value — magic, even — that no other piece of technology, save maybe for the Walkman upon its introduction, could evoke.
When Steve slowly but triumphantly took back the reigns of Apple Computer, following the acquisition of his follow-up act, the revolutionary but under-appreciated NeXT Computer company, and its impressive technology portfolio, we Apple faithful sat on the edge of our seats waiting to see what would happen. His next moves: enabling the talented in-house designer Jonathan Ive to build the first iMac, the re-purposing of the entirely object-oriented OpenStep OS from NeXT as the long-awaited re-creation of the Mac OS, shocking the world (and eventually the music and media industries) with an MP3 player and music store that people actually loved to use, and finally changing I.T. irrevocably with the iPhone, made us all cheer as the company we loved finally took its rightful place as an admired and chased-after leader in technology.
But for me, that’s when it all went downhill. I can only imagine Apple is now what Steve always dreamt it would be. Certainly his exacting and demanding pursuit of perfection, from chassis design to software stack, although infamously making him simultaneously terrifying and inspiring to work for, has lent itself to the creation of some truly beautiful and usable products. But success has put them in the position he so sharply criticized throughout his younger, more idealistic years as a passionate, egotistical, but often-right visionary. Now Apple is “Big Brother” dictating what users can and cannot do with their gadgets they’ve purchased. The friendly Mac face is gone, replaced by the App Store, where Apple takes a 30% cut of every piece of software (and content) that runs on their gear — a brash, monopolistic and cloyingly controlling move that even Bill Gates at the height of his career wouldn’t have dreamt of trying to foist upon an industry.
Steve’s top-to-bottom approach that created that imperfect but perfectly lovable Mac, with all its eccentricities that could be tolerated only because so few of us used them that all of us could share the work-arounds and unofficial upgrades that voided our warranties but kept our Macs ticking long after we were supposed to have purchased a new one, has now created generation after generation of disposable gadgets that are really only supposed to be useful until the next shiny Cupertino-produced iToy comes out to make last year’s purchase seem foolish and out-of-date. Love may still go into their design and manufacture, but its a fickle love who’s expiry date is looming almost as soon as the product ships.
I confess, I work for the other side now, and maybe this new perspective has tainted my outlook. There was a time, though, that I wouldn’t have dreamt of working for the other side. Apple was something to believe in and cheer for, and everyone else was the lumbering, uncreative, bureaucratic evil empire of technology, trying to lock individuals into corporate I.T. guidelines and scheduled maintenance plans. Now Windows is actually a pretty “insanely great” product, and Bill Gates is working to cure malaria and finally rid the world of polio, while the underpowered iPad continues its short march to planned obsolescence in the face of next year’s model (which will have the built-in webcam that they pulled at the last minute from the first generation device to give them something to sell the drooling, mesmerized iPublic in 12 months.)
Don’t get me wrong: I’m still proud to have been a faithful Mac user for the nearly 20 years I spent nursing those eccentric but intrinsically wonderful old Macs along, while cheering for each success my favorite computer company claimed in the face of overwhelming odds. I still love seeing Steve’s first keynote (and many of the following ones!) as iCEO, and those “Think Different” ads still tug at my creative side. But its been a long time since Apple was that company, and although they’ve found the success we always hoped for them, I think they’ve lost their soul in doing so.
For those of you who are “new to Mac” and think you’ve bought into something special, I won’t begrudge you the feeling you get when you open that beautifully designed box — just know that what you’re experiencing is a fraction of what it might have been, had you had the guts to buy an Apple product before they were the latest fad.
For those of you who have been loyal all this time: here’s to the Crazy Ones! I was going link to the “Think Different” page on Apple’s website, but all it says now is “Page Not Found…”

Installing Rhapsody DR2 on VMWare

Between the acquisition of NeXT by Apple in the late 90s, and the release of OS X, Apple tried and abandoned a path to merge the two company’s technologies into a new, modern OS. Ultimately, a similar but different path was chosen, where much of the proprietary technology that made OpenStep expensive (specifically Adobe-licensed PostScript) were re-created, and better compatibility (introducing Carbon into the Classic OS to give developers an easier migration path than the hard and fast change to Yellowbox) with existing Mac applications was provided for.
Nonetheless, what amounts to an experiment: Rhapsody, essentially the NeXTStep/OpenStep OS with Mac interface elements bolted onto it (sometimes), was incredibly interesting. Yellowbox was to represent the new app platform (with built-in multi-architecture support) while the Bluebox, for compatibility with Classic Mac apps was to be added before release.
Shortly I will outline instructions here for getting Rhapsody DR2 (x86) up and running in VMWare. OK, it turns out this process is exactly the same as for installing NextStep. In case it wasn’t obvious, these two OSes are very closely related.

AppleTV for Mac

This remains the most popular thing I’ve ever posted — despite the fact that its really nothing special. The meat of it is a little start-up script that contains no undiscoverable tricks. I don’t even use it any more!
Nonetheless, it’s in-demand, and I can’t find a hosting method that can keep up. So, here’s my solution:

  • The start-up movie is no longer available here — it probably shouldn’t have been posted here to begin with. If you find someone with a Patchsticked AppleTV, it’s trivial to SCP in and grab the start-up movie (discussed here.)
    You can also use any other movie you want, which you specify when you edit the script.
     
  • The screen saver never worked right on a normal Mac, but Scott Q has engineered a replacement. His link appears to be down, but get in touch with him and send him your thanks.
     
  • The script itself is still available here.
    Copy and Paste the script into the AppleScript editor, updating it to provide the path to where ever you want your start-up video, and save it as a run-only script. Add it as a Login item in your account, and you’re set.
     
  • The background image I made is awful (it was just a screen shot) and I’m sure someone’s made better, but I’ll keep that here if you want it. If you do this right, you should only see the wallpaper for a few seconds anyway, so if you make yourself an all black image, or find a nice Apple logo, you’ll be all set.

And honestly, that’s all that was released. Like I said, nothing magical. My Mac Mini worked fine as a Home Theater PC, but eventually I just went with an actual hacked AppleTV (which smoothly handles anything but MKV) because I wanted my Mac for other things. If you find any other great ideas, feel free to share them here!

Assorted, Scattered Objective-C Notes as compared to C#

A outlet is like a pre-known property that can be bound
(ie: drag destination object to origin object and assign to the outlet (property) nextKeyView)
myObject.methodToCall(parameters)
is like
[myObject methodToCall:parameters];
int i = myObject.assignValue;
is like
int i = [myObject assignValue];
form.Window(makeKeyAndOrderFront(target));
is like
[[form window].makeKeyAndOrderFront:target];
object myObject();
is like
id myObject;
string myString;
is like
NSString *mystring;
Defining an instance method:
private string myMethod();
is like
– (NSString *)myMethod;
Defining a class method:
public DateTime myMethod();
is like
+ (NSDate *)myMethod;
private float convertAmountbyRate(float amt, float rate)
is like
– (float)convertAmount:(float)amt byRate:(float)rate;
convert.convertAmountbyRate(1.0, 2.3);
is like
[convert convertAmount:1.0 byRate 2.3];
public interface myInterface : myClass {…}
is like
@interface myInterface : NSObject {…} @end

Assorted, Scattered JavaScript Notes

Boolean(value) method returns false for falsey values, true for truthy values
falsy: false, null, undefined, “”, 0, NaN
truthy: everything else: “0”, “false”

+ as a leading operator converts a string to a number: +”42″ = 42. Same as Number(“42”) = 42), parseInt(“42”, 10) = 42
+”3″ + (+”4″) = 7

=== !== do not do type coercion, slightly faster

if (a) {
return a.member;
} else {
return a;
}
can be written as
return a && a.member;
if the first operand is truthy, return the second operand, else, return the first

but for || if the first operand is truthy, return the first operand, else, return the second:
var last = input || somethingElse;
so if input is truthy, then last is input, otherwise set last to somethingElse

you can label loops and break them by label:
myloop: for (whatever)
{
break myloop;
}

//other loop
for (var name in object) {
if (object.hasOwnProperty(name))        //avoids looking at objects we might have inherited from
{
name //is the current member
object[name] //is the current member value
}
}

//multiple conditions in switch statements
switch(something) {
case “;”;
case “,”;
case “.”;
isPunctuation();
break;
default:
somethingElse();
}

//exceptions and object literals
throw new Error(myReason);

throw {         //create an “object literal” creates an exception object on the fly
name: myexceptionName,
message: reason
};

//object literals
an object literal is wrapped in { }
a name can be a names or a value
values are any type
: seperates names and values
, seperates pairs
object literals can be used anywhere a value can appear
var myObject = {name: “Jack”, ‘goto’: ‘Jail’, grade: ‘A’, level: 3};
var myName = myObject.name;     //extracts “Jack”
var destination = myObject[‘goto’];     //extracts “Jail”
var destination = myObject[“name”];     //extracts “Jack”
var destination = myObject[goto];       //returns an error because goto is a reserved word, hence the other notation

//maker function
function maker (name, grade)
{
var it = {}; //makes a new empty object, good shorthand
it.name = name;
it.grade = grade;
return it;
}
var myObject = maker(“Jack”, “A”);

//an object with an object as a member, shorthanded
var myObject = {
name: “jack”,
grade: “a”,
clothes: {
pants: ‘blue’,
shirt: ‘red’
}
};

//if you have more than a couple parameters in a function, why not make them an object?
function myfunc(pa, pb, pc, pd, pe, pf)
myfunc(pa, pb, pc, pd, pe, pf)
vs.
function myfunc(specs)
myfunc({ pa: ‘1’, pc: ‘3’, pb:’2′, … })

** note: variables that are not var’ed become implicitly global

//specify object’s prototype on creation? linkage — doesn’t really exist
var newObject = object(otherObject);
//gives it a secret pointer to otherObject, but the secret pointer is used for retrieving only NOT storing
//object (lowercase) is a method that Yahoo made up
//different than

var newObject = Object() which equals: var newObject = object(Object.prototype)

delete myObject[memberName];    //deletes (sets to undefined) a member of an object

myArray[myArray.length] = 3     //appends to end of array (same as pop)

var myArray[]   //creates a new array?

Resolving missing dependencies when building a NeXTStep/OpenStep App

If you’ve played around with NextStep/OpenStep trying to build a sample app — say, so you can find out how much OS X/the iPhone is like those sweet black machines of yesteryear — you might have an error like this one, when attempting to build a sample app you’ve created: AppKit.h not found (or any one of the other billion header files that are missing)
This may mean an incomplete installation of the Developer tools. Here’s what to do:

  • From the Developer CD, open the NextCD folder and then Packages.
  • From the Services menu, use Open Sesame to open the Package as Root
  • Install the Package to its default file locations.

NextStep: Open as Root
Now, in your project in PB, you may need to tell the compiler where to find those libraries.

  • From the Tools menu, open the Inspector and look at the Build Attributes.
  • Under Framework Search Order, Set… a new path to where those files just got installed: /NextLibrary/Frameworks
  • Do the same for Header Search Order, but use /NextDeveloper/Headers

Project Builder: Framework Search
Now you should be able to Build in Project Builder! Note that PB doesn’t have a “Build and Go” that I can find, so once you build, you need to use Workspace Manager to find your newly made .app and double click it to test it out.