Geekzone: technology news, blogs, forums
Guest
Welcome Guest.
You haven't logged in yet. If you don't have an account you can register now.


wintersm

87 posts

Master Geek

Trusted

#75435 18-Jan-2011 09:31
Send private message

I have created a widget that will show your 2-degrees pre-pay balance on an android phone.

It will update after a phone call or when you click update..


Give it a go..



You can download it from the Android Market - Now called NZ Phone Balance Widget

https://market.android.com/details?id=nz.org.winters.android.nzmobileaccountwidget

I need some feedback, more features will come soon - eg update intervals, only work on a 2degrees connected mobile e.t.c.





Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.

View this topic in a long page with up to 500 replies per page Create new topic
 1 | 2 | 3 | 4 | 5 | 6 | ... | 8
NonprayingMantis
6434 posts

Uber Geek


  #428330 18-Jan-2011 09:41
Send private message

How does it get the balance? Does it send an SMS or use the data connection?



bazzer
3438 posts

Uber Geek

Trusted

  #428331 18-Jan-2011 09:43
Send private message

I don't need to know my balance continuously in real time, so I just added a shortcut that direct dials *100*1#. Other info that gives me is the expiry date, so maybe you'd want to add that?

wintersm

87 posts

Master Geek

Trusted

  #428332 18-Jan-2011 09:43
Send private message

To get the data, it uses a data connection and parses the 2degrees web site pages, does a login and gets the details from the first page..

I put in an option to only update when connected to wifi as the 2degress pages are enormous at 300k each and it loads 2 or 3 of those..

:)

 




Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.



wintersm

87 posts

Master Geek

Trusted

  #428333 18-Jan-2011 09:45
Send private message

bazzer: I don't need to know my balance continuously in real time, so I just added a shortcut that direct dials *100*1#. Other info that gives me is the expiry date, so maybe you'd want to add that?


Expiry date is in the screen you get when you click on the widget..


 




Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.

killerteddy
50 posts

Geek


  #428338 18-Jan-2011 09:59
Send private message

Nice app!
Maybe it can show data balance as well?

wanghou168
453 posts

Ultimate Geek


  #428344 18-Jan-2011 10:11
Send private message

Thanks for the app
works quite well

Another info about showing txt or data addons?




MOBILE: Huawei P30
OTHER: Thinkpad E14 + Asus Vivobook + Intel NUC5i3 + A family of Raspberry Pi x 9 + Amazon Echo


lokhor
2858 posts

Uber Geek

Trusted

  #428371 18-Jan-2011 11:30
Send private message

Works well however I'm sure you don't need to use data to retrieve this information. You could use the USSD Code *100*1# and then you would not need data. Also showing how much data usage is left would be nice.




All comments are my own opinion, and not that of my employer unless explicitly stated.


 
 
 
 

Shop now for Lenovo laptops and other devices (affiliate link).
wintersm

87 posts

Master Geek

Trusted

  #428379 18-Jan-2011 11:50
Send private message

Ok, got out of a meeting, seeing some more comments good.. I will try to answer..

Data & text packs, I dont buy them, I need to know if they show up in the screen when you press on the widget, if so, its easy to add it to the front screen if I know how it is displayed, or I need a snippet of the html from the 2 degrees page that shows those balances.


USSD- I did look into that, was my first thought, but the android sdk is missing (maybe on purpose) the ability to retrieve UTMS data after the call is made. 

:)





Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.

timmyh
188 posts

Master Geek

Trusted

  #428400 18-Jan-2011 12:42
Send private message

Yes I am getting data pack result:

"
PrePay Credit      xx.xx
(expiring on 31 December 2011)

Your 'top up ang get' special rates
(expiring on)

National Data         20.77
(20.77MB expiring on 09 February 2011)
"

cool!

timmyh
188 posts

Master Geek

Trusted

  #428403 18-Jan-2011 12:46
Send private message

Just added a 50MB data pack and noticed a wee bug:


"
PrePay Credit      xx.xx
(expiring on 31 December 2011)

Your 'top up and get' special rates
(expiring on)

