# 'JOYSTICK\_' 32-FUNCTION-BUTTON-BOX-master Error uploading sketch

**URL:** <https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005>\
**Category:** IDE 1.x\
**Created:** [March 24, 2022, 3:41pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005 "2022-03-24T15:41:34Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![hemo84](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@hemo84](https://forum.arduino.cc/u/hemo84)\
**Post date:** [March 24, 2022, 3:41pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/1 "2022-03-24T15:41:34Z")

</div>

Hello Friends,  
am new here. am trying to upload a popular sketch "from internet" to my Arduino Micro.  
first it give this error "Keypad.h" and i searched here and found that i have to download it to library. i did and it was solved.  
then i faced another error "Joystick\_ Joystick(JOYSTICK\_DEFAULT\_REPORT\_ID,  
JOYSTICK\_TYPE\_JOYSTICK, 32, 0,  
false, false, false, false, false, false,  
false, false, false, false, false);"  
i downloaded all joystick from library but it didn't work. I also downloaded this joystick library and i didn't work too.  
 ![](https://europe1.discourse-cdn.com/arduino/optimized/4X/a/3/c/a3c6743a795ae82a2056fdbfae312860cd2ccfad_2_690x345.png)

### [MHeironimus/ArduinoJoystickLibrary](https://github.com/MHeironimus/ArduinoJoystickLibrary)

An Arduino library that adds one or more joysticks to the list of HID devices an Arduino Leonardo or Arduino Micro can support. - MHeironimus/ArduinoJoystickLibrary  
here is the error.  
thanks in advance.

\</\> Arduino: 1.8.19 (Windows Store 1.8.57.0) (Windows 10), Board: "Arduino Micro"

ARDUINO\_BUTTON\_BOXV2:97:1: error: 'Joystick\_' does not name a type; did you mean 'Joystick'?

Joystick\_ Joystick(JOYSTICK\_DEFAULT\_REPORT\_ID,

^ ~~~~~~~~

Joystick

C:\Users\Ibrahim\Desktop\ARDUINO\_BUTTON\_BOXV2\ARDUINO\_BUTTON\_BOXV2.ino: In function 'void setup()':

ARDUINO\_BUTTON\_BOXV2:103:11: error: expected unqualified-id before '.' token

Joystick.begin();

```
       ^

```

C:\Users\Ibrahim\Desktop\ARDUINO\_BUTTON\_BOXV2\ARDUINO\_BUTTON\_BOXV2.ino: In function 'void CheckAllButtons()':

ARDUINO\_BUTTON\_BOXV2:124:39: error: expected unqualified-id before '.' token

```
                           Joystick.setButton(buttbx.key[i].kchar, 1);

                                   ^

```

ARDUINO\_BUTTON\_BOXV2:128:39: error: expected unqualified-id before '.' token

```
                           Joystick.setButton(buttbx.key[i].kchar, 0);

                                   ^

```

C:\Users\Ibrahim\Desktop\ARDUINO\_BUTTON\_BOXV2\ARDUINO\_BUTTON\_BOXV2.ino: In function 'void CheckAllEncoders()':

ARDUINO\_BUTTON\_BOXV2:159:15: error: expected unqualified-id before '.' token

```
   Joystick.setButton(rotaries[i].ccwchar, 1); delay(50); Joystick.setButton(rotaries[i].ccwchar, 0);

           ^

```

ARDUINO\_BUTTON\_BOXV2:159:70: error: expected unqualified-id before '.' token

```
   Joystick.setButton(rotaries[i].ccwchar, 1); delay(50); Joystick.setButton(rotaries[i].ccwchar, 0);

                                                                  ^

```

ARDUINO\_BUTTON\_BOXV2:162:15: error: expected unqualified-id before '.' token

```
   Joystick.setButton(rotaries[i].cwchar, 1); delay(50); Joystick.setButton(rotaries[i].cwchar, 0);

           ^

```

ARDUINO\_BUTTON\_BOXV2:162:69: error: expected unqualified-id before '.' token

```
   Joystick.setButton(rotaries[i].cwchar, 1); delay(50); Joystick.setButton(rotaries[i].cwchar, 0);

                                                                 ^

```

Multiple libraries were found for "Joystick.h"

Used: C:\Users\Ibrahim\Documents\Arduino\libraries\Joystick

Not used: C:\Users\Ibrahim\Documents\Arduino\libraries\ArduinoJoystickLibrary-master

Not used: C:\Users\Ibrahim\Documents\Arduino\libraries\AxisJoystick

exit status 1

'Joystick\_' does not name a type; did you mean 'Joystick'?

This report would have more information with  
"Show verbose output during compilation"  
option enabled in File -\> Preferences.

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [March 24, 2022, 3:45pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/2 "2022-03-24T15:45:08Z")

</div>

use \</\> button at inserting a code or Error messages.

---

<div class="post-metadata">

**Author:** ![hemo84](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@hemo84](https://forum.arduino.cc/u/hemo84)\
**Post date:** [March 24, 2022, 4:13pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/3 "2022-03-24T16:13:11Z")

</div>

thanks

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [March 24, 2022, 4:17pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/4 "2022-03-24T16:17:42Z")

</div>

i have no errors

---

<div class="post-metadata">

**Author:** ![hemo84](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@hemo84](https://forum.arduino.cc/u/hemo84)\
**Post date:** [March 24, 2022, 4:43pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/5 "2022-03-24T16:43:40Z")

</div>

When uploading the sketch to the board this error appears and stops loading.

Joystick\_' does not name a type; did you mean 'Joystick'?

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [March 24, 2022, 4:51pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/6 "2022-03-24T16:51:05Z")

</div>

i have this error not. it compiles completely and uploaded how expected

---

<div class="post-metadata">

**Author:** ![hemo84](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@hemo84](https://forum.arduino.cc/u/hemo84)\
**Post date:** [March 24, 2022, 5:26pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/7 "2022-03-24T17:26:04Z")

</div>

So, would it be any of the below cases,  
Cable problem  
Board type  
Computer issue

---

<div class="post-metadata">

**Author:** ![kolaha](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/kolaha/32/966427_2.png) [@kolaha](https://forum.arduino.cc/u/kolaha)\
**Post date:** [March 24, 2022, 6:32pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/8 "2022-03-24T18:32:16Z")

</div>

replace old Cable/Board/Computer with new one but please don't post your sketch here. let me guess to the end.

---

<div class="post-metadata">

**Author:** ![hemo84](https://avatars.discourse-cdn.com/v4/letter/h/48db29/32.png) [@hemo84](https://forum.arduino.cc/u/hemo84)\
**Post date:** [March 24, 2022, 6:42pm UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/9 "2022-03-24T18:42:47Z")

</div>

thanks for your efforts and time 🙂

---

<div class="post-metadata">

**Author:** ![sterretje](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/sterretje/32/391294_2.png) [@sterretje](https://forum.arduino.cc/u/sterretje)\
**Post date:** [March 26, 2022, 4:32am UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/10 "2022-03-26T04:32:56Z")

</div>

> [@hemo84](#):
>
> Cable problem  
> Board type  
> Computer issue

It will definitely not be a cable problem as you do not even get to the upload stage. Your board type is correct and this is not a computer issue in the sense that it requires you to troubleshoot your PC (although one never knows how or what Microsoft manages to screw up).

Have you tried one of the examples that come with the library?

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [September 22, 2022, 4:33am UTC](https://forum.arduino.cc/t/joystick-32-function-button-box-master-error-uploading-sketch/973005/11 "2022-09-22T04:33:30Z")

</div>

Closed on September 22, 2022, 4:33am UTC

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
