Friday, July 1, 2011

Facebook 1.6 + WIFI using Aerize WIFIX

Most of the black berry owners are facing this dilemma of "I really like the BB with all of it's software, but I hate to be obliged to pay for using my phone monthly". Most of us hate to be obliged to do something that we really don't wanna do, such as paying for a blackberry plan to use the facebook app for instance.

This small guide/checklist/whatever will guide you through the neccessary steps to install and run facebook app version 1.6.0.22 on your BB on WIFI.

First, we'll need to check that we satisfied the following points:   
  • make sure that you have the version 1.6.0.22
  • make sure that the WIFI is disabled
  • note: if you have Aerize wifix , make sure that it's disabled
  • make sure that you have a well-configured APN
  • make sure that your facebook account is using http not https
  • make sure that you are logged out from facebook from all sites with except of your mobile
Ok, great, now install facebook 1.6.0.22, and log in for the first time, make sure that you have enough airtime/credit in your plan cuz it uses the APN to log in not the WIFI.

Leave the account logged in, open Aerize and press on new
Now, press on "add host" and add the following hosts:
  • api.facebook.com (when the Facebook home page)
  • profile.ak.fbcdn.net (used when the friend's profile)
  • Photo-a.ak.fbcdn.net (used when viewing photos)
  • photos-b.ak.fbcdn.net
  • photos-c.ak.fbcdn.net
  • photos-d.ak.fbcdn.net
  • photos-e.ak.fbcdn.net
  • photos-f.ak.fbcdn.net
  • photos-g.ak.fbcdn.net
  • photos-h.ak.fbcdn.net
  • photos-a.ak.fbcdn.net
  • sphotos.ak.fbcdn.net (to put this host gives me no error in the photos and the excellent load)
  • static.ak.fbcdn.net
  • external.ak.fbcdn.net
  • creative.ak.fbcdn.net
  • apps.facebook.com
  • static.ak.connect.facebook.com
  • platform.ak.fbcdn.net
Great, now try to use the facebook through WIFI.

That's it for today, in case you don't have Facebook 1.6, you can get it OTA from http://arthurtooy.com/download/bb/apps/fb16/022os5/fb16022os5.jad 

There is also another guide, in Vietnamese that explains how to install 1.7, but I could apply the method mentioned, you are very welcome to try and feed me back, here is the LINK translated with Google translate.

Saturday, June 11, 2011

Java Power Tools

This is a very fast brief on how to get and install the most important , in my own opinion,  java power tools you will use in your every-day development activities.

PMD 

To install the PMD plugin for Eclipse:
  • Start Eclipse and open a project
  • Select "Help">"Software Updates">"Find and Install"
  • Click "Next", then click "New remote site"
  • Enter "PMD" into the Name field and "http://pmd.sf.net/eclipse" into the URL field
  • Click through the rest of the dialog boxes to install the plugin
Alternatively, you can download the latest zip file and follow the above procedures except for using "New local site" and browsing to the downloaded zip file.

To configure PMD, select "Windows">"Preferences", then select PMD.

To run PMD, right-click on a project node and select "PMD">"Check code with PMD".

To run the duplicate code detector, right-click on a project node and select "PMD">"Find suspect cut and paste". The report will be placed in a "reports" directory in a file called "cpd-report.txt".

To find additional help for other features, please read included help by selecting Help>Help Contents and browse the "How to..." section in the "PMD Plugin Documentation" book.

After installing an update, if you get an Exception such as "java.lang.RuntimeException: Couldn't find that class xxxxx", try deleting the ruleset.xml file in the .metadata/plugins/net.sourceforge.pmd.eclipse directory in your workspace.

To get Eclipse to not flag the @SuppressWarnings("PMD") annotation, look under the menu headings Java > Compiler > Errors/Warnings > Annotations > Unhandled Warning Token.

Source :http://pmd.sourceforge.net/integrations.html#eclipse


CheckStyle

The recommended way to install the Eclipse Checkstyle Plug-in on Eclipse 3.2/3.3 is via the update site.
  • Within Eclipse go to Help>Software Updates>Find and Install
  • Choose Search for new features to install and press Next
  • Create a New Remote Site...
  • Input a name to your liking (for instance Checkstyle Plug-in) and input the following URL: http://eclipse-cs.sf.net/update/
  • Click your way through the following pages to install the plug-in.
  • Restart Eclipse
  • Copy the ruleset xml file to your project's root directory.
  • Go to Window > Preferences > CheckStyle.
  • Click on New and configure as shown below. Click on browse to find the your ruleset file.
  • You should see something like the following picture.
  • Click OK to accept it.

Note: Alternatively the Checkstyle Eclipse Plug-in can be downloaded from the Eclipse Checkstyle Plug-in's SourceForge project download site.

Source: http://eclipse-cs.sourceforge.net/downloads.html


FindBugs

Update sites allow you to automatically install FindBugs into Eclipse and also query and install updates. There are three different update sites

FindBugs Eclipse update sites
Site Description
http://findbugs.cs.umd.edu/eclipse/ Only provides official releases of FindBugs.
http://findbugs.cs.umd.edu/eclips-candidate/ Provides official releases and release candidates of FindBugs.
http://findbugs.cs.umd.edu/eclipse-daily/ Provides the daily build of FindBugs. No testing other than that it compiles.

You can also manually download the plugin from the following link: http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_1.3.9.20090821.zip?download. Extract it in Eclipse's "plugins" subdirectory. (So /plugins/edu.umd.cs.findbugs.plugin.eclipse_1.3.9.20090821/findbugs.png should be the path to the FindBugs logo.)

Once the plugin is extracted, start Eclipse and choose Help → About Eclipse Platform → Plug-in Details. You should find a plugin called "FindBugs Plug-in" provided by "FindBugs Project".

Source: http://findbugs.sourceforge.net/manual/eclipse.htm

Go Green - Save Earth

"On average, PCs utilize 280 watts of electricity", the usual working hours for a PC is 4 to 10 hours, so the average is about 7 hours.

Based on the previous scenario, the monthly consumption of a single tower would be 280 Watts X 7 Hours/Day X 30 Day = 58800Wh Or 58,8 kWh which is , with simple calculations, about 715 kWh a year (It's worth mentioning that a fridge , working all time, built after 2001 consumes about 500 kWh per year).

Producing Electricity in the United States (2006).
Coal 50%
Nuclear 19%
Natural gas 19%
Hydroelectric 7%
Petroleum Other 3%
renewables 2%

Based on the table above, we would see that U.S depends mostly on the coal as a power source (bear in mind that this is not pure coal) for producing electricity.

As shown in the figure below, coal (which contributes by 50% of our energy) for every kWH of energy produces more that 0.6 lbs of pure CO2 emission, so if the avreage computer as mentioned above consumes 715kWH to operate, then it's producing about 536.25 lbs of CO2 emission every year.

Let's say that out of the average of 7 hours/day that we use the PC, we take an average of 1 hour break without turning off or even putting the computer in the standby mode, then we are wasting about 1 Hour X 280 Watt X 365 Day/Year = 102.2 kWH of wasted energy per year, and producing a useless CO2 emission of about 61.32 lbs. So what the solutions might be, well, there is a variety of option , easiest is to turn off your computer when you don't need it for long periods, or at least putting the computer in the stand by mode. You can also try to find the power efficient computers (like the star energy certified products), you can also assure that your pc gets good ventilation all the time because the more heat , the more power is needed for cooling.

I hope this thread was both informative and entertaining, sorry if it was long but i couldn't help it.
Sources:
Sustainability 101: A Toolkit for Your Business By Anca Novacovici, Jennifer Woofter
Chemistry and chemical reactivity, Volume 2 By John C. Kotz, Paul Treichel, John Raymond Townsend