Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Tuesday, November 6, 2007

Deja Vu and Reverse Psychology

Here's an interesting conversation that I had last night at a barbecue:

'Yeah, I hear that Linux desktops may hit 1% of the market soon...'

'Interesting...so how are they tracking that?'

*shrug*'I think that they're planning on tracking installs on the hardware so that they have a better idea.'

'What on the new Dell Linux PCs?'

'No, those other linux pcs.'

'The XO Laptop?'

'No, the other ones'

'The Asus ones?'

'Yeah.'

Regardless, the following hardware review for the Asus EEE PC came out of right field:

I have been waiting for the eee pc since I saw a blurb about it in, of all places, Vogue. They were pushing it as a computer that fits in your clutch, and since I travel a lot, I was salivating.

I am writing on it now, and I am just thrilled with it. It does indeed fit into my purse (it's about the size of a small-ish notebook or journal) and my wifi connection worked right away when I opened it up. I've been using the battery for about 2 hours so far and it's still at 40% power, so that looks promising.


...

WHAT?!

Did I miss something? Since when are Linux computers featured in Vogue? Since when do people give glowing reviews for Linux hardware on Amazon?

And since when does my sister print out a Tux pumpkin stencil for Halloween?

But this reminds me of a point in my life from a long time ago. A point where I looked around and said 'there's no way that people are actually going to start using the internet, but boy it would be cool if they did'.

So now I'm thinking, 'There's no way that people are actually going to start using Linux, but boy it would be cool if they did'.


UPDATE Nov 7, 2007:
Great article on Forbes regarding the Asus Eee PC and the technical, cultural, economic hurdles involved: http://members.forbes.com/global/2007/1112/024a.html

Also, my friend Scott has almost simultaneously blogged about the XO Laptop!

The idea virus is go!

Wednesday, April 11, 2007

Trace Output on Linux with Flash Player 9

I just spent about 45 minutes getting my flash player to trace to a text file. So as of this writing, here are the current things that you should watch out for when attempting to trace() out with flash on linux:

Make sure that you have the debugger version installed. If you are using Ubuntu, or another distro that uses package management, remove the flash player package. On Ubuntu Feisty Fawn, this is the flashplugin-nonfree package. Open synaptic and uncheck the package. It will warn you that you are removing the ubuntu-restricted-extras package also. Don't worry about this, as its a dummy package.

Install the debugger version from the adobe site. This is pretty straightforward.

Once installed, you must turn on the trace reporting by creating a file in your home directory called mm.cfg with the following contents:

TraceOutputFileEnable=1
ErrorReportingEnable=1
MaxWarnings=1

So what exactly will these three lines do? Well the first says that we should print out all trace() function calls to the file ~/.macromedia/Flash_Player/Logs/flashlog.txt. The second option says that we should also print out our stack traces and exceptions to the log file. Lastly MaxWarnings is how many lines the log file will contain until the player stops. This page goes more in depth.

A couple important points: The documentation is incorrect, and the output file is NOT ~/macromedia/Flash_Player/Logs/flashlog.txt but ~/.macromedia/Flash_Player/Logs/flashlog.txt . This is important because files with a '.' in front are hidden, so you won't see a 'macromedia' folder pop up in your home dir.

Secondly, the flash player is smart enough to create the ~/.macromedia/Flash_Player/Logs/flashlog.txt path, directories and all. So you do not need to create this path manually.

Ok, so now you've installed the debug version, and you've created your mm.cfg. Your logging to the file, and now you want to watch the output! Well, you have many options at your disposal. A favorite option is the FlashTracer extension for FireFox. Here is a special version that works on Linux.

Another option is to use 'tail' a basic command line program that displays the tail end of files:

tail -f ~/.macromedia/Flash_Player/Logs/flashlog.txt

As with all command line programs, you can pipe them to do fun interesting things :)

tail -f ~/.macromedia/Flash_Player/Logs/flashlog.txt | grep DEBUG

To just get all the lines with DEBUG on them.

tail -f ~/.macromedia/Flash_Player/Logs/flashlog.txt | grep -C 3 DEBUG

Get the lines that have DEBUG on them, and the lines around them (useful for seeing what happened before and after the line in question).

And here is a simple script that encapsulates the above tail usage into a simple program:

#!/bin/bash
if [ -z "$1" ]
then
tail -f ~/.macromedia/Flash_Player/Logs/flashlog.txt
else
tail -f ~/.macromedia/Flash_Player/Logs/flashlog.txt | grep $1
fi