This use markfickett/minecraftstatus library to check the the status of a Minecraft server, including list of online players. A prestine copy of mcstatus.py is included here.
This is a merge from two independants project found on github:
- bennuttall/people-in-space-indicator-blinkt People in Space Indicator with Pimoroni's Blinkt
- Raspberry Pi (any version with 40 pins to accomodate the Blinkt!
- Pimoroni Blinkt!
- USB cable and power
- MicroSD card
- network connectivity to a minecraft server
- (Optional) FADO lamp from IKEA
- Pimoroni Blinkt Python library this need to be downloaded and installed separately
- markfickett/minecraftstatus this is included in this repository
This indicate a blue count of user connected to the Minecraft server (from 1 to 8) and blink red when in error. It use the Men in Space logic
This is an ambiant display where all LEDs from the Blinkt! show the same color. You are supposed to put the PiZero and Blinkt! into a FADO lamp from IKEA.
Here is the display logic:
- Constant Green mean server OK but no-one connected
- Blinking Blue mean server OK and number of blink is the number of user connected
- Blinking constantly Red mean problem to connect to the server
Even better than mc_blinkt_fade.py, this version use fade-in fade-out rather than blinking. It make it even more ambiant indicator and you will notice if the program stop for some reason. Still minded for inclusion into a FADO lamp from IKEA.
Here is the display logic:
- Slow Fade in and out of Green mean server OK but no-one connected
- Each fast Fade in and out of Blue between Green indicate the number of user connected
- Slow Fade in and out of Red mean problem to connect to the server
This is a copy of the core part of mcstatus.py. It can be used to build other version that use Blinkt! or else.
Run mc_blinkt_count.py server_name_or_ip
on a Pi with connectivity to the minecraft server
Run mc_blinkt_fado.py server_name_or_ip
on a Pi with connectivity to the minecraft server
Run mc_blinkt_fade.py server_name_or_ip
on a Pi with connectivity to the minecraft server
In a loop, it connect to a Minecraft server, query the number of connected user and it lights up an LED per user connected, in sequence.
If the Minecraft server is unavailable, the end LED blinks red.
Very special setup (totally out of the scope of this project) for this Raspberry PiZero. The PiZero get both network and power from the host (MAC mini) from a single USB cable. The setup was made based on this: Setting up Pi Zero OTG - The quick way (No USB keyboard, mouse, HDMI monitor needed) Additionnaly, the MAC mini is sharing it's internet connectivity for update and communication with remote Minecraft server.
This project is based on a Raspberry Pi learning resource wrote by Ben Nuttall that just uses simple LEDs using GPIO Zero. See People in Space Indicator.