How to open the Ubiquiti Bullet M2

I was trying to get OpenWRT working on my Bullet M2, but was having issues. So I heard there was a serial port on the board that you can use to grab debug information. I proceeded to open the sucker up, and at first was doing it wrong.

The proper way is by taking the ring off near the N connector for the antenna. I used some vice grips and it came off rather easily with some muscle. Here’s a photo with the ring circled in red. ;D

Once the ring is off, you simple push the N connector and the board will slide out of the enclosure.

Now all you need to do is connect a MAX232 TTL Converter to the following pins.

I haven’t found a good TTL to RS232 converter that has decent cables. There are some but I’ve yet to research them fully. You also need the proper pinout, which I don’t know yet so if you have a solution for both please post a comment. Thanks!

Groovy (Grooveshark) Plugin for Apple TV2 4.2 Firmware

I stumbled upon an updated package for Groovy thats works on my Apple TV2 4.2 Firmware. The following forum topic is where I found the package. As well as a direct download mirrored on my site.

http://forums.plexapp.com/index.php/topic/22489-groovy-app-for-apple-tv/

Download com.atv.groovy_0.4-5_iphoneos-arm.deb – [download id=”4″]

Funny Chainmail about Economics and Stimulus Packages

I received this chainmail recently and thought it was funny.

Economics 101 = Short & Interesting

It is a slow day in the small Manitoba town of Lac du Bonnet and streets
are deserted.

Times are tough, everybody is in debt, and everybody is living on credit.

A tourist visiting the area drives through town, stops at the motel, and
lays a $100 bill on the
desk saying he wants to inspect the rooms upstairs to pick one for the
night.

As soon as he walks upstairs, the motel owner grabs the bill and runs next
door to pay his debt
to the butcher.

The butcher takes the $100 and runs down the street to retire his debt to
the pig farmer.

The pig farmer takes the $100 and heads off to pay his bill to his supplier,
the Co-op.

The guy at the Co-op takes the $100 and runs to pay his debt to the local
prostitute,
who has also been facing hard times and has had to offer her “services” on
credit.

The hooker rushes to the hotel and pays off her room bill with the hotel
owner.

The hotel proprietor then places the $100 back on the counter so the
traveler will not suspect
anything.

At that moment the traveler comes down the stairs, states that the rooms are
not satisfactory,
picks up the $100 bill and leaves.

No one produced anything.

No one earned anything…

However, the whole town is now out of debt and now looks to the future with
a lot more
optimism.

And that, ladies and gentlemen, is how a “stimulus package” works.

Mac Tip: Create a Solid Color for Desktop Background OSX

I wanted to choose a different Solid Color for my Desktop Background on my Mac. In order to achieve this, you have to complete a couple of steps. All of the default Desktop Backgrounds for “Solid Colors” are located in “Macintosh HD/Library/Desktop Pictures/Solid Colors”. From here you can add PNG images and they wil be available under the “Desktop” section of “Desktop & Screen Savers” in System Preferences. You just need to create a new PNG image with the color your would like to use and then you can set it as your Desktop Background. I’ve provided some steps on how to complete this easily.

