Hacking How to use ShinyQuagsire's Splatoon 2 Post Printer

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
!!! This is an outdated thread! Plese use this one instead. !!!

Disclaimer: This is not an easy guide to use! It's not as simple as placing some files in certain spots and running "make"; there are certain things you need to install, environment variables you need to set, etc. A *lot* of troubleshooting will most likely be necessary. I'm happy to help if you need some assistance, however.


Seeing as nobody else has made a guide like this, and I've figured out how to get it running, I figured I'd make a guide to help out. This guide is not for beginners; you'll need at least a bit of knowledge on how to add programs to your path, use the command line, etc. This is also assuming you're using Windows.

If you have a device that uses chips like the ATMega328,
this project will not work. You need a USB HID compatible microcontroller.

For those who don't know, this is the post printer:

It uses a Teensy 2.0++ (and possibly other microcontrollers with USB HID compatible AVRs, such as the ATMega32u4) to mimic a Hori Pokken pad for the WiiU, which now works on the Switch due to update 3.0.0 allowing more controllers to be used.

You'll need:

Hardware:
- A Teensy 2.0++ (the one with the AT90USB1286)
- A USB C male to USB female adapter like this one, brand doesn't really matter long as it works with the Switch
- A Nintendo Switch
- Splatoon 2

Software:
- Teensy Loader (Windows binary)
- LUFA
- Atmel AVR 8-bit and 32-bit GNU Toolchain (You'll need to create an account on the site to download)
- The Splatoon 2 post printer, of course (Hit "Clone or download" and download a .zip)
- If you have an ATMega32u4 board, use this repo instead for the post printer. Also, here's a much more up-to-date repo.
- Python 2.7 (Not Python 3)
- GIMP 2
- MinGW (the .exe installer)

Section 1: Preparation

First, you'll need to get all the software installed and everything.
  1. Download the Teensy Loader
  2. Download and install Python 2.7.
  3. Download and install Atmel's AVR 8-bit Toolchain (extract this to a folder like C:\development\AVR-Toolchain or something)
  4. Download and install GIMP. (Seeing a pattern here?)
  5. Download and install MinGW. If it wants to install any addons for the program itself, say yes.
  6. Create a folder somewhere on your PC (I made mine in C:\development\SwitchFightstick)
  7. Open up the .zip file for the post printer (whould be called Switch-Fightstick-master.zip) and open the folder inside that so you can see all the files. Extract all those into the folder you made in the last step. Delete the "image.c" file since you'll be making a new one later.
  8. Open up your system PATH by hitting the windows key and searching for "Edit the system environment variables", clicking "Environment variables...", and double clicking "Path" in the bottom system variables section.
  9. Open up Windows Explorer and find the folder where you installed the AVR toolchain in step 3. Once there, find the "bin" folder and go into that. Then copy your current path by clicking the top bar, selecting it all, and hitting ctrl+C.
  10. Go back to the Path window you opened in step 7 and hit "New". Paste the directory to the toolchain's bin folder there. While you're there, also add the directory "C:\Python27" (without quotes) to make sure Python will work properly. Apply and exit. You'll also need to add C:\MinGW\bin to your path.
  11. Browse to the folder where you extracted the atual post printer, and open up the LUFA zip file. Find the folder inside the zip file titled "Build", open it, find the "LUFA" folder inside that and copy it to the same directory as the post printer
  12. If you're using an ATMega32u4 board, open the makefile in a text editor (preferably Notepad++) and replace the "MCU = at90usb1286" with "MCU = atmega32u4"
Section 2: Preparing the image for printing
  1. Open up GIMP and hit ctrl+N to make a new canvas. Make it 320px wide and 120px tall.
  2. Paste your image onto this new canvas and resize it to fit however you want.
  3. On the top toolbar, select "Image" then hit "Mode" and select "Indexed". When the window pops up, hit "Use black and white (1 bit) pallet", and make sure dithering is set to normal. Your image should now be in just black and white, no grey or anything in between.
  4. Hit File > Export As... and export the image as "raw image data (.data)" and save it inside the post printer's folder alongside all the other files. Name it whatever you want, as long as it ends in ".data".
  5. Open up a command window and browse to the post printer's folder. Next you'll want to run the command "python bin2c.py [name of your image] > image.c". If successful, nothing will happen in the command line itself, but you should have a new file called "image.c"
  6. Run the command "make all". If you did everything correctly, it should now compile!
Section 3: Actually running it from the Teensy

I don't actually have my Teensy yet (ordered it last night), but I do have some experience using similar boards in the past. The following may not be 100% accurate, but it should be close enough that you can get it to work if I mistype something.
  1. Plug in your Teensy 2.0++ and open the Teensy Loader.
  2. Extract the .exe file to the post printer's directory. Don't run it.
  3. Open a command window and navigate to the post printer's directory.
  4. Run the command "teensy_loader_cli -mmcu=at90usb1286 -w Joystick.hex". If nothing happens, try pressing the button on the Teensy.
  5. Make sure your Switch is charged fully; this will take a while. Like, an hour or more. It's not very fast, but still faster than doing it by hand.
  6. Open Splatoon 2 and go over to the post box. Select the smallest pencil with L. Hold up and right until the cursor is at the very top right corner, then press left and down once each. The cursor won't look like it moved. This is because the cursor actually goes one pixel out outside the boundaries, and pusing left and down brings to exactly the corner. You can tell by pressing left or down again; it should move instead of staying still. Just put it back to the corner again.
  7. Now you should be able to unplug your Teensy, plug your USB C to USB adapter into the Switch (in handheld mode), plug in the Teensy, and go! The reason you need to do it in handheld mode is because there are sync issues when just using the dock's USB ports in docked mode.
If I made a mistake in any portion of this guide, please correct me! The above should get it working properly, but if it doesn't I need to know what I wrote wrong and what to correct. Again, I don't actually have my Teensy board itself so I can't fully test it, but I was able to successfully do sections 1 and 2.

Anyone who has a Teensy 2.0++ and is willing to test this, please do and let me know if it works!

@FierceDeityLink1 and @_______ have confirmed this works with atmega32u4 boards!
 
Last edited by dj505,

LightOffPro

ユキオクン
Member
Joined
Jun 10, 2016
Messages
316
Trophies
0
Age
28
Location
In Papa Rei's closet.
XP
811
Country
Portugal
This is dope as fuck, but it's very unlikely that the average user will buy a Teensy 2.0 just for this.
Still, very interesting concept! If i had the hardware for this, would definitely try it out.
 
  • Like
Reactions: Xanthe

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
This is dope as fuck, but it's very unlikely that the average user will buy a Teensy 2.0 just for this.
Still, very interesting concept! If i had the hardware for this, would definitely try it out.
I definitely did haha. It's fun messing with stuff like this. I think cheaper microcontrollers like the ATMega32u4 might work, but I don't have one and don't want to waste money on one that might not work
 

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
I definitely did haha. It's fun messing with stuff like this. I think cheaper microcontrollers like the ATMega32u4 might work, but I don't have one and don't want to waste money on one that might not work

If its pre-compiled .hex file, then no it won't work on an ATMega board.
 

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
If its pre-compiled .hex file, then no it won't work on an ATMega board.
Well when you actually use the makefile, you can choose your target platform by editing it. I'm sure if I were to select an ATMega32u4 or another USB HID compatible chip, it would output an appropriate file.
 

dpad_5678

Ape weak on own. Ape strong in unity.
Member
Joined
Nov 19, 2015
Messages
2,219
Trophies
1
XP
2,880
Country
United States
Well if we can get the SC, it would probably be port-able to Atmega32u4-based Arduino boards and clones such as the Micro/Pro Micro and Trinket. That's if it those boards are powerful enough for that.
 

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
Well if we can get the SC, it would probably be port-able to Atmega32u4-based Arduino boards and clones such as the Micro/Pro Micro and Trinket. That's if it those boards are powerful enough for that.
The project itself is open source, as well as the library it uses (LUFA - Lightweight USB Framework for AVRs) so it should be possible. From what I've read, LUFA should support any USB HID compatible chip to some degree
 

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
The project itself is open source, as well as the library it uses (LUFA - Lightweight USB Framework for AVRs) so it should be possible. From what I've read, LUFA should support any USB HID compatible chip to some degree

Thought it was closed as the OP mentioned .hex file. Then maybe it can, I should try it.
 

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
Thought it was closed as the OP mentioned .hex file. Then maybe it can, I should try it.
I am the OP haha. Yeah, I guess it depends on what board you compile it for. You get a hex file for the AT90USB1286 chip, not sure about any others as I haven't tried.

Thought it was closed as the OP mentioned .hex file. Then maybe it can, I should try it.
There's a tutorials section? TIL. Gonna cross post this there in the morning! Thanks for letting me know!
 
Last edited by dj505,

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
There's a tutorials section? TIL. Gonna cross post this there in the morning! Thanks for letting me know!

- EDIT - Apparently this project was a fork of another project that use an atmega32u4. Things will be much easier then,
 
Last edited by _______,

MegaMagikarp

Well-Known Member
Newcomer
Joined
Mar 25, 2015
Messages
83
Trophies
0
Location
California
XP
664
Country
Taiwan
I'm glad someone with relating knowledge did a write up. I wanted to try this before but wasn't sure where to start. Couldn't find helpful example on the internet about LUFA usage. Will look into this when I get a chance. (I have a Arduino instead of teensy tho, not sure if I can get it to work)
 

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
I'm glad someone with relating knowledge did a write up. I wanted to try this before but wasn't sure where to start. Couldn't find helpful example on the internet about LUFA usage. Will look into this when I get a chance. (I have a Arduino instead of teensy tho, not sure if I can get it to work)

It was a forked project originally using an atmega32u4. So we should be able to get it work on an Arduino.
 

Jayro

MediCat USB Dev
Developer
Joined
Jul 23, 2012
Messages
12,878
Trophies
4
Location
WA State
Website
ko-fi.com
XP
16,773
Country
United States
Pretty neat, but this is waaaaaaaaaaay too complicated for me to setup just to post a few 2 color dithered pictures. I'd rather print them out on printer paper, and trace them to the tablet.
 
  • Like
Reactions: TotalInsanity4

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
Ok, so it does compile for the atmega32u4 family, but you need avrdude or something to flash the resulting .hex file as the Arduino IDE won't load it. It should still work.

Tho it does compile, I can't get it to work with my Arduino Leonardo r3 somehow. (Plugged onto Switch and nothing happened. Maybe might was broken, donno) Uno use atmega328p which is not supported so I can't try that.
 

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
Tho it does compile, I can't get it to work with my Arduino Leonardo r3 somehow. (Plugged onto Switch and nothing happened. Maybe might was broken, donno) Uno use atmega328p which is not supported so I can't try that.
Maybe there's a button or something that needs to be hit... Maybe try plugging it in then pressing the reset button?
 

_______

 
Member
Joined
May 13, 2016
Messages
515
Trophies
0
XP
834
Country
Japan
Maybe there's a button or something that needs to be hit... Maybe try plugging it in then pressing the reset button?

I tried those of course. I didn't read the source entirely tho, but what I can see there is you don't need to interact with it since the action was pre-coded.

wrong post

In general you can't with this project. But with LUFA library in theory you can of course.
 

dj505

Inexperienced Romhacker
OP
Member
Joined
Oct 4, 2014
Messages
556
Trophies
0
Location
Most likely at the arcade
Website
www.youtube.com
XP
844
Country
Canada
I tried those of course. I didn't read the source entirely tho, but what I can see there is you don't need to interact with it since the action was pre-coded.
Ah, not sure why it's not working then. I'll be able to test it properly once my Teensy arrives, but until then I have no way to troubleshoot :/

Edit: Are you using the dock's USB hub or a USB C to A adapter?
 
Last edited by dj505,

Site & Scene News

Popular threads in this forum

General chit-chat
Help Users
  • K3Nv2 @ K3Nv2:
    @Sicklyboy, $150 isn't that bad for a jtag slim on ebay
  • Veho @ Veho:
    I only wish it was actually playable.
  • Veho @ Veho:
    There's a guy on the Tube of You that makes playable mechanical arcade games out of Lego. This could work on the same principle.
  • Veho @ Veho:
    Just a couple of guys taking their manatee out for some fresh air, why you have to molest them?
  • Veho @ Veho:
    Stupid Chinese shop switched their shipping company and this one is slooooooow.
  • LeoTCK @ LeoTCK:
    STOP BUYING CHINESE CRAP THEN
  • LeoTCK @ LeoTCK:
    SUPPORT LOCAL PRODUCTS, MAKE REVOLUTION
  • LeoTCK @ LeoTCK:
    THEY KEEP REMOVING LOCAL SHIt AND REPLACING WItH INFERIOR CHINESE CRAP
  • LeoTCK @ LeoTCK:
    THATS WHY MY PARTNER CANT GET A GOOTWEAR HIS SIZE ANYMORE
  • LeoTCK @ LeoTCK:
    HE HAS BIG FOOT AND BIG DUCK
  • LeoTCK @ LeoTCK:
    d*ck i mean*
  • LeoTCK @ LeoTCK:
    lol
  • Veho @ Veho:
    Mkay.
  • Veho @ Veho:
    I just ordered another package from China just to spite you.
  • SylverReZ @ SylverReZ:
    Communism lol
  • SylverReZ @ SylverReZ:
    OUR products
  • The Real Jdbye @ The Real Jdbye:
    @LeoTCK actually good quality products are dying out because they can't compete with dropshipped chinese crap
    +2
  • BakerMan @ BakerMan:
    @LeoTCK is your partner the sascrotch or smth?
  • Xdqwerty @ Xdqwerty:
    Good morning
  • Xdqwerty @ Xdqwerty:
    Out of nowhere I got several scars on my forearm and part of my arm and it really itches.
  • AdRoz78 @ AdRoz78:
    Hey, I bought a modchip today and it says "New 2040plus" in the top left corner. Is this a legit chip or was I scammed?
    AdRoz78 @ AdRoz78: Hey, I bought a modchip today and it says "New 2040plus" in the top left corner. Is this a legit...