From d91da281fd9f7b9627a027fce8dfb10fc6b8025d Mon Sep 17 00:00:00 2001 From: Caitlin Hennessy Date: Fri, 20 Oct 2017 10:27:43 -0700 Subject: [PATCH] Serial (#554) --- editor/extension.ts | 7 ++++--- pxtarget.json | 5 +++++ theme/site/globals/site.variables | 7 +++++++ 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/editor/extension.ts b/editor/extension.ts index d878f9fe..1bdf317c 100644 --- a/editor/extension.ts +++ b/editor/extension.ts @@ -332,11 +332,12 @@ namespace pxt.editor { if (d.reportError) { d.reportError(Util.lf("Please connect your device.")) } else { - console.error(e) + pxt.reportException(e) } } else { - saveHexAsync() - } + return saveHexAsync() + } + return Promise.resolve() }) } diff --git a/pxtarget.json b/pxtarget.json index 54e39fa6..68a2dc9e 100644 --- a/pxtarget.json +++ b/pxtarget.json @@ -203,6 +203,11 @@ "serial": { "nameFilter": "^mbed Serial Port", "log": true, + "useEditor": true, + "editorTheme": { + "graphBackground": "#d9d9d9", + "lineColors": ["#6633cc", "#3891A6", "#3454D1", "#EF767A", "#F46197", "#107C10"] + }, "chromeExtension": "hjcflblhjoglmjjkecamiegdigfkgeni", "vendorId": "0x0d28", "productId": "0x0204", diff --git a/theme/site/globals/site.variables b/theme/site/globals/site.variables index f171146d..7a5c2599 100755 --- a/theme/site/globals/site.variables +++ b/theme/site/globals/site.variables @@ -67,3 +67,10 @@ @blocklyToolboxColor: rgba(0, 0, 0, 0.05); @trashIconColor: @primaryColor; + +/*------------------- + Serial +--------------------*/ + +@serialTextColor: black; +@serialGraphBackground: #d9d9d9; \ No newline at end of file