Add some descriptive info to serial docs (#704)

* Local commit

* Add some descriptive info to serial docs

* Example typo

* Tiny edit
This commit is contained in:
Galen Nickel
2018-03-09 13:14:24 -08:00
committed by Peli de Halleux
parent 13f20bfcad
commit ddc9aeae35
6 changed files with 53 additions and 36 deletions

View File

@ -5,7 +5,7 @@
//% advanced=true
namespace serial {
/**
* Prints a line of text to the serial
* Print a line of text to the serial port
* @param value to send over serial
*/
//% weight=90
@ -23,7 +23,7 @@ namespace serial {
}
/**
* Prints a numeric value to the serial
* Print a numeric value to the serial port
*/
//% help=serial/write-number
//% weight=89 blockGap=8
@ -33,9 +33,9 @@ namespace serial {
}
/**
* Prints an array of numeric values to the serial as CSV
* Print an array of numeric values as CSV to the serial port
*/
//% help=serial-write-numbers
//% help=serial/write-numbers
//% weight=86
//% blockId=serial_writenumbers block="serial|write numbers %values"
export function writeNumbers(values: number[]): void {
@ -48,7 +48,7 @@ namespace serial {
}
/**
* Writes a ``name: value`` pair line to the serial.
* Write a name:value pair as a line to the serial port.
* @param name name of the value stream, eg: x
* @param value to write
*/
@ -60,7 +60,7 @@ namespace serial {
}
/**
* Reads a line of text from the serial port.
* Read a line of text from the serial port.
*/
//% help=serial/read-line
//% blockId=serial_read_line block="serial|read line"
@ -70,7 +70,7 @@ namespace serial {
}
/**
* Returns the delimiter corresponding string
* Return the corresponding delimiter string
*/
//% blockId="serial_delimiter_conv" block="%del"
//% weight=1 blockHidden=true