This repository was archived by the owner on Oct 24, 2023. It is now read-only.
Flojoy snake demo#149
Open
izi-on wants to merge 31 commits into
Open
Conversation
Upload app.jpeg pictures and modify sort_vector
…odes into nick/add-basic-nodes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
GAMEPAD node:
The gamepad node uses the hidapi package to read input devices. It scans for a device that has the name "gamepad" in it,
and then it listens to inputs from it. The inputs are described by a list of booleans that is set on the "y" field of the DataContainer of type ordered_pair.
Suggestions: add new type "gamepad input"?
SNAKE_GAME node:
The snake game node takes as an input an ordered_pair DataContainer and reads the "y" field for the list of booleans.
It grabs its previous game state from Small Memory, then with the new inputs calculates its new state and writes it again to Small Memory. The node returns a DataContainer of type 'image' that corresponds to snake game matrix.
LED_MATRIX node:
The LED matrix node takes as an input a DataContainer of type image. Using the following Arduino script:
It communicates via serial to the Arduino that has a WS2812B LED Matrix connected to the 6th digital pin.
Styleguide
Docs
Testing