Friday, January 29, 2010

I Loves My Python, Loves My Python

The title comes from a cute little cartoon in "Bowling for Columbine" where a redneck is cradling a rifle while purring, "I loves my gun, loves my gun."

Python is by far my favorite interpreted language. I use it for all sorts of things: client tools (thank you wxGlade!), server scripting, personal file management, and on and on...

If you're serious about using Python, I think you'll really want a project-oriented IDE with debugging, variable inspection, and code hinting. I use Wingware's IDE. Anyone recommend alternatives? Tips for using Wingware IDE?

Tuesday, January 19, 2010

Tethering Android in Ubuntu

First off, I think you can tether any Android phone to create an Internet connection no matter what computer you have, though the methods differ slightly by type (search for PDANet, Barnacle, EasyTether in the market). Legally and technically, it appears possible. Verizon won't give you support to do it and if you ask for help, Verizon will likely want you to pay an additional $50 a month for some kind of a mobile data plan (yikes!). In terms of xfer cap, I've heard you have up to 5GB per month free on the "unlimited" data plan (yeah. I know. Seems contradictory, right?). After that, it's $0.05 per MB, I believe. That total includes any xfers you make on the phone alone. Not bad, I wouldn't think... I don't see most people hitting huge xfers with the mobile phone and hopefully the tethering is used as a backup, not the norm.

As for info from Verizon on this, if found this post on their forums:
http://forums.verizon.com/t5/Android-Devices/TOS-limitations-on-tethering-Citation-needed/m-p/146162#M9721

Here is the response I got. A little more detailed than the other. Basically I got out of it what the guy above me says. Don't abuse it and if you have problems don't complain to Verizon about it cause it ain't their problem.

Thank you for contacting our Verizon Wireless website. We are happy to assist you with your question about using a Verizon Wireless device as a tethered modem.

We will assist you by providing information on our Mobile Broadband Connect feature. This feature enables a device to be used as a tethered modem.

Dear [Valued Customer],

To use a Verizon Wireless device as a tethered modem, the following requirements must be met:

1. You will need a device that supports our Mobile Broadband Connect feature

2. You will need our VZAccess Manager software

3. You will need to add the Mobile Broadband Connect feature to your account

The Motorola Droid does not support our Mobile Broadband Connect feature. Because of this, VZAccess Manager software is not available. Also, the Mobile Broadband Connect feature cannot be added to the account. Because the Motorola Droid does not meet the requirements that we have for tethered modem usage, the device should not be used as a tethered modem. While we apologize that tethered modem usage is not available with the Droid, please note that we are unable to advocate the use of a third party application, such as PDAnet (Windows or Mac only).

We hope you find this information helpful. More information on the Droid device can be found at the following website:

http://support.vzw.com/clc/features/data_services/android_os.html

Other troubleshooting tips and helpful product information can be found at www.verizonwireless.com/data. It has been a pleasure assisting you today. We make it our personal goal to resolve all of your concerns. We sincerely hope that you feel we have done that today. Should you feel your current concerns are not fully resolved, please reply back to this email or call us at 1-800-922-0204 and we will happily address them for you. We appreciate your business and thank you for choosing Verizon Wireless.



So, looks like it can be done for $30 (one time fee) on Windows/Mac without much headache. PDAnet doesn't seem to be avail for Linux. :( However, the Linux solution seems pretty sound as well and is completely free:
http://www.humans-enabled.com/2009/12/how-to-tether-your-verizon-droid-as.html

I've tested this on Ubuntu 9.04, 9.10, and 10.04. It worked flawlessly an all three with my Droid Incredible and my dad's Droid OG.

Monday, January 18, 2010

Mounting VMware VMDK Disks in Ubuntu (Linux)

Took me a while to find the info on this, but it's fairly simple once you piece together all the information out there. First off, I'm not converting this to VirtualBox. I'm simply accessing the HD as though it were mounted on my local file system (Ubuntu). The VMDK image is for a WinXP virtual machine.

First off, verify you have vmware-mount on your system. Drop to terminal, type "vmware-mount". You should get info regarding usage. If not, you need to install VMware Server or VMware Workstation (it's bundled with them). When prompted during the install, say 'Yes' to installing the additional tools packages. Not sure which one it's in, but it's there. Sorry, perhaps someone else can clarify this point.

Next, navigate to the location of your VMDK and type "vmware-mount -p .vmdk". This will show you a list of mount points within the file (first column).

Create /mnt/ using "mkdir /mnt/"

Next, type "sudo vmware-mount .vmdk <# found in column 1> /mnt/"

You can now navigate to that folder and browse/copy the contents of the VMDK elsewhere.

When you're done, just type "vmware-mount -d /mnt/" to release the mount safely.

Deciding on the Best Python GUI Designer: Pt. 2

So, I've developed my first GUI Ubuntu app using Python and wxPython. I ended up doing the layout in wxGlade. Once I figured out how the sizers work, it was cake. I'm still a bit disappointed with some of the cross-platform GUI layout decisions wx makes, but hey, it's not exactly productive trying to emulate a Microsoft "standard", is it?

SO, verdict? wxGlade gets the job done. LOVE the way Python handles the class-based UI stuff and wxGlade makes adding more stuff later a snap without worrying about overwriting anything accidentally. Now, on to SOAP integration with Python...

Tuesday, January 5, 2010

Deciding on the Best Python GUI Designer

I've been learning the various front-end dev tools for RAD Python development lately. I first went to QT because of the extensive design tools available for it. I quickly ruled it out due to its licensing restrictions.

I next gave the various wxPython designers/IDEs a look over. I started with wxGlade as it seems to be commonly used on the Internet. After running through some tutorials, I'm fairly satisfied that it could do what I need but it does lack some of the more advanced layout options.

Boa Constructor shows promise but is pretty convoluted and lacks a certain "polish" that I'm looking for.

I also gave PythonCard a go but it's miserable on Linux, so it's probably out as well...

Any recommendations out there for a solid wxPython layout environment? Do I just need to stick with wxGlade and hope for the best?

Quickly Moving an App to a Different Output (Monitor)

You can always drag and drop or even Alt+drag anywhere on the window to move. However, I was able to activate the "Put" feature in Compiz to accomplish this via a keystroke. The option "Put To Next Output" does just this (just turn it on and give it a key combo).