Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'selectMode' was not declared in this scope; did you mean 'select' #11

Open
rklxmok opened this issue Oct 25, 2024 · 0 comments
Open

'selectMode' was not declared in this scope; did you mean 'select' #11

rklxmok opened this issue Oct 25, 2024 · 0 comments

Comments

@rklxmok
Copy link

rklxmok commented Oct 25, 2024

Excuse me for my ignorance, I am new to arduino. I have added the libraries and when I verify the sketch I just get a ton of not declared errors

`In file included from c:\Users\Administrator\Documents\Arduino\libraries\usb-keyboard/usb-keyboard.h:4,
from C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:1:
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino: In function 'int mode_select(char, int)':
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:9:24: error: 'selectMode' was not declared in this scope; did you mean 'select'?
9 | SerialPrintf("%s", selectMode);
| ^~~~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:9:5: note: in expansion of macro 'SerialPrintf'
9 | SerialPrintf("%s", selectMode);
| ^~~~~~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:19:59: error: 'mode_strings' was not declared in this scope
19 | } else if (peekChar > '0' && peekChar < ('0'+sizeof(mode_strings)/sizeof(char*))) {
| ^~~~~~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino: In function 'void usb_send_key(uint16_t, uint16_t)':
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:189:12: error: 'Keyboard' was not declared in this scope
189 | if (mod) Keyboard.press(mod);
| ^~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:190:3: error: 'Keyboard' was not declared in this scope
190 | Keyboard.press(key);
| ^~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino: In function 'void command_mode(char)':
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:226:9: error: 'kbd_buff' was not declared in this scope
226 | kbd_buff[kbd_idx] = '\0';
| ^~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:226:18: error: 'kbd_idx' was not declared in this scope
226 | kbd_buff[kbd_idx] = '\0';
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:228:9: error: 'crs_idx' was not declared in this scope
228 | crs_idx = kbd_idx;
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:262:5: error: 'crs_idx' was not declared in this scope
262 | crs_idx = kbd_idx;
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:262:15: error: 'kbd_idx' was not declared in this scope
262 | crs_idx = kbd_idx;
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:264:14: error: 'kbd_idx' was not declared in this scope
264 | } else if (kbd_idx >= KBD_BUFFSZ-1) {
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:269:9: error: 'crs_idx' was not declared in this scope
269 | if (crs_idx>kbd_idx) crs_idx = kbd_idx;
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:270:5: error: 'kbd_buff' was not declared in this scope
270 | kbd_buff[crs_idx++] = in_ascii;
| ^~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:270:14: error: 'crs_idx' was not declared in this scope
270 | kbd_buff[crs_idx++] = in_ascii;
| ^~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino: In function 'void c_unicode(char*, bool)':
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:443:10: error: 'keyboard_leds' was not declared in this scope
443 | if (!keyboard_leds & (1<<0))
| ^~~~~~~~~~~~~
C:\Users\Administrator\Documents\Arduino\keyboard2\keyboard2.ino:445:5: error: 'Keyboard' was not declared in this scope
445 | Keyboard.press(MODIFIERKEY_ALT);
| ^~~~~~~~

exit status 1

Compilation error: 'selectMode' was not declared in this scope; did you mean 'select'?`

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

No branches or pull requests

1 participant