From 48ff3bd3d62cf4d1d86438e817808fd204e6266a Mon Sep 17 00:00:00 2001 From: Jakob Stendahl Date: Fri, 7 Sep 2018 10:43:15 +0200 Subject: :zap: Remove online deps from neo_ide --- package-lock.json | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'package-lock.json') diff --git a/package-lock.json b/package-lock.json index f12881a..ac5f897 100644 --- a/package-lock.json +++ b/package-lock.json @@ -4,6 +4,12 @@ "lockfileVersion": 1, "requires": true, "dependencies": { + "@fortawesome/fontawesome-free": { + "version": "5.3.1", + "resolved": "https://registry.npmjs.org/@fortawesome/fontawesome-free/-/fontawesome-free-5.3.1.tgz", + "integrity": "sha512-jt6yi7iZVtkY9Jc6zFo+G2vqL4M81pb3IA3WmnnDt9ci7Asz+mPg4gbZL8pjx0nGFBsG0Bmd7BjU9IQkebqxFA==", + "dev": true + }, "@webassemblyjs/ast": { "version": "1.5.13", "resolved": "https://registry.npmjs.org/@webassemblyjs/ast/-/ast-1.5.13.tgz", @@ -3872,6 +3878,12 @@ "resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz", "integrity": "sha1-R+Y/evVa+m+S4VAOaQ64uFKcCZo=" }, + "jquery": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/jquery/-/jquery-3.3.1.tgz", + "integrity": "sha512-Ubldcmxp5np52/ENotGxlLe6aGMvmF4R8S6tZjsP6Knsaxd/xp3Zrh50cG93lR6nPXyUFwzN3ZSOQI0wRJNdGg==", + "dev": true + }, "js-base64": { "version": "2.4.5", "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-2.4.5.tgz", -- cgit v1.2.3 From ec3b7655b3b265cfe0086d7ad20ffa28cfa8629d Mon Sep 17 00:00:00 2001 From: jakobst1n Date: Tue, 4 Dec 2018 16:19:02 +0000 Subject: :sparkles: Matrix is now setting itself up correctly Have bypassed a try-catch for now --- package-lock.json | 44 +++++++++++++++------- .../pythonSupportFiles/LuxcenaNeo/Matrix.py | 8 ++++ .../pythonSupportFiles/LuxcenaNeo/Strip.py | 12 +++--- 3 files changed, 45 insertions(+), 19 deletions(-) (limited to 'package-lock.json') diff --git a/package-lock.json b/package-lock.json index ac5f897..8b1b5de 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2651,7 +2651,8 @@ "ansi-regex": { "version": "2.1.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "aproba": { "version": "1.2.0", @@ -2672,12 +2673,14 @@ "balanced-match": { "version": "1.0.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "brace-expansion": { "version": "1.1.11", "bundled": true, "dev": true, + "optional": true, "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -2692,17 +2695,20 @@ "code-point-at": { "version": "1.1.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "concat-map": { "version": "0.0.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "console-control-strings": { "version": "1.1.0", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "core-util-is": { "version": "1.0.2", @@ -2819,7 +2825,8 @@ "inherits": { "version": "2.0.3", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "ini": { "version": "1.3.5", @@ -2831,6 +2838,7 @@ "version": "1.0.0", "bundled": true, "dev": true, + "optional": true, "requires": { "number-is-nan": "^1.0.0" } @@ -2845,6 +2853,7 @@ "version": "3.0.4", "bundled": true, "dev": true, + "optional": true, "requires": { "brace-expansion": "^1.1.7" } @@ -2852,12 +2861,14 @@ "minimist": { "version": "0.0.8", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "minipass": { "version": "2.2.4", "bundled": true, "dev": true, + "optional": true, "requires": { "safe-buffer": "^5.1.1", "yallist": "^3.0.0" @@ -2876,6 +2887,7 @@ "version": "0.5.1", "bundled": true, "dev": true, + "optional": true, "requires": { "minimist": "0.0.8" } @@ -2956,7 +2968,8 @@ "number-is-nan": { "version": "1.0.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "object-assign": { "version": "4.1.1", @@ -2968,6 +2981,7 @@ "version": "1.4.0", "bundled": true, "dev": true, + "optional": true, "requires": { "wrappy": "1" } @@ -3053,7 +3067,8 @@ "safe-buffer": { "version": "5.1.1", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "safer-buffer": { "version": "2.1.2", @@ -3089,6 +3104,7 @@ "version": "1.0.2", "bundled": true, "dev": true, + "optional": true, "requires": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -3108,6 +3124,7 @@ "version": "3.0.1", "bundled": true, "dev": true, + "optional": true, "requires": { "ansi-regex": "^2.0.0" } @@ -3151,12 +3168,14 @@ "wrappy": { "version": "1.0.2", "bundled": true, - "dev": true + "dev": true, + "optional": true }, "yallist": { "version": "3.0.2", "bundled": true, - "dev": true + "dev": true, + "optional": true } } }, @@ -4383,8 +4402,7 @@ "monaco-editor": { "version": "0.14.3", "resolved": "https://registry.npmjs.org/monaco-editor/-/monaco-editor-0.14.3.tgz", - "integrity": "sha512-RhaO4xXmWn/p0WrkEOXe4PoZj6xOcvDYjoAh0e1kGUrQnP1IOpc0m86Ceuaa2CLEMDINqKijBSmqhvBQnsPLHQ==", - "dev": true + "integrity": "sha512-RhaO4xXmWn/p0WrkEOXe4PoZj6xOcvDYjoAh0e1kGUrQnP1IOpc0m86Ceuaa2CLEMDINqKijBSmqhvBQnsPLHQ==" }, "move-concurrently": { "version": "1.0.1", diff --git a/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Matrix.py b/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Matrix.py index 0986b45..4a93247 100644 --- a/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Matrix.py +++ b/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Matrix.py @@ -37,6 +37,14 @@ class Matrix: def get(self, x, y): """ Return the value of a place in the matrix given x and y coordinates """ return self.matrix[y][x] + + def dump(self): + for y in self.matrix: + thisYLine = "" + for x in y: + thisYLine += str(x) + ( ' ' * (5 - len(str(x))) ) + print(thisYLine) + if __name__ == "__main__": testMatrix = Matrix( diff --git a/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Strip.py b/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Strip.py index e671d42..4856076 100644 --- a/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Strip.py +++ b/src/compileAndRun/pythonSupportFiles/LuxcenaNeo/Strip.py @@ -38,11 +38,11 @@ class Strip: self.strip.show() # Setup matrix - pixelMatrix = Matrix(self.SEGMENTS, stripConf["matrix"]) - try: - print("TESTING") - except: - print("Something went wrong while setting up your self-defined matrix.") + #try: + self.pixelMatrix = Matrix(self.SEGMENTS, stripConf["matrix"]) + self.pixelMatrix.dump() + #except: + # print("Something went wrong while setting up your self-defined matrix.") def show(self): """Update the display with the data from the LED buffer.""" @@ -76,7 +76,7 @@ class Strip: """Set a whole segment to the provided red, green and blue color. Each color component should be a value from 0 to 255 (where 0 is the lowest intensity and 255 is the highest intensity).""" - for n in getSegmentRange(self.segments, segment): + for n in getSegmentRange(self.SEGMENTS, segment): self.strip.setPixelColor(n, Color(red, green, blue, white)) def setBrightness(self, brightness): -- cgit v1.2.3