neopolitan
A library for displaying "text" on LED boards
Description
This is a revamp of stockticker, which queries real-time stock price data, calculates daily fluctuations, and displays it on an LED board. While the end result of that project was cool, this project aims to clarify much of the data display code and make it usable to display any inputted message. See this sub-readme for an introduction to how data can be used to make the board display "human-readable" text.
Given that access to hardware boards can be constrictive and testing can be difficult, this project aims to support data display on a graphical interface so that anyone can access it. pygame is used to display the graphical display, while the neopixel (hence the project name) library is used to interface with the hardware board. The switch between these two displays is OS-dependent.
Installation
[python3 -m] pip install neopolitan
Usage
Make sure to exit the program by pressing the window close "X", instead of ctrl+c
- To run the program
from neopolitan.neop import main as main_function main_function()
- To demo live-update functionality
import neopolitan.testboardrunner
- To run the program with arguments
from queue import Queue q = Queue() # Initialize the input events queue q.put('say This is a demo statement') # Set the message: 'say {message (spaces okay)}' q.put('speed fast') # Set the scroll speed: 'speed {slow/medium/fast}' q.put('wrap True') # Set whether message wraps when done displaying: 'wrap {True/False}; from neopolitan.neop import main main(events=q) # Run main with the specified events
- See Supported Characters for a list of supported characters
https://github.com/alyoshenka/neopolitan/assets/38815390/1e98261b-8dfb-48e3-943b-34b49878c55f
- To run some demos
from neopolitan.demos import * display('This displays a message that cannot be updated') # Execution will return here when the display is closed display_all() # display all defined symbols
https://github.com/alyoshenka/neopolitan/assets/38815390/e9cae65b-2c18-4844-886f-61a2a319c42a
- See this code for an example of how to send live updates in the package
Command Line Arguments
[Deprecated] Note: This code only works from source, NOT the package install
From the top-level neopolitan/ directory: python[3] neopolitan/neop.py {args}
--message/-m {message_to_display}- Displays the given message on the board (enclose in quotes if multiple words)
--scroll-speed/-s {slow/medium/fast}- Controls how quickly the display scrolls across the screen
--wrap/-w {True/False}- Determines whether the display should "wrap around" when it gets to the end, or just show a blank screen
Metadata
Release files for neopolitan 0.1.41
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| neopolitan-0.1.41.tar.gz | 20.4 kB | Without provenance | Details for neopolitan-0.1.41.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| neopolitan-0.1.41-py3-none-any.whl | Python 3 | none | any | Details for neopolitan-0.1.41-py3-none-any.whl |
Total release size: 45.7 kB
Release files / neopolitan-0.1.41.tar.gz
| Download URL | neopolitan-0.1.41.tar.gz |
|---|---|
| Size | 20.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c4aad8e39f49c7ffef7d6ec0722e8d2a4325081bd5c6b8c8ea7dac623c7f5704
|
|
BLAKE2b-256 checksum How to use checksums |
2533fbd1c9d1289a582ec6ccb764c2eeba54282b361d7c3cfc08cbc746e76358
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.6
|
Release files / neopolitan-0.1.41-py3-none-any.whl
| Download URL | neopolitan-0.1.41-py3-none-any.whl |
|---|---|
| Size | 25.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d7c868debb7d3cc67677f0dcce922860c0d52fbe7a5f8d949af35f748a44e8c8
|
|
BLAKE2b-256 checksum How to use checksums |
97cf8c254da181c3a07da0200afe0a7921beb8a35d177274bf63b13cbc8dbc6a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.6
|
Security for neopolitan 0.1.41
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.