Had to do the same with my Teensy since it's inside a SNES controller
If that is all you want to do, I recommend taking a look at my CommunityController repo as you can do pretty much anything you'd like via pythonDid you wire the buttons from this controller and rewrote the code to use them or just use the "default" joystick.c?
I just ordered a teensy and plan to use it for pokemon automation, it would be nice to use controller buttons to move ingame and trigger sequences...
If that is all you want to do, I recommend taking a look at my CommunityController repo as you can do pretty much anything you'd like via python
The only downside is that it requires an Arduino uno opposed to a Teensy since I lost the original source
C:\Switch Dev\Splatmeme-Printer>mingw32-make
0 [main] sh 6452 sync_with_child: child 13396(0x1E4) died before initialization with status code 0xC0000142
263 [main] sh 6452 sync_with_child: *** child state waiting for longjmp
/usr/bin/sh: fork: Resource temporarily unavailable
0 [main] sh 3292 sync_with_child: child 1308(0x1F0) died before initialization with status code 0xC0000142
303 [main] sh 3292 sync_with_child: *** child state waiting for longjmp
/usr/bin/sh: fork: Resource temporarily unavailable
0 [main] sh 5072 sync_with_child: child 5504(0x1F0) died before initialization with status code 0xC0000142
267 [main] sh 5072 sync_with_child: *** child state waiting for longjmp
/usr/bin/sh: fork: Resource temporarily unavailable
[INFO] : Begin compilation of project "Joystick"...
avr-gcc (WinAVR 20100110) 4.3.3
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
[GCC] : Compiling C file "Joystick.c"
avr-gcc -c -pipe -gdwarf-2 -g2 -mmcu=atmega16u2 -fshort-enums -fno-inline-small-functions -fpack-struct -Wall -fno-strict-aliasing -funsigned-char -funsigned-bitfields -ffunction-sections -I. -DARCH=ARCH_AVR8 -DF_CPU=16000000UL -mrelax -fno-jump-tables -x c -Os -std=gnu99 -Wstrict-prototypes -DUSE_LUFA_CONFIG_HEADER -IConfig/ -DZIG_ZAG_PRINTING -I. -I./LUFA/LUFA/.. -DARCH=ARCH_AVR8 -DBOARD=BOARD_NONE -DF_USB=16000000UL -MMD -MP -MF obj/Joystick.d Joystick.c -o obj/Joystick.o
Joystick.c: In function 'SetupHardware':
Joystick.c:56: warning: implicit declaration of function 'clock_prescale_set'
Joystick.c:56: error: 'clock_div_1' undeclared (first use in this function)
Joystick.c:56: error: (Each undeclared identifier is reported only once
Joystick.c:56: error: for each function it appears in.)
LUFA/LUFA/Build/DMBS/DMBS/gcc.mk:213: recipe for target 'obj/Joystick.o' failed
mingw32-make: *** [obj/Joystick.o] Error 1
C:\Switch Dev\Splatmeme-Printer>
Joystick.c:213: error: 'clock_div_1' undeclared (first use in this function)
clock_prescale_set(clock_div_1);
CLKPR = (1 << CLKPCE); CLKPR = (0 << CLKPS3) | (0 << CLKPS2) | (0 << CLKPS1) | (0 << CLKPS0);
I've had two errors that I had to fix.
1. For the error:
I replaced Joystick.c line 212Code:Joystick.c:213: error: 'clock_div_1' undeclared (first use in this function)
withCode:clock_prescale_set(clock_div_1);
2. @Proto-Propski I had this error. I think the makefile tries to put intermediate files in a folder called "obj", but there is no obj folder. I simply made a folder called "obj" for it to put the files in and it worked!Code:CLKPR = (1 << CLKPCE); CLKPR = (0 << CLKPS3) | (0 << CLKPS2) | (0 << CLKPS1) | (0 << CLKPS0);
Now I'm getting this error.I've had two errors that I had to fix.
1. For the error:
I replaced Joystick.c line 212Code:Joystick.c:213: error: 'clock_div_1' undeclared (first use in this function)
withCode:clock_prescale_set(clock_div_1);
2. @Proto-Propski I had this error. I think the makefile tries to put intermediate files in a folder called "obj", but there is no obj folder. I simply made a folder called "obj" for it to put the files in and it worked!Code:CLKPR = (1 << CLKPCE); CLKPR = (0 << CLKPS3) | (0 << CLKPS2) | (0 << CLKPS1) | (0 << CLKPS0);
C:\Users\Chico\Desktop\Splatmeme-Printer-master>make
0 [main] sh 9828 sync_with_child: child 11892(0x1EC) died before initialization with status code 0xC0000142
186 [main] sh 9828 sync_with_child: *** child state waiting for longjmp
/usr/bin/sh: fork: Resource temporarily unavailable
0 [main] sh 4536 sync_with_child: child 12080(0x1EC) died before initialization with status code 0xC0000142
228 [main] sh 4536 sync_with_child: *** child state waiting for longjmp
/usr/bin/sh: fork: Resource temporarily unavailable
[INFO] : Begin compilation of project "Joystick"...
avr-gcc (WinAVR 20100110) 4.3.3
Copyright (C) 2008 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
[GCC] : Compiling C file "Joystick.c"
avr-gcc -c -pipe -gdwarf-2 -g2 -mmcu=atmega16u2 -fshort-enums -fno-inline-small-functions -fpack-struct -Wall -fno-strict-aliasing -funsigned-char -funsigned-bitfields -ffunction-sections -I. -I./LUFA/.. -DARCH=ARCH_AVR8 -DBOARD=BOARD_NONE -DF_USB=16000000UL -DF_CPU=16000000UL -mrelax -fno-jump-tables -x c -Os -std=gnu99 -Wstrict-prototypes -DUSE_LUFA_CONFIG_HEADER -IConfig/ -DZIG_ZAG_PRINTING -MMD -MP -MF Joystick.d Joystick.c -o Joystick.o
In file included from Joystick.h:53,
from Joystick.c:27:
Descriptors.h:52: error: conflicting types for 'CALLBACK_USB_GetDescriptor'
./LUFA/Drivers/USB/Core/AVR8/../Device.h:133: error: previous declaration of 'CALLBACK_USB_GetDescriptor' was here
make: *** [Joystick.o] Error 1
Heya, I got this for the sole purpose of using it in Splatoon 3. After 8+ hours of trial an error, I can confirm it works! What you'll have to do to get it to work however, is follow everything in the linked github. BUT, before you use the "make" command, open Joystick.c in notepad and find the line that talks about:Is this working for splatoon 3? I tested it in splatoon 2 and it works fine but not for splatoon 3. It draws just a bunch of random lines and dots on the left side of the drawing. Right side is completely ignored
Is this working for splatoon 3? I tested it in splatoon 2 and it works fine but not for splatoon 3. It draws just a bunch of random lines and dots on the left side of the drawing. Right side is completely ignored
Heya, I got this for the sole purpose of using it in Splatoon 3. After 8+ hours of trial an error, I can confirm it works! What you'll have to do to get it to work however, is follow everything in the linked github. BUT, before you use the "make" command, open Joystick.c in notepad and find the line that talks about:Is this working for splatoon 3? I tested it in splatoon 2 and it works fine but not for splatoon 3. It draws just a bunch of random lines and dots on the left side of the drawing. Right side is completely ignored
You can also replace "SWITCH_MINUS" with "SWITCH_LCLICK". My only problem now is that the cursor is wiggling and rubbing up alongside the sides of the canvas.Heya, I got this for the sole purpose of using it in Splatoon 3. After 8+ hours of trial an error, I can confirm it works! What you'll have to do to get it to work however, is follow everything in the linked github. BUT, before you use the "make" command, open Joystick.c in notepad and find the line that talks about:
// Clear the screen if (command_count == ms_2_count(1500) || command_count == ms_2_count(3000)) ReportData->Button |= SWITCH_MINUS;
And remove it completely. In splatoon 2, the minus button is used to clear the screen, but in Splatoon 3, they moved that button to L Stick button. Because of this, the Minus button in splatoon 3 will "save and close" the post.
Remove the -zigzag blah blah part from the makefile and redo it all again.You can also replace "SWITCH_MINUS" with "SWITCH_LCLICK". My only problem now is that the cursor is wiggling and rubbing up alongside the sides of the canvas.
This is what happens to me
View attachment 326761
Remove the -zigzag blah blah portion of the makefile. The try it again after recompiling.You can also replace "SWITCH_MINUS" with "SWITCH_LCLICK". My only problem now is that the cursor is wiggling and rubbing up alongside the sides of the canvas.
This is what happens to me
View attachment 326761
This worked, thanks a lotRemove the -zigzag blah blah portion of the makefile. The try it again after recompiling.
How were you able to get your arduino to choose the left most pen option? for me it's constantly using the middle pen.You can also replace "SWITCH_MINUS" with "SWITCH_LCLICK". My only problem now is that the cursor is wiggling and rubbing up alongside the sides of the canvas.
This is what happens to me
View attachment 326761
// Clear the screen if (command_count == ms_2_count(1500) || command_count == ms_2_count(3000)) ReportData->Button |= SWITCH_MINUS;
// Clear the screen if (command_count == ms_2_count(1500) || command_count == ms_2_count(3000)) ReportData->Button |= SWITCH_L;
I’m stuck on this as well. I’m not sure which line I need. There are multiple lines that start with avrdude. I have an Arduino Micro.Hi everyone, I have and Arduino Leonardo (atmega32u4) and after about putting in close to an hour of work I am stuck on Step 5 with a when it comes to flashing the Joystick.hex to my Ardunio. Both the tutorial and github talk about avrdude giving you a code when you upload any sketch to it. My question is where exactly is this code located? there's a bunch of lines that start with avrdude but I dont see anything that would be a command line code.
Second, when it comes to uploading a sketch to the ardunio in step 4, does it matter if it's a blank sketch? Is that a possible reason why when I go into step 5 I am getting no code back for avrdude? I'm extremely new to the arduino scene and don't know what type or kind of sketch I'm needing to upload, or if the blank code is good enough.
Thank you to anyone who can help.
I've chugged through the instructions and am hitting a wall at this step, but I'm not seeing a Joystick.hex file, just Joystick.c and Joystick.h. Any pointers, or am I missing something obvious?...flashing the Joystick.hex to my Ardunio....