Python code that talks to pettycoin.