1. Double click on “Macintosh HD” on your desktop.
2. Navigate to the following folder “Macintosh HD/Library/Desktop Pictures/Solid Colors”.
3. Right click on “Solid White.png” and select “Duplicate”.
4. Rename the newly created file to “Solid Green.png” or to whichever color you wish to create. (This is important as the name on the file is used for the name under the “Solid Colors” section in Desktop & Screen Savers”.
5. Open the the file “Solid Green.png” in your favourite image editor, I use Gimp. Which can be downloaded for free online at http://gimp.org
6. Change the image to be the color of your choice, and save the file.
7. Open “Desktop & Screen Saver” and you should now see “Solid Green” in the list. You’re done!

Here is a screenshot of “Solid Green” located under “Solid Colors”.

Looking at Cassandra (DB) and Hiphop (Compiling PHP to Native C)

I was all over the internet one day and ran into a project called Cassandra. Which was opensourced by Facebook and is being developed by Apache committers as well as other major companies.

http://cassandra.apache.org/

I also dug up another Facebook related project called Hiphop, which compiles PHP into native C to boost performance. Also used by Facebook.

https://github.com/facebook/hiphop-php/wiki/

Adding APC to MediaTemple Grid Service

I have a client that wanted to start his own personal blog. He’s in the IT industry and wanted to use WordPress, he didn’t know what Shared Hosting Provider to go with. I suggested two, dreamhost.com and mediatemple.com

I don’t like shared hosting, why? It’s either slow at time for hours or always slow, so instead I just grab a VPS and pay the $30 or $50 month so my sites load fast. You could even ditch your Grid Service and go with a Dedicated Virtual, and achieve lighting fast page loads on your WordPress/PHP site.

Anyways, lets talk more about how to setup APC properly on the Grid Service. I mean lets really talk about it, because I always forget the steps.

You will need to first download the latest stable version of APC, I’ve had issues with the beta version and the stable version. But far less with the stable version. If you want to pick and choose which version to run visit the APC PECL Website directly at http://pecl.php.net/package/APC

I almost forgot, if you want to follow the instructions in this guide. You will need to have SSH access enabled on your Grid Service account. This guide will assist you.

http://kb.mediatemple.net/questions/16/Connecting+via+SSH+to+your+(gs)+Grid-Service

Once you have access and the URL to the latest stable release of APC (3.0.19 as of this writing). You will want to wget the file to the root of your account.

wget http://pecl.php.net/get/APC-3.0.19.tgz

Decompress and untar the archive, change directory to the extracted contents and phpize the module.

tar -zxvf APC-3.0.19.tgz
cd APC-3.0.19

Next you will want to run phpize. The phpize command prepares the PECL modules build environment.  Once you run phpize you will see something similar to the following:

server@n10:~/APC-3.0.19$ phpize
Configuring for:
PHP Api Version:         20020918
Zend Module Api No:      20020429
Zend Extension Api No:   20050606

Now we want to set the configuration options for the module. You will need to find out what version of PHP your Grid Service is running, you need to know the Major and Minor numbers. You can get this information from phpinfo, you will need to create a new file inside your sites html directory and enter the following:


Make sure the file has a .php extension and then open up a browser and view the file. You should be presented with something like the following.

You can see that we’re running PHP 5.2.14-2, the “-2” is more or less for MediaTemples reference.

Next you want to type out the following command and run it, pay special attention to the “-with-php-config” portion as this is important, make sure you find the right location of this file then run the command.

./configure -enable-apc -enable-apc-mmap -with-apxs2=/usr/sbin/apxs -with-php-config=/usr/local/php-5.2.14-2/bin/php-config

A bunch of text should scroll, hopefully no errors. Now we want to make the module so just type “make”.

xxxxxxx.com@n10:~/APC-3.0.19$ make
/bin/sh /home/xxxxx/users/.home/APC-3.0.19/libtool --mode=compile gcc -I. -I/home/xxxxx/users/.home/APC-3.0.19 -DPHP_ATOM_INC -I/home/xxxxxx/users/.home/APC-3.0.19/include -I/home/113041/users/.home/APC-3.0.19/main -I/home/xxxxxx/users/.home/APC-3.0.19 -I/usr/local/php-5.2.14-2/include/php -I/usr/local/php-5.2.14-2/include/php/main -I/usr/local/php-5.2.14-2/include/php/TSRM -I/usr/local/php-5.2.14-2/include/php/Zend -I/usr/local/php-5.2.14-2/include/php/ext -I/usr/local/php-5.2.14-2/include/php/ext/date/lib -DHAVE_CONFIG_H -g -O2 -c /home/xxxxxx/users/.home/APC-3.0.19/apc.c -o apc.lo

-------------CUT TO SAVE SPACE--------------

----------------------------------------------------------------------
Libraries have been installed in:
/home/xxxxx/users/.home/APC-3.0.19/modules

If you ever happen to want to link against installed libraries
in a given directory, LIBDIR, you must either use libtool, and
specify the full pathname of the library, or use the `-LLIBDIR'
flag during linking and do at least one of the following:
- add LIBDIR to the `LD_LIBRARY_PATH' environment variable
during execution
- add LIBDIR to the `LD_RUN_PATH' environment variable
during linking
- use the `-Wl,--rpath -Wl,LIBDIR' linker flag
- have your system administrator add LIBDIR to `/etc/ld.so.conf'

See any operating system documentation about shared libraries for
more information, such as the ld(1) and ld.so(8) manual pages.
----------------------------------------------------------------------

Build complete.
(It is safe to ignore warnings about tempnam and tmpnam).

Now we just need to make the appropriate directories for the module to reside. The directory you need to find is called “data”, if you follow these steps below you can navigate to the directory. Then make the proper directories, and then copy the module.

cd ~/
cd ../..
cd data
mkdir -p lib/php
cp ~/APC-3.0.19/modules/apc.so

The last step is to modify the php.ini and have PHP load the newly created apc.so module. (Note: in the second example, the ‘xxxx’ stands for your user number, you can find this by running “pwd”)

nano ~/../../etc/php.ini
or
nano /home/xxxx/etc/php.ini

Then just add the following lines:

extension_dir = /home/113041/data/lib/php
extension = apc.so

You should now have APC loaded into PHP, double check by going to the phpinfo page you made and search for APC. It should give you some information and configuration variables. Furthermore, if APC is not being loaded and shown on the phpinfo page, enable the error log (http://wiki.mediatemple.net/w/GS:Read_access_logs_and_error_logs) and see if any error messages are being generated.

Hope you enjoy!

Ubiquiti Bullet M2 and Some Random Long Omni-Directional Antenna

So I purchased a Bullet M2 made by Ubiquiti, you can find their site at http://ubnt.com

I grabbed it from http://www.xagyl.com/ which is located in Ontario, there are no places in British Columbia that I know of that carries Ubiquiti or Microtik Products. This device supports POE (YAY), but I had to get a POE inverter.

I also purchased an omni-directional antenna, and I was surprised when I got the package. This is the antenna I bought.

http://www.xagyl.com/store/product.php?productid=16327&cat=262&page=1

This is what it looks like, I was totally suprised.

So this “2.4GHz 12dBi Omnidirectional Antenna N Male Connector” antenna, is long! Those are my keys on the ground!

New Workspace Setup

So sitting in my room in the dark, I usually don’t get motivated. So I decided to make the hump to a 27′ monitor for my living space that was so awkward it I had no use for it. So I turned it into a workspace. So now I have my Macbook Pro, 27′ monitor and an Apple Keyboard setup for all my grind at projects, code and problems.

So far it’s worked out really well for me. Here’s some pictures

Mikrotik Routerboard Pictures

Here are some pictures of the Routerboard 750G, I purchased two of them. One I will be deploying in a 22 room hotel, the other is one to play with at home.

This thing is absolutely awesome when it comes to customization, and what it can do. It does more than dd-wrt. However dd-wrt is great since you can put it on any consumer hardware.

Here are some pictures of the Routerboard 750G’s I just picked up. Awesome equipment!

Forget TwitterUpdater Use WordTwit!

Alright, I was stumbling around looking for some things and found this wonderful plugin called WordTwit

This plugin is awesome! Not only is it really clean and done well, but it has multiple URL Shortening services. No Bit.ly login support at the moment. However there is one great thing about it that I love. The fact that each post has this little box under tags, that tells you whether the post has been tweet’d or not.

Now that’s really awesome. I love this plugin!