Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Replace Operator on iOS 4.x with current prepaid balance. (For PCCW)
Objective-C Shell
branch: master
Failed to load latest commit information.
deb Don't run on startup
src Initial commit
.gitignore Initial commit
README.textile Added screenshot to README
deploy.sh Initial commit
dpkg-deb-nodot Initial commit
ldid Initial commit
makedeb.sh Initial commit

README.textile

BalanceAsOperator

Replace Operator on iOS 4.x with current prepaid balance.
Specifically written for PCCW in Hong Kong, with an AT+CUSD command of “##122#”.

An extension to Fake-Operator

Credit to this site for the source code of sendmodem.

BalanceAsOperator screenshot

Install

Download the .deb package from the ‘Downloads’ link on this page, and install with $ dpkg -i << package >>.deb

How it works

Package contains an executable binary that sends an AT USSD command to the carrier, which returns the balance message. Program then replaces the carrier name in the top left corner with the parsed balance. It does this by altering the com.nspwn.fakeoperatorpreferences plist, and then notifying FakeOperator to update SpringBoard.

Also includes a launchd script that schedules the program to be executed every half hour.

Tags

This project might also be useful if you need to learn how to:

  • Compile an iPhone program for iOS 4.1/4.2
  • Run a script or application on iOS 4.1/4.2 at a scheduled interval (with launchd)
  • Send AT commands to the iPhone/iPad modem (programmatically send SMS/dial numbers/etc)
  • Write plist files to alter preferences for another application

Why

My carrier (PCCW) doesn’t believe in sending SMS alerts when my balance is about to, or even has, run out. I’ve emailed them about it, but thats just the way it is. So I thought this would be a better alternative to getting a new number.

Would be happy to help anyone alter this for their own carriers, if requested. However, some operators do weird stuff like SMS every time you send an AT command like this, so that would be annoying.

Something went wrong with that request. Please try again.