An application for displaying a rotating set of information panels
Project description
Overview
Datapanels is an application for displaying a rotating set of independent panels, each of which displays some useful or entertaining information or something visually interesting.
Usage
After installation, the application can be run using
python -m datapanels.app [--builder_path path_to_builder_file] [--transition-sec secs] [--full_screen]
The --builder_path option lets you specify a configuration file that will determine what panels get displayed. The --transition-sec parameter lets you specify the number of seconds between transitions. If no parameters are provided, a simple default set of panels will be created.
Configuring DataPanels
DataPanels can be configured via a configuration file that specifies what panels should be displayed. This is actually a Kivy ([https://kivy.org/]) configuration file.
The configuration file should take the form:
<DataBuilder>:
PanelType1:
panel type one parameters
PanelType2
panel type two parameters
PanelType2
parameters for another instance of PanelType2
The following example show a sample configuration.
<DataBuilder>:
border: 0
QuotationDisplay:
update_sec: 5
quotations: "See https://github.com/man-vs-electron/datapanels for info on how to configure this application.", "Where you go, that's where you'll be", "Thanks for trying this application."
StockPanel:
tickers: 'MSFT', 'PSEC', 'TSLA'
data_update_rate_sec: 60*20
ticker_change_rate_sec: 5
GameOfLifePanel:
update_rate: 0.5
activated_color: 1, 0, 0, 1
grid_color: 0, 0, 1, 1
Example Usage
TODO
Panel Types
Each panel displayed in Datapanels can be configured. The following sections describe each panel type and its key parameters.
QuotationDisplay
The quotation display is a simple panel that displays quotations. These quotations change periodically.
The parameters include:
- update_sec: The number of seconds before changing the quotation
- quotations: assigned as either a list of strings, one per quotation, or a single string that is a path to a file with quotations, one per line.
StockPanel
The StockPanel display information about a list of stocks. Data about one stock is shown at a time and the specific stock shown is rotated around on a regular basis.
The parameters include:
- data_update_rate_sec: how many seconds between updating the stock info
- proxserver: if not None, a proxy server to use for talking to yfinance
- ticker_change_rate_sec: how many seconds between changing the stock being shown
- tickers: list of security ticker symbols to track
GameOfLifePanel
The Kivy panel that displays the Game of Life, along with some controls.
Key Properties:
- update_rate: number of seconds between each generation
- random_cell_count: Either percentage of cells to make alive or the number of cells to make alive when randomizing.
- background_color - RGBA list for the inactive cell color
- grid_color - RGBA for the grid lines
- activated_color - RGBA for the active cell color
- cell_length - the length of the side of a cell (essentially cell size)
WeatherPanel
The Kivy panel that displays current weather and weather forecast for a list of provided locations.
This panel uses information downloaded from https://openweathermap.org and requires a key. The free key is sufficient for the data that is used in this panel. When configuring the panel, the key can either be places in the configuation key using the owm_key option or an environment variable owm_key can be set.
Key Properties:
-
owm_key - The user's key from https://openweathermap.org/. IMPORTANT: This panel will not work without this key.* It either needs to be specified as a property in the configuration or it needs to be set as an environment variable. You can get a free key by registering at openweathermap.org.
-
temp_units - either fahrenheit or celcius (Default - fahrenheit)
-
text_color - the rgba color of the text and line components of the interface. (Default - [0,0,0,1])
-
bg_color - the background color (Default - [.5, .5, .5, 1])
-
data_update_rate_sec - The number of seconds between data updates
-
location_switch_rate_sec - The number of seconds to show each location
-
locations - a list of WeatherResponse objects, one each for the locations of interest. This attribute can be set by assigning a list in the form of [(lat1, lon1), location_name1, (lat2, lon2), location_name2, ...]. This is the form to use when assigning locations using the configuration file. If assigned this way, it will be converted in a list of WeatherResponse objects.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file datapanels-0.1.3.tar.gz
.
File metadata
- Download URL: datapanels-0.1.3.tar.gz
- Upload date:
- Size: 128.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.6.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e7a0c840d753bd3e25ab7e6c267334edbecf11c8697e8e8f17787cef52ea2c03 |
|
MD5 | b5b964e632f77b1f33f8626e3ce22956 |
|
BLAKE2b-256 | fda5cda7a210a6a3a8af075becb9a0e98a677d83a6d53bc8f7ad6be8d017f204 |
File details
Details for the file datapanels-0.1.3-py3-none-any.whl
.
File metadata
- Download URL: datapanels-0.1.3-py3-none-any.whl
- Upload date:
- Size: 162.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.6.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.8.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | f139bda52d4daa4f42fb17a2b83ec7d54faaffadc18df585edd69e7fbb0f282d |
|
MD5 | ff2b09b1e93c9f90a734ce286c30d5e2 |
|
BLAKE2b-256 | 8fa1a41481d96334153770879ab21d87519305556d071e7bedfdfe668aac265c |