Skip to content

Conversation

@Tnks2U
Copy link
Collaborator

@Tnks2U Tnks2U commented Feb 20, 2025

entrylabs/entry-hw#807

신규기기 1종 추가
기존 기기 3종 수정

전체 4종 중 3종은 웹연결만 변경

@Tnks2U Tnks2U self-assigned this Feb 20, 2025
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit

eslint

⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

let time = script.getNumberValue('TIME', script);


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

let time = script.getNumberValue('TIME', script);


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

let time = script.getNumberValue('TIME', script);


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

let time = script.getNumberValue('TIME', script);


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.


⚠️ [eslint] <prefer-template> reported by reviewdog 🐶
Unexpected string concatenation.


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const commandBuffer = Buffer.from(command, 'utf8');


⚠️ [eslint] <radix> reported by reviewdog 🐶
Missing radix parameter.

const value = parseInt(script.getNumberValue('VALUE', script));


⚠️ [eslint] <radix> reported by reviewdog 🐶
Missing radix parameter.

const time = parseInt(script.getNumberValue('TIME', script)); // ms


⚠️ [eslint] <radix> reported by reviewdog 🐶
Missing radix parameter.

const turnValue = parseInt(script.getNumberValue('TURN_VALUE', script));


⚠️ [eslint] <radix> reported by reviewdog 🐶
Missing radix parameter.

const turnTime = parseInt(script.getNumberValue('TURN_TIME', script)); // ms


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.


⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.


⚠️ [eslint] <max-len> reported by reviewdog 🐶
This line has a length of 114. Maximum allowed is 100.

'화면에 [게임/캐릭터]중 특정 아이콘을 표시할 위치와 크기를 설정\nX좌표: -160 ~ 160\nY좌표: -120 ~ 120\n크기: 0 ~ 200',


⚠️ [eslint] <max-len> reported by reviewdog 🐶
This line has a length of 176. Maximum allowed is 100.

'Set the position and size of a specific icon in [game/character] on the screen\nX coordinate: -160 ~ 160\nY coordinate: -120 ~ 120\nSize: 0 ~ 200',


🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ··

robotis_icon_game_character_44: 'Running Person 2',


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'iconNum' is never reassigned. Use 'const' instead.

let iconNum = script.getField('ICON', script);


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_instruction' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_instruction' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_address' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_address' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_length' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_length' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_sendqueue' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_sendqueue' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_instruction' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_address' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_length' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'packets' is never reassigned. Use 'const' instead.


🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ABC with abc

this.robotisBuffer.push([INST_WRITE, 1010, 2, 0xABC2]); // 아래 20번 모드 진입후 코알라 얼굴로 변경준비


⚠️ [eslint] <max-len> reported by reviewdog 🐶
This line has a length of 114. Maximum allowed is 100.

'화면에 [게임/캐릭터]중 특정 아이콘을 표시할 위치와 크기를 설정\nX좌표: -160 ~ 160\nY좌표: -120 ~ 120\n크기: 0 ~ 200',


⚠️ [eslint] <max-len> reported by reviewdog 🐶
This line has a length of 176. Maximum allowed is 100.

'Set the position and size of a specific icon in [game/character] on the screen\nX coordinate: -160 ~ 160\nY coordinate: -120 ~ 120\nSize: 0 ~ 200',


🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ························

robotis_icon_game_character_44: 'Running Person 2',


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'iconNum' is never reassigned. Use 'const' instead.

let iconNum = script.getField('ICON', script);


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_instruction' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_instruction' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_address' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_address' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_length' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_length' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_sendqueue' is not in camel case.


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'data_sendqueue' is never reassigned. Use 'const' instead.


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_instruction' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_address' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_length' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <camelcase> reported by reviewdog 🐶
Identifier 'data_value' is not in camel case.

[data_instruction, data_address, data_length, data_value],


⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'packets' is never reassigned. Use 'const' instead.


🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Delete ················


🚫 [eslint] <prettier/prettier> reported by reviewdog 🐶
Replace ABC with abc

this.robotisBuffer.push([INST_WRITE, 1010, 2, 0xABC1]); // 아래 20번 모드 진입후 꼭두 얼굴로 변경준비

i--;
}

if (chunk === SOME_EXPECTED_RESPONSE) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'SOME_EXPECTED_RESPONSE' is not defined.

const queryString = [];
const readablePorts = this.readablePorts;

const commandStr = Entry.hw.sendQueue['COMMAND'];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <dot-notation> reported by reviewdog 🐶
["COMMAND"] is better written in dot notation.

Suggested change
const commandStr = Entry.hw.sendQueue['COMMAND'];
const commandStr = Entry.hw.sendQueue.COMMAND;

for (let i = 0; i < commandStr.length; i++) {
queryString.push(commandStr.charCodeAt(i));
}
delete Entry.hw.sendQueue['COMMAND'];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <dot-notation> reported by reviewdog 🐶
["COMMAND"] is better written in dot notation.

Suggested change
delete Entry.hw.sendQueue['COMMAND'];
delete Entry.hw.sendQueue.COMMAND;

Cocodron_Dron_Controller_land: 'Landing',
Cocodron_Dron_Controller_emergency: 'Emergency Stop',
Cocodron_Dron_Controller_headless: 'Headless Mode',
//Cocodron_Dron_Controller_move_drone: 'Move joystick %1 in %2 direction by %3 for %4 ms',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <max-len> reported by reviewdog 🐶
This line has a length of 114. Maximum allowed is 100.

isNotFor: ['cocodroncontrollerLite'],
func(sprite, script) {
const command = 'mapping_start';
const commandBuffer = Buffer.from(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

const command = `down ${stick} ${time}\r`;
console.log('Constructed command:', command);

const commandBuffer = Buffer.from(command, 'utf8');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

isNotFor: ['cocodroncontrollerLite'],
func(sprite, script) {
let stick = script.getNumberValue('STICK', script) * 10;
let time = script.getNumberValue('TIME', script);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

Suggested change
let time = script.getNumberValue('TIME', script);
const time = script.getNumberValue('TIME', script);

}

const command = `cw ${stick} ${time}\r`;
const commandBuffer = Buffer.from(command, 'utf8');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

isNotFor: ['cocodroncontrollerLite'],
func(sprite, script) {
let stick = script.getNumberValue('STICK', script) * 10;
let time = script.getNumberValue('TIME', script);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <prefer-const> reported by reviewdog 🐶
'time' is never reassigned. Use 'const' instead.

Suggested change
let time = script.getNumberValue('TIME', script);
const time = script.getNumberValue('TIME', script);

}

const command = `ccw ${stick} ${time}\r`;
const commandBuffer = Buffer.from(command, 'utf8');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ [eslint] <no-undef> reported by reviewdog 🐶
'Buffer' is not defined.

@Tnks2U Tnks2U merged commit 265107e into develop Feb 25, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants