Friday, March 21, 2008

Computer Bliss

In response to my co-worker Brandon's recent post about his computer upgrades... and possibly a little follow-up to my previous post about the MacBook Air...

I used to have two machines in my office with a total of 6 hard disks and about 300 loud fans spinning in them. One was a desktop, running a development virtual machine and a generic office/web applications. The other was a bare-metal development box for doing hardware development.

They've been replaced with a 17" MacBook Pro. It runs my development environment in a virtual machine (which I simply copied over from the previous machine, how nice!). It also allows me to do some crazy things like plug it into our gigabit network and use optical discs. Then, I moved my hardware box into our engineering lab and connect to it via RDP when I need to access it.

The result? My office is completely silent. I can bring the MacBook home (or anywhere) and have the actual development environment from work right there, no VPN, no VNC. It's also a fully-functional computer, no sacrifices. Not to mention, I get to use MacOS!

If I don't want to bring a whole full-size MacBook Pro somewhere (like the places a MacBook Air would go), I still have the iPod Touch which does a great job of running a web browser and reading email.

Thursday, March 6, 2008

Trouble with audio sample rates and SX Servers

One of the things I've been hearing from our support guys at Tightrope Media Systems is a lot of people have legacy content that is 44.1kHz audio that they would like to play back on their SX Server. The server, however, requires the standard DVD sample rate of 48kHz. This leaves everyone sad.

To help, I built a simple little utility that uses ffmpeg to fix the audio inside an mpeg2 file to be compatible with an SX Server. It's a little Windows app that you can run, drag a batch of files and folders onto and it will do its best to process the files to make them work on the SX.


Download FixMpeg
Read More about FixMpeg at my software site

Monday, January 28, 2008

Why the MacBook Air?

Apple just released their super slim MacBook Air. I got to thinking, this is perfect, it's super portable, you can carry it around easily and keep in touch wirelessly from your couch, coffee shop, et c. It doesn't have the real power of a full-blown computer, so you probably would be able to do all your work on it. Instead, it is perfect to read email, browse the web, look at pictures, maybe some other stuff.

Wait? Doesn't the iPhone and/or iPod Touch already read email, browse the web, look at pictures and do a bunch of other stuff? With your data plan, it also does it at a lot more places... and it's a lot more portable and a lot cheaper.

It seems that Apple already has a mobile platform, they should focus on it. The MacBook Air is a distraction from it.

Thursday, January 17, 2008

Unity/Coherence for non-virtual PC?

I use a Mac at home and want to have the ability to run PC software. I wish I could use only a Mac, but I still do some development on Windows and I have some weird legacy hardware that can't be put on/into the Mac but works fine on the ol' PC. Boot Camp is too disruptive and Parallels or VMWare don't let me use those strange hardware devices and they are slower than real hardware (which I already have).

For some time I've used multiple monitors and have one on the Mac, one on the PC with Synergy. That leaves me with less screen real estate for either machine and I end up using the Mac most of the time anyway.

I would just like to banish my PC to the closet without a head (monitor) and just use it over the network when I need to. VNC and remote desktop (RDP) are great for accessing the banished PC, but it obscures a lot of my beautiful Mac when I am connected. What would make it so much more seamless is having technology like VMWare's Unity or Parallels' Coherence but against a real, not a virtual, PC. I mean, they did it, it is useful, someone has probably made that, right? Not really...

