adding block notation on ArrowNames (#462)
This commit is contained in:
parent
0bdf4b6c68
commit
2ff50b9c0f
@ -254,7 +254,7 @@
|
||||
"serial.delimiters": "Returns the delimiter corresponding string",
|
||||
"serial.onDataReceived": "Registers an event to be fired when one of the delimiter is matched.",
|
||||
"serial.onDataReceived|param|delimiters": "the characters to match received characters against.",
|
||||
"serial.readBuffer": "Reads multiple characters from the rxBuff and fills a user buffer.",
|
||||
"serial.readBuffer": "Reads multiple characters from the receive buffer and fills a user buffer.",
|
||||
"serial.readBuffer|param|length": "default buffer length, eg: 64",
|
||||
"serial.readLine": "Reads a line of text from the serial port.",
|
||||
"serial.readString": "Reads the buffered received data as a string",
|
||||
|
@ -20,6 +20,14 @@
|
||||
"AnalogPin.P7|block": "P7 (write only)",
|
||||
"AnalogPin.P8|block": "P8 (write only)",
|
||||
"AnalogPin.P9|block": "P9 (write only)",
|
||||
"ArrowNames.East|block": "East",
|
||||
"ArrowNames.NorthEast|block": "North East",
|
||||
"ArrowNames.NorthWest|block": "North West",
|
||||
"ArrowNames.North|block": "North",
|
||||
"ArrowNames.SouthEast|block": "South East",
|
||||
"ArrowNames.SouthWest|block": "South West",
|
||||
"ArrowNames.South|block": "South",
|
||||
"ArrowNames.West|block": "West",
|
||||
"BaudRate.BaudRate115200|block": "115200",
|
||||
"BaudRate.BaudRate1200|block": "1200",
|
||||
"BaudRate.BaudRate14400|block": "14400",
|
||||
@ -297,10 +305,12 @@
|
||||
"pins|block": "pins",
|
||||
"serial.delimiters|block": "%del",
|
||||
"serial.onDataReceived|block": "serial|on data received %delimiters=serial_delimiter_conv",
|
||||
"serial.readBuffer|block": "serial|read buffer %length",
|
||||
"serial.readLine|block": "serial|read line",
|
||||
"serial.readString|block": "serial|read string",
|
||||
"serial.readUntil|block": "serial|read until %delimiter=serial_delimiter_conv",
|
||||
"serial.redirect|block": "serial|redirect to|TX %tx|RX %rx|at baud rate %rate",
|
||||
"serial.writeBuffer|block": "serial|write buffer %buffer",
|
||||
"serial.writeLine|block": "serial|write line %text",
|
||||
"serial.writeNumber|block": "serial|write number %value",
|
||||
"serial.writeString|block": "serial|write string %text",
|
||||
|
@ -149,21 +149,21 @@ enum IconNames {
|
||||
}
|
||||
|
||||
enum ArrowNames {
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="North"
|
||||
North = 0,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="North East"
|
||||
NorthEast,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="East"
|
||||
East,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="South East"
|
||||
SouthEast,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="South"
|
||||
South,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="South West"
|
||||
SouthWest,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="West"
|
||||
West,
|
||||
//% blockIdentity=images.arrowNumber
|
||||
//% blockIdentity=images.arrowNumber block="North West"
|
||||
NorthWest,
|
||||
}
|
||||
|
||||
|
4
libs/core/shims.d.ts
vendored
4
libs/core/shims.d.ts
vendored
@ -773,13 +773,15 @@ declare namespace serial {
|
||||
/**
|
||||
* Sends a buffer through Serial connection
|
||||
*/
|
||||
//% blockId=serial_writebuffer block="serial|write buffer %buffer"
|
||||
//% help=serial/write-buffer advanced=true weight=6 shim=serial::writeBuffer
|
||||
function writeBuffer(buffer: Buffer): void;
|
||||
|
||||
/**
|
||||
* Reads multiple characters from the rxBuff and fills a user buffer.
|
||||
* Reads multiple characters from the receive buffer and fills a user buffer.
|
||||
* @param length default buffer length, eg: 64
|
||||
*/
|
||||
//% blockId=serial_readbuffer block="serial|read buffer %length"
|
||||
//% help=serial/read-buffer advanced=true weight=5 shim=serial::readBuffer
|
||||
function readBuffer(length: number): Buffer;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user