Live bus tracker (aka an exercise in scraping and API calls)

Welp, irony of ironies, I've decided to screw JSON and just do a string search :p seems that php's "json_decode" is a delicate little flower that likes to **** up whenever it wants, so ya know what I'm not even gonna use ya! Take that!

Dirty as hell but works 100% of the time, until Transperth decide to change their json layout, buuut I don't think that's too likely given how slow they are to change anything at all.

Ah well, added to intranet and it does what it's supposed to.
Next up, making a little screen to put next to the exit door

Are there no good 3rd party JSON libraries for PHP?
 
Tbh I haven't looked, and probably won't cause I don't need to install anything else doing it this way :p laziness ftw.

I found an old RPi model B, overkill really but laziness wins the day again. Found a 5" LCD on ebay for $30 bucks so bought that, now just gotta wait till she arrives
uVgyS2r.jpg
 
While I'm waiting for that screen to arrive, I decided to implement a hotkey to deploy to staff who wanted it, ended up looking like this :p
BouncyFlawlessCrocodileskink.gif
 
Back
Top Bottom