Wifiibo is a tool for managing an amiibo collection. Using an ESP8266 (with the Arduino development environment) and an NFC reader, you can read & store existing amiibos, create new amiibos using amiibo data files, and view your amiibo data. All amiibo data is stored on the flash memory of the ESP8266, so there's no need for additional storage hardware. The whole thing is managed using any web browser!
The library that runs most of the amiibo functions is a port of amiitool for the ESP8266 using the Arduino environment.
- Save/back up existing amiibo
- Create blank amiibos without any existing dumps (requires encryption keys)
- Create new ammibos using data files (requires encryption keys)
- View your amiibo collection using any web browser (even on your phone!)
Main Page:
Filtering displayed amiibo:
Read an existing amiibo tag/figure:
Upload saved amiibo data:
Wifiibo requires the following hardware:
- ESP8266 (Wemos D1 Mini from Aliexpress: ~$3)
- PN532 NFC board (RECOMMENDED) (PN532 V3 board from Aliexpress: ~$5) or MFRC522 Board (MFRC522 RFID Reader module from Aliexpress: ~$5)
WARNING: The MFRC522 library used in Wifiibo is not compatible with newer MFRC522 chips. The PN532 board is highly recommended instead.
Remember to flip the DIP switches on the PN532 board to SPI mode (ch1: OFF, ch2: ON).
Make the following connections between the ESP8266 and the NFC board:
PN532 Pin | D1 Mini Pin | ESP Pin |
---|---|---|
MOSI | D7 | GPIO 13 |
MISO | D6 | GPIO 12 |
SCK | D5 | GPIO 14 |
SS | D4 | GPIO 2 |
VCC | +5V | +5V |
GND | GND | GND |
MFRC-522 Pin | D1 Mini Pin | ESP Pin |
---|---|---|
SDA | D2 | GPIO 4 |
SCK | D5 | GPIO 14 |
MOSI | D7 | GPIO 13 |
MISO | D6 | GPIO 12 |
GND | GND | GND |
RST | D3 | GPIO 0 |
3.3v | 3.3v | 3.3v |
If you already have the ESP toolchain (or at least utilities) installed, running the following command from a terminal/command prompt will flash the ESP:
esptool.py --port <serial_port> write_flash -fm dio 0x00000 <path/to/Wifiibo_1.35.ino.d1_mini.bin>
On Windows, the serial port will be something like COM5
, on Linux it will be something like /dev/ttyS1
or /dev/ttyUSB0
, and on Mac something like /dev/cu.usbserial-141130
.
If you don't have the ESP tools installed, but you have python (Linux,Mac), you can try to install them by running the following command from a terminal:
pip install esptool
Starting with 1.40, firmware binaries are created for both the D1 Mini and D1 Lite. The D1 Lite is configured for a SPI Flash Filesystem size of 256K, so OTA updates are likely impossible on the D1 Lite.
Wifiibo depends on a number of additional Arduino libraries (which are needed if you want to compile Wifiibo):
- EspAsyncTCP
- Currently-used version: 1.2.2
- ESPAsyncWebServer
- Currently-used version: 1.2.3
- ArduinoJson
- Currently-used version: 6.13.0
- Either version 5 or 6 should be supported
Wifiibo also uses modified versions of the following libraries; they are included with Wifiibo, so you don't need to download them separately (they also use different library names so they will coexist with existing copies):
In order to compile the Wifiibo software, you'll need the Arduino IDE. Ensure you have the ESP8266 board support package version 2.6.3 installed (refer to the main ESP8266 Arduino page for instructions on setting it up). Clone this repository into the 'libraries' folder in your Arduino sketch folder. Open the Arduino IDE, and you'll find Wifiibo under the "Examples" menu. After selecting your ESP8266 board in the IDE, click the Upload button to flash Wifiibo to the ESP8266. Hint: After the inital upload, you can place existing amiibo dumps and the retail key file into the sketch Data directory, and use the "ESP8266 Sketch Data Upload" option in the "Tools" menu to upload them all at once.
When Wifiibo starts, if your ESP8266 isn't connected to Wifi, it will start up its own hotspot called "Wifiibo." Connect to the hotspot using your phone or computer, then open a web browser and go to http://192.168.4.1 to access Wifiibo. Click on the "Configure Wifi" button, enter your Wifi network credentials, and click submit.
Once connected to Wifi, you can access Wifiibo by going to http://wifiibo.local in your broswer. Alternatively, some routers will allow you to go to http://wifiibo. (note the '.' at the end). Tip: Once you get to the Wifiibo page, you can click on the IP in the top-right corner of the page. Using the IP directly seems to be faster on some Windows computers.
In order for Wifiibo to read or write any amiibo tags, it needs the amiibo encryption keys. Click on the red button labeled "Upload keys" for further instructions. Alternatively, if you already have a keys file, you can upload it using the "Upload amiibo" button (the keys file must be named "key_retail.bin"). Once you have successfully imported the amiibo encryption keys, the red "Upload keys" button will disappear.
Using Wifiibo is fairly straightforward. amiibo data is pulled from the excellent amiibo API by @N3vin. In order to write amiibo information to a tag, the tag must be type NTAG215 and must be blank.
If new software releases are made, they will show up in the "releases" folder. To easily update your Wifiibo, download the latest release binary, then go to http://wifiibo.local/update. Select the "bin" file you downloaded, and click the "Update" button. When updating is complete, the page will change to "OK." Go back to http://wifiibo.local and verify that the version number in the upper-right corner of the screen has been updated.
If you have access to a 3D printer, you can print an enclosure for Wifiibo. The enclosure is in two halves, which press-fit together. The lid piece will need to be printed upside-down and requires support material for the "inset" on the top. The Wemos D1 Mini board can be press-fit into the base, and the NFC board can be screwed into the standoffs in the lid. I made the standoffs slightly smaller than the #4-40 screws I used, so I tapped the mounts using an inexpensive tapping tool. Alternatively, there's another lid version that allows the NFC board to be pressfit into the lid.
Enclosure (created in OpenSCAD):
Jack06WS made a PCB for Wifiibo! Check it out here: https://github.com/Jack06WS/WifiiboPCB
- The main Wifiibo page is called amiitool.htm. There's a python script & accompanying executable that's used to gzip the page, then convert the binary into a C-style header file so the page is embedded in the firmware. This way, any future firmware updates will contain the updated web page (otherwise users would have to upload it separately).
- The main page (amiibool.htm) is pretty messy
Wifiibo mostly uses software & libraries written by others. The following resources were used to develop Wifiibo:
- Kostia Plays - Tons of info on how to read & write amiibos by @konstantin-kelemen
- amiitool - Software to encrypt/decrypt amiibo data by @socram8888
- GBATemp - amiibo data structure information
- 3dBrew - amiibo/NTAG215 data structure information
- amiibo API - Online amiibo database & index by @N3vin
MFRC-522 NFC chip supportComplete!Pull requests welcome; ensure it implements the NFCInterface pure virtual class.
- Card emulation support using PN532
- Not sure if this is possible- the documentation on the PN532 states that in emulation mode, only 4-byte IDs are supported. Might be able to supply raw page data to get it to work.
- SD card support
- The amiitool library has some SD support (using the SdFat library for long filename support), but it has not been tested.
- The Wifi scan results JSON info in the main program might need to be changed from static to dynamic to handle a large number of results
- Bulk upload & download (via ZIP file)
- This should be handled in the JavaScript frontend, since the ESP8266 doesn't have enough memory to handle it
- Bulk upload is supported via multi-file select