Live data from Hacker News

A Raspberry Pi-powered live train station sign

balena.io

131–140 of 146 posts

Re: A Raspberry Pi-powered live train station sign

#131
post #2

That is super cool. But admittedly when I saw the title i was hoping for a mini version of those massive flipboard signs. Those things are amazing.

We've had a short project at some point recreating a station's big departure times flipboard in an ipad app; my colleagues went out there for a couple hours to just look at the thing, record background and noises, write down its behaviour and draw the small nuances and damages in the flippers and their contents. Over a weekend my colleague made a POC of the animation of a single unit, then in the next week the two of us copied that one over in a big grid to display departure times from the API. It was a really cool little project, and IIRC the managers of the organization we made it for would frequently just have it open on their desk or show it off to people.

Re: A Raspberry Pi-powered live train station sign

#132

Earlier quoted context omitted.

I also found that a binary notification is all I needed. I just want to know if everything is running OK or if there are delays. So I built this a few years ago: https://unop.uk/train-disruption-indicator-with-a-blinky-tap...

:-) I use reactube everyday. It is permanently open on my desktop and also as a home screen shortcut on the phone. :+1:

Cheers, nice to know it's appreciated. Someone actually asked me to change it to say "Good Service" the other day! Whoosh...

There is a ~mirror at https://unop.uk/tube/ in case CloudFlare go down. Although as I discovered recently, this doesn't help as the API runs on them too! There's another API I could use as a backup but it's not as good.

For the curious: https://reactube.com/

Re: A Raspberry Pi-powered live train station sign

#133

Very cool but I find a pi is overkill for something like this. ESP8266 or ESP32 would work just as well.

Pi Zero Ws are $10, ESP32 dev boards are $12. Why pick the more expensive one AND spend more time writing the software?

ESP32 boards are about $4 on aliexpress...

I much prefer using an ESP32 for something like this because I don't have to deal with installing distro's, updates, etc.

Re: A Raspberry Pi-powered live train station sign

#134
post #74

I'm working on a few projects at home with ESP and RPi Zero. It's so much fun to do your own "IoT" devices. There's still a problem I don't know solve well, holistically. When you do something with UI there's inputs from humans (buttons, knobs, etc), the network and timers. I'm completely lost how to coordinate that, especially when I use an LED/OLED display. How to make sure a single screen is displayed long enough…

You might want to look into a RTOS.

Each task has its own stack, and can communicate with other tasks with mailboxes or shared memory (with a lock).

You'd have a task for each of the things you mention: debouncing a button, drive the display from a buffer, and application logic.

The application logic then doesn't have to worry about bounces, how long it'll take to drive the display, etc.

Modal screens over static screens is orthogonal to this though. You'd need to build a priority scheme, and only pass down events to the current on-screen view.

Re: A Raspberry Pi-powered live train station sign

#135
post #48

Pretty cool. When I took the train to work I made a simple stop-light with transit data. Trains ran every 10 minutes and it took me a few minutes to walk to the station. Green meant I could definitely catch the next train. Yellow meant I'd make it if I walked fast, and red meant I'd miss this train and need to wait for the next one.

I made something similar when I was in uni and had to catch a bus to get back home, but with my Pebble and a C application: next bus was one button press away and another press was all was needed to start a carefully calibrated double alarm for "start packing" and "leave" times

Is there any option right now as hackable as the Pebble? I'm not sure how I would build something like this right now that the Pebble is gone.

Re: A Raspberry Pi-powered live train station sign

#136
post #52
post #11

Earlier quoted context omitted.

They would, but the Pi Zero is a much better UX for people who don't deal with microprocessors on a regular basis. It has SSH, I can get in and look at logs from my desktop, wifi is standard. It all adds up - and for something like this, the power draw is not an issue, and the cost is minimal.

And constantly compiling and flashing the ESP gets old after a while.

Yeah, this is a pain. I'm glad we have the OTA library, though. Saves so much time.

Re: A Raspberry Pi-powered live train station sign

#137
post #74

I'm working on a few projects at home with ESP and RPi Zero. It's so much fun to do your own "IoT" devices. There's still a problem I don't know solve well, holistically. When you do something with UI there's inputs from humans (buttons, knobs, etc), the network and timers. I'm completely lost how to coordinate that, especially when I use an LED/OLED display. How to make sure a single screen is displayed long enough…

You might want to look into a RTOS. Each task has its own stack, and can communicate with other tasks with mailboxes or shared memory (with a lock). You'd have a task for each of the things you mention: debouncing a button, drive the display from a buffer, and application logic. The application logic then doesn't have to worry about bounces, how long it'll take to drive the display, etc. Modal screens over static scr…

Thanks, ipoopatwork.

I'm using MicroPython and this is what I want to stick with. But I'll research how RTOS is doing things and make an equivalent.

Re: A Raspberry Pi-powered live train station sign

#138

Earlier quoted context omitted.

Doesn't, like, all software that has anything to do with a calendar already do reminders? I know Outlook and Google Calendar do.

Well, sometimes you are in Do not Disturb mode, so notifications don't come through. Also, this thing would always be on, and you simply need to glance over to see: Next meeting in X minutes. Also my calendar is kinda full, so seeing conflicts for the next meetings would be super-cool.

...so let me get this straight. You've specifically told your computer not to remind you about meetings in the straight-forward built-in way it can, and want to build a separate overengineered reminder system out of an overpowered toy to do the same thing?

Christ. No wonder everything in our industry sucks.

Re: A Raspberry Pi-powered live train station sign

#139

Ohh, I think I know the right APIs to make the Boston MBTA version of this. Will post it up if I do it.

PRs welcome - we could remove the 'UK' part of the project and make it work for more cities/countries.

API docs here so I don't forget where they are: https://www.mbta.com/developers/v3-api

Re: A Raspberry Pi-powered live train station sign

#140

Earlier quoted context omitted.

I made something similar when I was in uni and had to catch a bus to get back home, but with my Pebble and a C application: next bus was one button press away and another press was all was needed to start a carefully calibrated double alarm for "start packing" and "leave" times

Is there any option right now as hackable as the Pebble? I'm not sure how I would build something like this right now that the Pebble is gone.

Not that I know of, sadly. Pebble was a jewel :(
Post reply on HN