From 10d44b97cc9613f63a44a13ea9230b3128c3819c Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Tue, 26 Apr 2016 10:29:05 -0700 Subject: [PATCH 1/3] more serial infos --- libs/microbit/serial.cpp | 2 +- libs/microbit/serial.ts | 3 ++- libs/microbit/shims.d.ts | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/libs/microbit/serial.cpp b/libs/microbit/serial.cpp index b3aa6a8c..bdd15adb 100644 --- a/libs/microbit/serial.cpp +++ b/libs/microbit/serial.cpp @@ -15,7 +15,7 @@ namespace serial { /** * Sends a piece of text through Serial connection. */ - //% + //% blockId=serial_writestring block="serial write %text" void writeString(StringData *text) { uBit.serial.send(ManagedString(text)); } diff --git a/libs/microbit/serial.ts b/libs/microbit/serial.ts index 326c7369..0649cded 100644 --- a/libs/microbit/serial.ts +++ b/libs/microbit/serial.ts @@ -8,7 +8,7 @@ namespace serial { * @param value to send over serial */ //% help=serial/write-line - //% blockId=serial_writeline block="serial|write %text" + //% blockId=serial_writeline block="serial|write line %text" export function writeLine(text: string): void { writeString(text); writeString("\r\n"); @@ -17,6 +17,7 @@ namespace serial { /** * Prints a numeric value to the serial */ + //% blockId=serial_writenumber block="serial|write number %value" export function writeNumber(value: number): void { writeString(value.toString()); } diff --git a/libs/microbit/shims.d.ts b/libs/microbit/shims.d.ts index 4f60205a..7c8abbb3 100644 --- a/libs/microbit/shims.d.ts +++ b/libs/microbit/shims.d.ts @@ -528,7 +528,7 @@ declare namespace serial { /** * Sends a piece of text through Serial connection. */ - //% shim=serial::writeString + //% blockId=serial_writestring block="serial write %text" shim=serial::writeString function writeString(text: string): void; } From 17eb36a8dc4629be1a9a03d551754b8b39cd2def Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Tue, 26 Apr 2016 10:43:49 -0700 Subject: [PATCH 2/3] Bump pxt-core to 0.2.99 --- package.json | 64 ++++++++++++++++++++++++++-------------------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/package.json b/package.json index f12e5a8f..f743f07b 100644 --- a/package.json +++ b/package.json @@ -1,34 +1,34 @@ { - "name": "pxt-microbit", - "version": "0.2.90", - "description": "BBC micro:bit target for PXT", - "keywords": [ - "JavaScript", - "education", - "microbit" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/Microsoft/pxt-microbit.git" - }, - "author": "", - "license": "MIT", - "homepage": "https://github.com/Microsoft/pxt-microbit#readme", - "files": [ - "README.md", - "pxtarget.json", - "built/*.js", - "built/*.json", - "built/*.d.ts", - "sim/public", - "docs/*.md", - "docs/*/*.md", - "docs/*/*/*.md" - ], - "devDependencies": { - "typescript": "^1.8.7" - }, - "dependencies": { - "pxt-core": "0.2.98" - } + "name": "pxt-microbit", + "version": "0.2.90", + "description": "BBC micro:bit target for PXT", + "keywords": [ + "JavaScript", + "education", + "microbit" + ], + "repository": { + "type": "git", + "url": "git+https://github.com/Microsoft/pxt-microbit.git" + }, + "author": "", + "license": "MIT", + "homepage": "https://github.com/Microsoft/pxt-microbit#readme", + "files": [ + "README.md", + "pxtarget.json", + "built/*.js", + "built/*.json", + "built/*.d.ts", + "sim/public", + "docs/*.md", + "docs/*/*.md", + "docs/*/*/*.md" + ], + "devDependencies": { + "typescript": "^1.8.7" + }, + "dependencies": { + "pxt-core": "0.2.99" + } } From e37ac1a1d77ffaccf104a3c424ab652426bc4854 Mon Sep 17 00:00:00 2001 From: Peli de Halleux Date: Tue, 26 Apr 2016 10:43:51 -0700 Subject: [PATCH 3/3] 0.2.91 --- package.json | 64 ++++++++++++++++++++++++++-------------------------- 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/package.json b/package.json index f743f07b..cab56e15 100644 --- a/package.json +++ b/package.json @@ -1,34 +1,34 @@ { - "name": "pxt-microbit", - "version": "0.2.90", - "description": "BBC micro:bit target for PXT", - "keywords": [ - "JavaScript", - "education", - "microbit" - ], - "repository": { - "type": "git", - "url": "git+https://github.com/Microsoft/pxt-microbit.git" - }, - "author": "", - "license": "MIT", - "homepage": "https://github.com/Microsoft/pxt-microbit#readme", - "files": [ - "README.md", - "pxtarget.json", - "built/*.js", - "built/*.json", - "built/*.d.ts", - "sim/public", - "docs/*.md", - "docs/*/*.md", - "docs/*/*/*.md" - ], - "devDependencies": { - "typescript": "^1.8.7" - }, - "dependencies": { - "pxt-core": "0.2.99" - } + "name": "pxt-microbit", + "version": "0.2.91", + "description": "BBC micro:bit target for PXT", + "keywords": [ + "JavaScript", + "education", + "microbit" + ], + "repository": { + "type": "git", + "url": "git+https://github.com/Microsoft/pxt-microbit.git" + }, + "author": "", + "license": "MIT", + "homepage": "https://github.com/Microsoft/pxt-microbit#readme", + "files": [ + "README.md", + "pxtarget.json", + "built/*.js", + "built/*.json", + "built/*.d.ts", + "sim/public", + "docs/*.md", + "docs/*/*.md", + "docs/*/*/*.md" + ], + "devDependencies": { + "typescript": "^1.8.7" + }, + "dependencies": { + "pxt-core": "0.2.99" + } }