National Data         70.77
(20.77MB expiring on 09 February 2011)
"

The 20.77 underneath didn't update to match the 70.77. Not sure if this is your side of 2deg side.

wintersm

87 posts

Master Geek

Trusted

  #428404 18-Jan-2011 12:46
Send private message


"National Data         20.77
(20.77MB expiring on 09 February 2011)"

Thanks - need this

I will have a look tonight at putting the data onto the main window where text is, if there is both, I should be able to fit them on..

 




Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.

timmyh
188 posts

Master Geek

Trusted

  #428406 18-Jan-2011 12:50
Send private message

The 20.77 underneath didn't update to match the 70.77. Not sure if this is your side of 2deg side.


It's a 2deg bug, not yours ;-)

tombrownzz
147 posts

Master Geek
Inactive user


  #428408 18-Jan-2011 13:02
Send private message

wintersm: To get the data, it uses a data connection and parses the 2degrees web site pages, does a login and gets the details from the first page..

I put in an option to only update when connected to wifi as the 2degress pages are enormous at 300k each and it loads 2 or 3 of those..

:)

 


You mean 2degrees homepage is 300kilobytes big? 

wintersm

87 posts

Master Geek

Trusted

  #428412 18-Jan-2011 13:05
Send private message

yup the login page & the first page you see after logging in are just over 300k each , and thats just the html without the images, so I have to load the login page to get a session ID, login which loads another page which has data, then send a logout which is probably loading another 300k (I need to look into that and see if i can make sure it is not)..

It seems like alot for the pages, bit of an overkill.. not mobile friendly at all..

Edit - my brain was playing tricks, 110k for the login page, so maybe i was thinking that the app is downloading around 300k each refresh.. 




Phone: Google Nexus 1 , stock Gingerbread 2.3.4 Self Rooted.

vita
68 posts

Master Geek


  #428414 18-Jan-2011 13:06
Send private message

The 2Degrees site displays this as the app displays it.
If you have 2 x data packs of the same type - the one with the closet expiry is shown with the amount.
The site would need to list each individual pack with its own balance and expiry for this to change.

Perhaps you should PM the 2D rep and see if there are any options of developing this app with them :) 

 1 | 2 | 3 | 4 | 5 | 6 | ... | 8
View this topic in a long page with up to 500 replies per page Create new topic





News and reviews »

Air New Zealand Starts AI adoption with OpenAI
Posted 24-Jul-2025 16:00


eero Pro 7 Review
Posted 23-Jul-2025 12:07


BeeStation Plus Review
Posted 21-Jul-2025 14:21


eero Unveils New Wi-Fi 7 Products in New Zealand
Posted 21-Jul-2025 00:01


WiZ Introduces HDMI Sync Box and other Light Devices
Posted 20-Jul-2025 17:32


RedShield Enhances DDoS and Bot Attack Protection
Posted 20-Jul-2025 17:26


Seagate Ships 30TB Drives
Posted 17-Jul-2025 11:24


Oclean AirPump A10 Water Flosser Review
Posted 13-Jul-2025 11:05


Samsung Galaxy Z Fold7: Raising the Bar for Smartphones
Posted 10-Jul-2025 02:01


Samsung Galaxy Z Flip7 Brings New Edge-To-Edge FlexWindow
Posted 10-Jul-2025 02:01


Epson Launches New AM-C550Z WorkForce Enterprise printer
Posted 9-Jul-2025 18:22


Samsung Releases Smart Monitor M9
Posted 9-Jul-2025 17:46


Nearly Half of Older Kiwis Still Write their Passwords on Paper
Posted 9-Jul-2025 08:42


D-Link 4G+ Cat6 Wi-Fi 6 DWR-933M Mobile Hotspot Review
Posted 1-Jul-2025 11:34


Oppo A5 Series Launches With New Levels of Durability
Posted 30-Jun-2025 10:15









Geekzone Live »

Try automatic live updates from Geekzone directly in your browser, without refreshing the page, with Geekzone Live now.



Are you subscribed to our RSS feed? You can download the latest headlines and summaries from our stories directly to your computer or smartphone by using a feed reader.