Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/topfunky/particle-lcd-mlb-dashboard
Data import and API glue to send baseball stats to a hardware LCD screen running on a Particle.io device
https://github.com/topfunky/particle-lcd-mlb-dashboard
Last synced: 11 days ago
JSON representation
Data import and API glue to send baseball stats to a hardware LCD screen running on a Particle.io device
- Host: GitHub
- URL: https://github.com/topfunky/particle-lcd-mlb-dashboard
- Owner: topfunky
- Created: 2018-08-04T22:08:41.000Z (over 6 years ago)
- Default Branch: release
- Last Pushed: 2022-12-07T22:20:01.000Z (almost 2 years ago)
- Last Synced: 2024-04-15T14:13:24.981Z (7 months ago)
- Language: JavaScript
- Homepage: https://particle-lcd-mlb-dashboard.now.sh
- Size: 180 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# MLB LCD Dashboard
This experimental code pulls a data feed of major league baseball games and sends it to the https://www.particle.io/ API to display stats on an LCD screen.
:camera: [Tweet with photo of Particle and LCD](https://twitter.com/topfunky/status/1025867900488310785)
:pushpin: NOTE: Code in this repo implements even better custom LCD graphics
# Development Notes
## Setup
Install [Particle CLI](https://docs.particle.io/tutorials/developer-tools/cli/#installing).
```
bash <( curl -sL https://particle.io/install-cli )
```Optionally install [dfu-util](https://docs.particle.io/support/particle-tools-faq/installing-dfu-util/)
```
brew install dfu-util
```## Hardware
- `5v` out of LCD panel plugs into the `3v3` pin
- `GND` plugs into any ground
- `RX` out of LCD panel plugs into `TX` on the Photon
- End pin of 3rd base LED goes to `A6`. End pin of 2nd base goes to `A5`. End pin of 1st base goes to `A4`.
- LEDs need resistor to `GND`.## API
Send a full score to both lines of the LCD:
```
curl -H "Authorization: Bearer $SPARK_ACCESS_TOKEN" https://api.particle.io/v1/devices/$SPARK_DEVICE_ID/lcdRow1 -d arg="*NYY 10 Judg 1-2 LAD 12 8 **"
```Turn on an LED for all bases (321).
```
curl -H "Authorization: Bearer $SPARK_ACCESS_TOKEN" https://api.particle.io/v1/devices/$SPARK_DEVICE_ID/bases -d arg="0000000000000321"
```## MLB Data
```json
away_name_abbrev
home_name_abbrev
status (strikes, balls, etc.)status:
{ b: '2',
ind: 'I',
inning: '4',
inning_state: 'Top',
is_no_hitter: 'N',
is_perfect_game: 'N',
note: '',
o: '0',
reason: '',
s: '1',
status: 'In Progress',
top_inning: 'Y' },linescore
```