Add port mappings to support older firmware version 2.0.00.0016 and later as well as newer firmware version 2.0.00.0017 or newer

This commit is contained in:
Kevin Andersen 2019-07-26 14:12:05 -04:00
parent dcccae9656
commit e7634d50fa

View file

@ -93,13 +93,24 @@ const BoostPortFeedback = {
* @readonly * @readonly
* @enum {number} * @enum {number}
*/ */
const BoostPort = {
const BoostPort20000016OrOlder = {
A: 55,
B: 56,
C: 0,
D: 1
};
const BoostPort20000017OrNewer = {
A: 0, A: 0,
B: 1, B: 1,
C: 2, C: 2,
D: 3 D: 3
}; };
// Set default port mapping to support the newer firmware
let BoostPort = BoostPort20000017OrNewer;
/** /**
* Ids for each color sensor value used by the extension. * Ids for each color sensor value used by the extension.
* @readonly * @readonly