Longevous Joy Menu

Another addition due to lack of a menu online. From ramen shop Longevous Joy, in Bensonhurst (Brooklyn).

Honestly, the ramen didn’t compare to what you would find in Manhattan ramen shops, or ZuZu Ramen in Gowanus. Served warm as opposed to hot, pork was far from tender, and I don’t remember noodles or broth being anything special. However it was shortly before closing time, so perhaps that had an effect on the food?

HelloWorld Android App in 10 Steps

Finished product.

I was a little annoyed by the fact that the setup of a development environment and the creation of a simple app for the Android system was so spread out all over the place on Android’s developer website, so I decided to write up my own quick guide/tutorial/howto.

Don’t get me wrong, the developer website is great, I just wanted all the steps to installing the environment and creating an app in one place.

These instructions apply whether you’re using a Mac, PC, or Linux. All of the software below is cross-platform.

Please leave a comment if anything is unclear.

1)   If you don’t already have it, download/install JDK.

2)   Download and install Eclipse IDE for Java Developers (any package of Eclipse should be okay though; this particular one was the smallest download).

3)   Download and install the latest version of Android SDK.

4)   In Eclipse install the ADT plugin which connects the Eclipse IDE to all the Android SDK tools:

  1. Start Eclipse, then select Help > Install New Software….
  2. Click Add, in the top-right corner.
  3. In the Add Repository dialog that appears, enter “ADT Plugin” for the Name and the following URL for the Location: https://dl-ssl.google.com/android/eclipse/
  4. Click OK
    Note: If you have trouble acquiring the plugin, try using “http” in the Location URL, instead of “https” (https is preferred for security reasons).
  5. In the Available Software dialog, select the checkbox next to Developer Tools and click Next.
  6. In the next window, you’ll see a list of the tools to be downloaded. Click Next.
  7. Read and accept the license agreements, then click Finish.
    Note: If you get a security warning saying that the authenticity or validity of the software can’t be established, click OK.
  8. When the installation completes, restart Eclipse.

5)   Run Android SDK Manager, which you can now do in Eclipse, via Window (top menu) > Android SDK and AVD Manager. Make sure to download Tools, Platform-tools, and at least one Android Platform (e.g. Android 1.5 is what I will be using for this tutorial) under “Available packages.”

Note: If for some reason Eclipse can’t find the SDK location, you can set it via Window > Preferences > Android. There you can point Eclipse to your SDK installation path – e.g. “C:\Program Files\Android\android-sdk”.

6)   Create Android Virtual Device in “Virtual devices” by clicking on “New…” button. Give it any name you want, set the target to the platform you downloaded, and leave everything else as is. This will be the emulator your app runs on.

7)   Create a new project (File > New > Project…). Select Android Project. Name it “HelloWorld” and give it the package name “com.example.helloworld”. Any Android build target will work for this simple app.

8)   After the project is created, use the package explorer on the left (which you can enable via Window > Show View if it isn’t already) to expand your project, and open the HelloWorldActivity.java file in the src > com.example.helloworld directory. This is where your code will be.

9)   Replace the contents of the java file with the following:

package com.example.helloworld;
 
import android.app.Activity;
import android.os.Bundle;
import android.widget.TextView;
 
public class HelloWorldActivity extends Activity {
	/** Called when the activity is first created. */
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		TextView tv = new TextView(this);
		tv.setText("Hello, Android");
		setContentView(tv);
	}
}

As you can see there are only a few changes. You have imported a TextView widget class and used it to show a string of text.

10)  Finally, test the code by running it Run > Run, and select Android Application. The Android Virtual Device you created earlier in the SDK Manager should pop up, boot, and run your HelloWorld app. Congrats!

In my next post I’ll go a bit more into depth about application layout (buttons, text widgets) and actually having the app do something besides display text.

Citizen Gotham2 Folding Bike Review

Background:

I think I’m a fairly moderate user of bicycles. While I don’t commute on a bicycle every day, it’s one of my primary modes of transportation – whether I’m going to get groceries, on an errand, rock-climbing at my local gym, etc. Basically any destination that’s less than 10 miles away.

