Blizzardboy

Psymeg & Chooch

Photos, Linux, Travel

Google Goes 8 Bit!

Google have released an 8 bit controller for NES – very cute! and I love the route option.

You have to love that video:)

Will be back in Japan end of the week – will have to dig our Nintendo out of storage – now where can we get one of those cartridges…

Django on Debian Squeeze with Postgres

Here are my notes for getting Django set up on Debian Squeeze with Postgres as the database. System was a new virtual machine running on VMWare Fusion.

Install dependencies for psycop2 and postgres:
sudo apt-get install python-dev libpq-dev postgresql python-django

Download and install psycopg2 (path will change – check – http://initd.org/psycopg/download/)

wget http://initd.org/psycopg/tarballs/PSYCOPG-2-4/psycopg2-2.4.4.tar.gz
tar -xvf psycopg2-2.4.4.tar.gz
cd psycopg2-2.4.4/
sudo python setup.py install

Add a user and database in postgres:

su - postgres
CREATE DATABASE djangotest;
CREATE USER django WITH PASSWORD 'django';
GRANT ALL ON djangotest TO django;

Run django-admin.py startproject mysite as per the tutorial website to get started.

In settings.py I had to specify localhost as the database machine – they comments say this isn’t needed.

So in settings.py the database section will look similar to this (I have changed the password…):


DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2', # Add 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' or 'oracle'.
'NAME': 'djangotest', # Or path to database file if using sqlite3.
'USER': 'django', # Not used with sqlite3.
'PASSWORD': 'django', # Not used with sqlite3.
'HOST': 'localhost', # Set to empty string for localhost. Not used with sqlite3.
'PORT': '', # Set to empty string for default. Not used with sqlite3.

From there you should be good to go with the tutorial.

Lost in Tokyo – Beautiful Video

I haven’t seen a video of Tokyo this beautiful in a long while:

Lost in Tokyo from Mark Bramley on Vimeo.

Happy New Year y’all!

Music for Coding

Reading the Coding Horror post Music to (Not) Code By, got me thinking about what I listen to when I code. I have pretty varied music tastes, but there is a lot of music that I listen to outside of work that isn’t really conducive to good coding.

Here is my top list:

1. Salmonella Dub, The Black Seeds, Kora etc
Good New Zealand dub. Nice and mellow with a sense of humour.
2. Peter Pik
Australian jazz guitarist. See him playing sometimes on the streets of Sydney.
3. Jose
Another Australian Jazz guitarist. He also plays on the streets of Sydney. I don’t go to music stores anymore, so buying CD’s on the street is a good retro way for me to get new music.
4. The album Ishi Kubari
Okinawan folk songs. I like to float along to this.
5. Koh Tao – On
Chilled ambient music.

That is what I am currently listening to while coding. I have tried lots of different music, but have found anything classical beyond the early modern composers too discordant to code to. And coding to Mandalavandalz or Texas Faggot is fun, but I always get distracted.

I think listening to music while coding is important, especially if you work in a busy office as it helps one to concentrate. What do you like to listen to at work?

Things to do next time in Japan

Funny living in a country like Japan for so long – over 10 years and 6 of those in Tokyo – that there are still so many things there that I never experienced. Most of the things on my list are things I feel I should have done, rather than really wanting to do them. Kind of like living in China for 9 months and not visiting the Forbidden Palace or seeing the Great Wall!

Here is my short list:

Yakatabune

Yakatabune are (were) fishing boats (pleasure boats) that one can rent out, or buy seats on to enjoy dinner or fireworks in places like Tokyo Bay. I always wanted to go out on one, sitting on the tatami and enjoying the fireworks. Expensive though and you need a minimum (depends on the company) of 4 people, and to book in advance. Famous since the Edo period, yakatabune would be perfect for a summers evening.

National Gallery
National Museum
Galleries and museums are funny things. I quite like installation art like the exhibitions that used to be shown at the Physics Room in Christchurch. That and looking through drawers of butterflies. There are many ways to write history – museums and galleries being a big part of that.

Tokyo Stock Exchange
Tokyo Stock Exchange has free tours. I went to the free museum at the Bank of Japan and that was fascinating.

Ghibli Museum
Feel like I should have gone, though I am not much of a fan of anime. Have enjoyed a couple of Miyazaki’s works though.

Japanese Diet
Ah, Japanese politics…

Sumo

Baseball
The only baseball game I have ever been to was Futatsui Junior High vs. Hatchimori Junior High (iirc). Seeing a professional game would be fun – J League Soccer sure was.

Visit Kamakura
Visit Nikko
Visit Hakone
There always seemed to be less trodden places to visit.

Climb Mt Fuji
Not sure if I really want to do that:) but I visited close by often enough.

The Network Engineer

Why did the network engineer cross the road?

Traceroute

Why did she come back?

Ping

It’s a bird, it’s a plane, nah mate it is Sydney!

Well it has been a while since I posted here, but we have been getting a few messages so I thought I would bring you up to date.

Following the earthquakes in Christchurch, and in Japan, we have decided to move from Japan to Australia.

We see the situation in Japan as being quite safe at the moment. But we have been thinking of leaving Japan for some time, so now is a good opportunity for us.

Lots to write about, but lots to do! So that is all for now.

binda’s bengali dahl

yellow lentils

soak over night – one pack ftw.

next morning, get some salt, 1 onion, teaspoon of curry powder and boil until soft.

in a separate fry pan get some garlic 2 buds about half an inch of ginger, one tomato, and some pepper (cayenne optional). olive oil. crush / grate ginger and garlic. heat olive oil, couple of spoons. saute ginger and garlic about 5 mins, add tomato, saute till becomes a sauce. poor into lentils

***

soup

lentils. olive oil, onions, saute onions and lentils, low heat for 5- 10 mins.

add water 125-150 mls. (depending on consistency wanted)
cook that till done.

then get a big bunch of parsley. chop it up fine. once boiled add parsley. add a big whack of grated ginger (4-9 tbs).

turn heat off and add ginger.

nom nom with bread or rice.

nb: both of these are untested!

Japan Election Results

The dust has almost settled on another election victory for one of Japan’s leading political parties. Gaining a few percentage points over the previous election results, a party spokesperson said that this result vindicated their recent middle of the road approach to the various economic and foreign relation problems being faced by the east Asian archipelago.

The Prime Minister, keen to extend his short reign of power, appeared before reporters at the official residence in Tamieke-sanno dressed in an elegantly cut dark suit with a crisp white shirt and a confidently understated tie. He calmly answered a number of questions on various topics. When asked about what his government intended to do about Japan’s current economic malaise, he stated, “We will continue to develop measures to remedy that issue.” On the ongoing issue of Japanese – American relations, he was quoted as saying, “America remains Japan’s most important ally and we look forward to continuing and developing that relationship.”

No news has as yet been forthcoming regarding a possible cabinet reshuffle, however there has been some speculation that some senior members of the previous cabinet will have their portfolio’s reshuffled to make way for new blood from the back benches.

Centos show version

To see which version of Centos a machine you are working on is running, at the command line type:

cat /etc/redhat-release

For me it was:

CentOS release 5.5 (Final)

           Next >>