diff --git a/libs/core/_locales/core-jsdoc-strings.json b/libs/core/_locales/core-jsdoc-strings.json index ed8d2185..5aea2b8b 100644 --- a/libs/core/_locales/core-jsdoc-strings.json +++ b/libs/core/_locales/core-jsdoc-strings.json @@ -270,14 +270,14 @@ "basic.showCompass|param|interval": "the amount of time (milliseconds) to show the needle. Default is 600.", "basic.showIcon": "Draws the selected icon on the LED screen", "basic.showIcon|param|icon": "the predefined icon id", - "basic.showIcon|param|interval": "the amount of time (milliseconds) to show the icon. Default is 600.", + "basic.showIcon|param|interval": "the amount of time (milliseconds) to block the LED Matrix for showing the icon. Default is 200.", "basic.showLeds": "Draws an image on the LED screen.", "basic.showLeds|param|interval": "time in milliseconds to pause after drawing", "basic.showLeds|param|leds": "the pattern of LED to turn on/off", "basic.showNumber": "Scroll a number on the screen. If the number fits on the screen (i.e. is a single digit), do not scroll.", - "basic.showNumber|param|interval": "speed of scroll; eg: 150, 100, 200, -100", + "basic.showNumber|param|interval": "speed of scroll; eg: 50, 100, 150, 200", "basic.showString": "Display text on the display, one character at a time. If the string fits on the screen (i.e. is one letter), does not scroll.", - "basic.showString|param|interval": "how fast to shift characters; eg: 150, 100, 200, -100", + "basic.showString|param|interval": "how fast to shift characters; eg: 50, 100, 150, 200", "basic.showString|param|text": "the text to scroll on the screen, eg: \"hi!\"", "basic.turnRgbLedOff": "Sets the color on the build-in LED. Set to 0 to turn off.", "console": "Reading and writing data to the console output.", diff --git a/libs/core/basic.cpp b/libs/core/basic.cpp index b415c315..de787576 100644 --- a/libs/core/basic.cpp +++ b/libs/core/basic.cpp @@ -25,7 +25,7 @@ namespace basic { /** * Display text on the display, one character at a time. If the string fits on the screen (i.e. is one letter), does not scroll. * @param text the text to scroll on the screen, eg: "hi!" - * @param interval how fast to shift characters; eg: 150, 100, 200, -100 + * @param interval how fast to shift characters; eg: 50, 100, 150, 200 */ //% help=basic/show-string //% weight=100 blockGap=16 @@ -35,9 +35,9 @@ namespace basic { //% parts="ledmatrix" //% text.shadowOptions.toString=true //% expandableArgumentMode="toggle" - //% interval.defl=150 + //% interval.defl=80 //% group="LED matrix" - void showString(String text, int interval = 150) { + void showString(String text, int interval = 80) { if (interval <= 0) interval = 1; int l = text ? text->getUTF8Size() : 0; diff --git a/libs/core/basic.ts b/libs/core/basic.ts index e812f6bc..b7dc96ad 100644 --- a/libs/core/basic.ts +++ b/libs/core/basic.ts @@ -43,7 +43,7 @@ namespace basic { /** * Scroll a number on the screen. If the number fits on the screen (i.e. is a single digit), do not scroll. - * @param interval speed of scroll; eg: 150, 100, 200, -100 + * @param interval speed of scroll; eg: 50, 100, 150, 200 */ //% help=basic/show-number //% weight=95 @@ -52,7 +52,7 @@ namespace basic { //% async //% parts="ledmatrix" //% expandableArgumentMode="toggle" - //% interval.defl=150 + //% interval.defl=80 //% group="LED matrix" export function showNumber(value: number, interval?: number) { showString(Math.roundWithPrecision(value, 2).toString(), interval); diff --git a/libs/core/icons.ts b/libs/core/icons.ts index 658343ab..c7bf1190 100644 --- a/libs/core/icons.ts +++ b/libs/core/icons.ts @@ -97,7 +97,7 @@ namespace basic { /** * Draws the selected icon on the LED screen * @param icon the predefined icon id - * @param interval the amount of time (milliseconds) to show the icon. Default is 600. + * @param interval the amount of time (milliseconds) to block the LED Matrix for showing the icon. Default is 200. */ //% weight=90 blockGap=8 //% blockId=basic_show_icon @@ -109,9 +109,9 @@ namespace basic { //% icon.fieldOptions.width="380" //% icon.fieldOptions.maxRows=4 //% expandableArgumentMode="toggle" - //% interval.defl=600 + //% interval.defl=200 //% group="LED matrix" - export function showIcon(icon: IconNames, interval = 600) { + export function showIcon(icon: IconNames, interval = 200) { let res = images.iconImage(icon) res.showImage(0, interval) } diff --git a/libs/core/shims.d.ts b/libs/core/shims.d.ts index 0947a22e..431e94c9 100644 --- a/libs/core/shims.d.ts +++ b/libs/core/shims.d.ts @@ -149,7 +149,7 @@ declare namespace basic { /** * Display text on the display, one character at a time. If the string fits on the screen (i.e. is one letter), does not scroll. * @param text the text to scroll on the screen, eg: "hi!" - * @param interval how fast to shift characters; eg: 150, 100, 200, -100 + * @param interval how fast to shift characters; eg: 50, 100, 150, 200 */ //% help=basic/show-string //% weight=100 blockGap=16 @@ -160,7 +160,7 @@ declare namespace basic { //% text.shadowOptions.toString=true //% expandableArgumentMode="toggle" //% - //% group="LED matrix" interval.defl=150 shim=basic::showString + //% group="LED matrix" interval.defl=80 shim=basic::showString function showString(text: string, interval?: int32): void; /**