I have also often been in situations where I needed to transport my bicycle – the college I attend is 60 miles away so I often take a train to get there, or a car (if I have access to one). With a bicycle I can skip the subway/campus bus on my way to the train/parking lot, and also get around campus.

A normal bicycle is rather unwieldy in that you will either end up sitting in a special section on the train while making sure you’re bike is stable for 2 hours, if you’re lucky, or standing on the train for 2 hours. If you’re driving, you would need a large car to fit the bicycle, or a bicycle rack to set up every time you take it with you. This is where I was hoping a folding bike like Gotham2 would come in handy.

Several factors made me decide on a Gotham2 bike – price, weight, looks, and available accessories. At 27 lbs it’s pretty light, and being able to get it with fenders and rack preinstalled as well as a convenient bag sounded very attractive just in terms of everything being done for me.

Things I liked:

It feels light. With the rack/fenders, it weighs in at 30.2 lbs according to my bathroom scale.

A lot of 20″ folding bikes look somewhat silly, but Gotham2 looks aggressive and pretty streamlined to me. I got the graphite color but I’m sure pearl probably looks just as good.

Components seem pretty high-quality, changing gears is smooth and quick.

Is pretty quick – I expected it to be noticeably slower due to the smaller wheels but that hasn’t been the case at all. However I haven’t done any sort of acceleration/speed test.

Initial folding is simple and quick.

First bike I got with a sufficiently comfortable seat.

Very inexpensive compared to similar folding bikes from Dahon and others. Upgrades such as bag and fenders/rack are also reasonably priced.

Things I didn’t like:

In my opinion, the gearing is too low. I emailed citizen about this and they replied that it’s designed for “comfortable city riding” and that I can retrofit a larger chainwheel. I ride it in New York City and I’m usually on the highest gear (7th). It would be perfect if it was the 4th or 5th gear.

The bike needs 2 velcro straps to stay folded. Otherwise there’s nothing keeping the two halves of the frame together, nor the handlebar from swinging. This means a significant increase in folding/unfolding time.

There’s no comfortable place for your hand when holding the bike in a folded state. You will either be holding it awkwardly by the seat or awkwardly by the frame. This makes for uncomfortable carrying between train aisles. While the bag may mitigate this issue (haven’t tried it yet outside of home), it adds the additional inconvenience of having to pack and unpack the bike as well as carry the bag around.

In addition, the bike does NOT roll when folded. There’s a convenient stand in front of the pedals for when the bike is on the ground, but it’s rendered almost useless if the pedals are turned from a horizontal orientation, at which it’s pretty difficult to turn them back (due to the brakes or something impeding the rear wheel from moving).

Things to note:

Not really a con, but you should note that despite the height range on Citizen’s website, depending on your inseam, Gotham2 may be too small. I’m 5’10″ and I have to extend the seat to the maximum height (as denoted on the stem) to be comfortable.

Lastly, just because a bike folds, doesn’t really make it smaller. I thought it did (silly me), practically, but really it’s just much wider. In an apartment setting you still need to dedicate quite a bit of space for it. In a train setting, I found out that I still can’t put it on the overhead racks (and it’s pretty uncomfortable to do so even if it fit due to the lack of any handle) or in the leg space, so it takes up at least an extra seat. In a car setting, I found that my expectation of easily fitting it into the front seat of my 2-door was pretty dumb, and a tiny trunk wont fit it, so I still need to use a bike rack for it.

I thought I should point that out to anyone who thinks a folding bike will suddenly be MUCH easier to transport and that you could take it ANYWHERE. It’s easier, but not by a significant degree.

In conclusion, I will be returning the bike as it did not mark a significant enough improvement in my transportation to warrant how much I spent on it and the associated accessories.

Big Brother is Watching (on the internet)

Tracking all Americans on the internet? Easy. Just draft up a bill and call it “Protecting Children From Internet Pornographers Act of 2011.” Anyone opposing it is automatically a child molester.

Ridiculous.

By a 19 to 10 vote, a House committee votes to require Internet service providers to keep track of what their users are doing for one year in case it would be useful for future police investigations. …