add enum baudrates (#376)
* add enum baudrates fixes perceived limitation of available baud rates https://github.com/Microsoft/pxt/issues/1752 * correct block comment * comma correction and remove trailing space That will teach me just to do cut and paste via github web interface :( * without running pxt buildtarget
This commit is contained in:
parent
1f2027d0f9
commit
3f25c2a170
@ -21,6 +21,15 @@
|
||||
"AnalogPin.P8|block": "P8 (write only)",
|
||||
"AnalogPin.P9|block": "P9 (write only)",
|
||||
"BaudRate.BaudRate115200|block": "115200",
|
||||
"BaudRate.BaudRate1200|block": "1200",
|
||||
"BaudRate.BaudRate14400|block": "14400",
|
||||
"BaudRate.BaudRate19200|block": "19200",
|
||||
"BaudRate.BaudRate2400|block": "2400",
|
||||
"BaudRate.BaudRate28800|block": "28800",
|
||||
"BaudRate.BaudRate300|block": "300",
|
||||
"BaudRate.BaudRate38400|block": "38400",
|
||||
"BaudRate.BaudRate4800|block": "4800",
|
||||
"BaudRate.BaudRate57600|block": "57600",
|
||||
"BaudRate.BaudRate9600|block": "9600",
|
||||
"BeatFraction.Breve|block": "4",
|
||||
"BeatFraction.Double|block": "2",
|
||||
|
18
libs/core/enums.d.ts
vendored
18
libs/core/enums.d.ts
vendored
@ -443,8 +443,26 @@ declare namespace led {
|
||||
declare enum BaudRate {
|
||||
//% block=115200
|
||||
BaudRate115200 = 115200,
|
||||
//% block=57600
|
||||
BaudRate57600 = 57600,
|
||||
//% block=38400
|
||||
BaudRate38400 = 38400,
|
||||
//% block=28800
|
||||
BaudRate28800 = 28800,
|
||||
//% block=19200
|
||||
BaudRate19200 = 19200,
|
||||
//% block=14400
|
||||
BaudRate14400 = 14400,
|
||||
//% block=9600
|
||||
BaudRate9600 = 9600,
|
||||
//% block=4800
|
||||
BaudRate4800 = 4800,
|
||||
//% block=2400
|
||||
BaudRate2400 = 2400,
|
||||
//% block=1200
|
||||
BaudRate1200 = 1200,
|
||||
//% block=300
|
||||
BaudRate300 = 300,
|
||||
}
|
||||
|
||||
|
||||
|
@ -15,8 +15,26 @@ enum SerialPin {
|
||||
enum BaudRate {
|
||||
//% block=115200
|
||||
BaudRate115200 = 115200,
|
||||
//% block=57600
|
||||
BaudRate57600 = 57600,
|
||||
//% block=38400
|
||||
BaudRate38400 = 38400,
|
||||
//% block=28800
|
||||
BaudRate28800 = 28800,
|
||||
//% block=19200
|
||||
BaudRate19200 = 19200,
|
||||
//% block=14400
|
||||
BaudRate14400 = 14400,
|
||||
//% block=9600
|
||||
BaudRate9600 = 9600
|
||||
BaudRate9600 = 9600,
|
||||
//% block=4800
|
||||
BaudRate4800 = 4800,
|
||||
//% block=2400
|
||||
BaudRate2400 = 2400,
|
||||
//% block=1200
|
||||
BaudRate1200 = 1200,
|
||||
//% block=300
|
||||
BaudRate300 = 300
|
||||
};
|
||||
|
||||
enum Delimiters {
|
||||
|
Loading…
Reference in New Issue
Block a user