Skip to content

Commit

Permalink
feat: basic cli echo
Browse files Browse the repository at this point in the history
  • Loading branch information
chmelevskij committed Jan 21, 2024
1 parent e9180c7 commit 09d2587
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/js/msp/MSPCodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,7 @@ const MSPCodes = {
MSP2_GET_LED_STRIP_CONFIG_VALUES: 0x3008,
MSP2_SET_LED_STRIP_CONFIG_VALUES: 0x3009,
MSP2_SENSOR_CONFIG_ACTIVE: 0x300A,
MSP2_CLI: 0x300B,

// MSP2_GET_TEXT and MSP2_SET_TEXT variable types
PILOT_NAME: 1,
Expand Down
5 changes: 5 additions & 0 deletions src/js/msp/MSPHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -1607,6 +1607,11 @@ MspHelper.prototype.process_data = function(dataHandler) {
case MSPCodes.MSP2_SEND_DSHOT_COMMAND:
console.log('DSHOT command sent');
break;
case MSPCodes.MSP2_CLI:
const decoder = new TextDecoder();
console.log("CLI response: ");
console.log(decoder.decode(data));
break;

case MSPCodes.MSP_MULTIPLE_MSP:

Expand Down

0 comments on commit 09d2587

Please sign in to comment.