I tried searching for just a rootless VNC viewer (rootless is what you call it in X windows when you don't have a background). No luck. Hmm, maybe X is the right track though, since X windows can display any client (application) on a display (server) running anywhere. Yes, I found a great thread of someone looking for just what I was on slashdot. That lead me to find a bunch of discussion by David Fraser and his XOpenWin project that was meant to capture a Window's application's display commands and translate them to be displayed on an X server (which the Mac has built in!). He, unfortunately, never got it working, but was beat to it by Sawanaka who made a wrapper using a Microsoft technology called Detours to capture the display of an application and sent it to X using the display layer from a project called PEACE from NetBSD. This project was called cygpeace. Since then, cygwin has changed a lot and has destabilized his code which hasn't been updated in a few years. I managed to get it to compile with some minor modifications to headers (especially for freetype) and removing a few function prototypes that have changed in Windows. Unfortunately it still didn't work.

After that long tale of searches, I grew sad and weary, but came to discover that Matthew Chapman had developed an open source client for the Microsoft Remote Desktop/Terminal Services protocol (RDP) called rdesktop. At least I won't have to use Microsoft's RDP client (which it turns out isn't as horrible as it used to be). Is that all the silver lining to this tale? As it happens, no, there exists a fantastic little hack contributed to the community from Cendio called SeamlessRDP. With the help of a small wrapper on the PC, you can display any application's windows to a remote X server! Perfect! It looks just as good as Coherence (you sometimes see glitches while moving things, but perfectly reasonable).

This is great, except on any normal person's Windows install you don't get unlimited RDP connections, so that means you get to run only one application remotely. Arrg, so close.

But wait! These nice fellows at Fontis have a further patch to SeamlessRDP that lets you run more than one application at once! Perfect! A real, usable solution.

I just had one issue, the domain socket they opened from the master rdesktop process had an off-by-one error in the name, this patch should fix the "not a socket" errors that would surely come up if you try this (as of January, 2008).


diff -c seamless.c ../rdesktop/seamless.c
*** seamless.c 2008-01-17 18:57:27.000000000 -0600
--- ../rdesktop/seamless.c 2008-01-11 18:17:19.000000000 -0600
***************
*** 608,614 ****
saun.sun_family = AF_UNIX;
strncpy(saun.sun_path, socket_name, sizeof(saun.sun_path));
unlink(socket_name);
! if (bind(sock, (struct sockaddr *) &saun, sizeof(struct
sockaddr_un)) < 0)
{
perror("Error binding to socket: bind");
exit(1);
--- 608,614 ----
saun.sun_family = AF_UNIX;
strncpy(saun.sun_path, socket_name, sizeof(saun.sun_path));
unlink(socket_name);
! if (bind(sock, (struct sockaddr *) &saun, strlen(saun.sun_path) +
sizeof(saun.sun_family) + 1) < 0)
{
perror("Error binding to socket: bind");
exit(1);
***************
*** 651,657 ****
/* Connect to server */
saun.sun_family = AF_UNIX;
strcpy(saun.sun_path, socket_name);
! len = sizeof(saun.sun_family) + strlen(saun.sun_path);
if (connect(s, (struct sockaddr *) &saun, len) < 0)
{
perror("Error connecting to socket: connect");
--- 651,657 ----
/* Connect to server */
saun.sun_family = AF_UNIX;
strcpy(saun.sun_path, socket_name);
! len = sizeof(saun.sun_family) + strlen(saun.sun_path) + 1;
if (connect(s, (struct sockaddr *) &saun, len) < 0)
{
perror("Error connecting to socket: connect");

Friday, December 7, 2007

School Shootings

The media needs to stop covering school shootings (and mall shootings like the recent one in Omaha) where someone goes and shoots a bunch of people and then commits suicide. If there was no chance to become famous by doing such a crazy thing, maybe it'd make it less glamorous.

Tuesday, May 9, 2006

Gas Prices

What I find the most annoying at the pump is fluctuations from day to day. This morning one station was $0.20 higher across the street from another on my way to work. What I think we need is a statewide gas price to reduce the volatility at the pumps. It is ridiculous to have the prices go up or down $0.20 in one day or if you drive 5 miles down the road.

Friday, February 10, 2006

Olympics

Every major sporting event like the Olympics is full of scandal around participants' performance-enhancing drug usage. We should stop this paranoia surrounding using these drugs and rather embrace it. There should be a second version of the Olympics that allows performance-enhancing drugs, body augmentation, cybernetic implants, et c.

Olympic athletes have made many sacrifices to participate, why not allow the ones that want to risk a bit more to use a technology and human invention to allow them to take that extra step.