More actions
(Created page with "{{Infobox Switch Homebrews |title=emuiibo |image=emuiiboswitch.png |description=Virtual amiibo (amiibo emulation) system for Nintendo Switch. |author=XorTroll |lastupdated=2022/02/10 |type=Utilities |version=0.6.4 |license=GPL-2.0 |download=https://dlhb.gamebrew.org/switchhomebrews/emuiiboswitch.7z |website=https://gbatemp.net/threads/emuiibo-mitming-nfp-services-for-amiibo-emulation.536210/ |source=https://github.com/XorTroll/emuiibo |donation=https://patreon.com/xortr...") |
No edit summary |
||
Line 1: | Line 1: | ||
{{Infobox Switch Homebrews | {{Infobox Switch Homebrews | ||
|title=emuiibo | |title=emuiibo | ||
|image= | |image=emuiibonx.png | ||
|description=Virtual amiibo (amiibo emulation) system for Nintendo Switch. | |description=Virtual amiibo (amiibo emulation) system for Nintendo Switch. | ||
|author=XorTroll | |author=XorTroll | ||
|lastupdated=2022/02/ | |lastupdated=2022/02/11 | ||
|type=Utilities | |type=Utilities | ||
|version=0.6.4 | |version=0.6.4 | ||
|license=GPL-2.0 | |license=GPL-2.0 | ||
|download=https://dlhb.gamebrew.org/switchhomebrews/ | |download=https://dlhb.gamebrew.org/switchhomebrews/emuiibonx.7z | ||
|website=https://gbatemp.net/threads/emuiibo-mitming-nfp-services-for-amiibo-emulation.536210/ | |website=https://gbatemp.net/threads/emuiibo-mitming-nfp-services-for-amiibo-emulation.536210/ | ||
|source=https://github.com/XorTroll/emuiibo | |source=https://github.com/XorTroll/emuiibo | ||
|donation=https://patreon.com/xortroll | |donation=https://patreon.com/xortroll | ||
}} | }} | ||
emuiibo is a background process (and service) which Nintendo Switch's internal NFC (NFP) services to support virtual amiibo emulation. | |||
| | |||
| | ==Installation== | ||
| | You need to the following files: | ||
| | *emuiibo (grab the latest release [https://github.com/XorTroll/emuiibo/releases here]) | ||
*emutool (see emuiibo download above) | |||
*Tesla (grab the latest [[Tesla Menu Switch|Tesla-Menu]] and [[NX-ovlloader Switch|nx-ovlloader]]) | |||
How to setup: | |||
*Make sure you downloaded all files mentioned above. | |||
*Create these folders on your SD (if not present): | |||
**<code>sd:/emuiibo/amiibo</code> | |||
**<code>sd:/switch/.overlays</code> | |||
*Extract all ZIP files and copy the folders on your SD card. It should look like this in the end: | |||
**emuiibo - <code>sd:/atmosphere/contents/0100000000000352/exefs.nsp</code> and <code>/flags</code> folder | |||
**emuiibo overlay - <code>sd:/switch/.overlays/emuiibo.ovl</code> | |||
**tesla-menu - <code>sd:/switch/.overlays/ovlmenu.ovl</code> | |||
**nx-ovlloader - <code>sd:/atmosphere/contents/420000000007E51A/exefs.nsp</code> and <code>/flags</code> folder | |||
If you set up everything correctly, emuiibo is ready to load your amiibos you created via emutool (see below) or via raw .bin amiibo dump fules. | |||
==User guide== | |||
===SD layout=== | |||
*Emuiibo's directory is <code>sd:/emuiibo</code>. | |||
*Virtual amiibos go inside <code>sd:/emuiibo/amiibo</code>. For instance, an amiibo named <code>MyMario</code> would be <code>sd:/emuiibo/amiibo/MyMario/<amiibo content></code>. | |||
*However, categories are supported by placing amiibos inside sub-directories (only inside a directory, like 3DS menu categories inside categories are not supported) - for instance: <code>sd:/emuiibo/amiibo/SSBU/Yoshi</code> would be a <code>Yoshi</code> amiibo inside <code>SSBU</code> category. | |||
*A virtual amiibo is detected by emuiibo based on two aspects: a <code>amiibo.json</code> and a <code>amiibo.flag</code> file must exist inside the virtual amiibo's folder mentioned above. If you would like to disable a virtual amiibo from being recognised by emuiibo, just remove the flag file, and create it again to enable it. | |||
*Every time the console is booted, emuiibo saves all the miis inside the console to the SD card. Format is <code>sd:/emuiibo/miis/<index> - <name>/mii-charinfo.bin</code>. | |||
===emutool - virtual amiibo creation=== | |||
Emuiibo no longer accepts raw BIN dumps to emulate amiibos. Instead, you can use <code>emutool</code> PC tool in order to generate virtual amiibos. | |||
First we look on the left half of the program: | |||
*In the first dropdown menu on top, you can choose amiibos from a certain collection. | |||
*In the second dropdown menu next to it, you can choose any amiibo you want to create. | |||
On the right half of the tool: | |||
*You can choose a name for the amiibo you want to create, a custom directory name (if you uncheck "Use name as directory name" below it). | |||
*You can then choose if you want the amiibo to use randomized UUIDs. This means that the console always read it as a new/unique amiibo (some games have restrictions to use the same amiibo only once or once a day). Note that this might cause issues for games which save data into amiibos, so avoid using it on those. | |||
*Then, you can choose if you want to save the amiibo picture shown on the left into the amiibo folder (it will be saved as a PNG file). | |||
Optional: | |||
*If you have a FTP connection on your switch console, you can directly save your amiibo on your SD into: emuiibo/amiibo/. | |||
In the last step you click on "Create virtual amiibo" and choose a location, where you want to save it to. If an SD card with emuiibo is detected, the program will point to that SD's <code>/emuiibo/amiibo</code> folder. | |||
Now you can copy the generated amiibo folder onto your SD card, in <code>sd:/emuiibo/amiibo/</code> or <code>sd:/emuiibo/amiibo/<category>/</code> - you can sort virtual amiibos by categories this way. | |||
===emuiibo basic controls=== | |||
If you set up everything mentioned above, you're ready to use emuiibo ingame. | |||
'''Tip:''' Enable it before you start a game, because it does not work in some games if you enable it after launching the game. | |||
To open the Tesla overlay, hold down L1 + D-Pad Down and then press R3 (Right Stick). If you did it, Tesla Overlay will open on the left side of the screen. Now choose emuiibo. | |||
In the emuiibo overlay: | |||
*Manage emulation: enable/disable emuiibo via DPad or L3 (it´s disabled by default). | |||
*View amiibo: | |||
**Choose your amiibo from root (<code>sd:/emuiibo/amiibo/</code>). | |||
**Choose your amiibo from a category (<code>sd:/emuiibo/amiibo/<category>/</code>). | |||
To go back in the menus, just press B button. | |||
After you selected an amiibo, you can see it's selected on top in the overlay and that it is "connected". | |||
"Connected" is the equivalent of holding a real amiibo figurine/card on the NFC point. To "Disconnect" the amiibo (the equivalent of removing a real amiibo from the NFC point), just select the same amiibo again. | |||
To see if emuiibo is working ingame, check if emuiibo is intercepting the game when it's trying to access amiibos. If it's not, try launching the game with emuiibo enabled first. | |||
====Example usage==== | |||
*Open the overlay and choose emuiibo. | |||
*Enable emuiibo. | |||
*Start the game. | |||
*Navigate to the games NFC feature to use the amiibo and activate it. | |||
*Open the overlay and choose your amiibo (will be connected). | |||
*The game should now register/make use of it. | |||
*If the game tells you to remove the amiibo, disconnect it. | |||
====Options==== | |||
*'''Emulation status (on/off):''' | |||
**When emuiibo's emulation status is on, it means that any game trying to access/read amiibos will be intercepted by emuiibo. | |||
**When it's off, it means that amiibo services will work normally, and nothing will be intercepted. | |||
**This is basically a toggle to globally disable or enable amiibo emulation. | |||
*'''Active virtual amiibo:''' | |||
**it's the amiibo which will be sent to the games which try to scan amiibos, if emulation is on. | |||
**Via tools such as the overlay, one can change the active virtual amiibo. | |||
*'''Virtual amiibo status (connected/disconnected):''' | |||
**When the active virtual amiibo is connected, it means that the amiibo is always "placed", as if you were holding a real amiibo on the NFC point and never moving it - the game always detects it. | |||
**When it is disconnected, it means that you "removed" it, as if you just removed the amiibo from the NFC point. | |||
**Some games might ask you to remove the amiibo after saving data, so you must disconnect the virtual amiibo to "simulate" that removal. | |||
**This is a new feature in v0.5, which fixed errors, since emuiibo tried to handle this automatically in previous versions, causing some games to fail. | |||
All this aspects can be seen/controlled via the overlay. | |||
===Supported figures=== | |||
Some games (like Skylanders) make use of their particular NFC technology, aside from amiibos. | |||
This project ONLY emulates amiibos; therefore, in Skylanders' case, only the two special figurines with amiibo support can be emulated here, where emuiibo will only emulate the "amiibo part" of them. | |||
===For developers=== | |||
emuiibo hosts a custom service, also named <code>emuiibo</code>, which can be used to control amiibo emulation by IPC commands. | |||
The overlay's code can be a good example to see how to control emuiibo from IPC and C++. | |||
===Raw dumps and encryption=== | |||
When using raw dumps, emuiibo doesn't save everything they have onto the new format, since some bits are encrypted. This is, for instance, why 20-heart Wolf Link amiibo dumps won't work with emuiibo, since the amiibo's app-area, where the console/game saves amiibo savedata, is an encrypted field, and it contains the information BOTW needs in order to recognize the feature. | |||
You can manually extract it, using [https://github.com/socram8888/amiitool amiitool]. You'll need to find the retail amiibo key to use it. | |||
Running the following will decrypt the raw dump: | |||
amiitool -d -k <key-file-bin> -i <amiibo-raw-dump-bin> -o <out-decrypted-bin> | |||
You'll have the decrypted app-area section at offset 0xDC on the decrypted dump, of length 0xD8. By saving that as <code><game-access-id>.bin</code> inside the <code>/areas</code> folder of a virtual amiibo being used by emuiibo, you can actually import the dump's savedata, which would allow for such things to work. Check below for a list of per-game access IDs. | |||
===Amiibo format=== | |||
Amiibos are, as stated above, directories with an <code>amiibo.json</code> and an <code>amiibo.flag</code> file. The flag is mainly there in case people would like to disable an amiibo and then re-enable it later. | |||
The JSON file contains all the aspects and data an amiibo needs to provide to games, except a few aspects (per-game savedata, protocol and tag type...) | |||
This are the properties an amiibo has: | |||
{| class="wikitable" | |||
! Name | |||
| The amiibo's name (max. 40 characters). | |||
|- | |||
! UUID | |||
| It's a unique identifier for the amiibo, composed of 10 bytes. If the "uuid" field is not present in the JSON, emuiibo will randomize the UUID everytime amiibo data is sent to a game. This has potential benefits in certain games, like in BOTW, where amiibos can only be used once per day, but with randomized UUIDs this can be bypassed, and one can get infinite rewards scanning this amiibo infinite times. | |||
|- | |||
! Mii | |||
| Every amiibo has a mii associated with it (it's "owner"). Internally, miis consist on a 88-byte structure known as "charinfo", so emuiibo stores this data in a file (typically <code>mii-charinfo.bin</code>). For new amiibos, emuiibo uses the console's services to generate a random mii, but for those who would like to use a mii from their console, emuiibo dumps in <code>miis</code> directory the console's miis, so it's just a matter of copying and pasting/replacing charinfo bin files. NOTE: emuiibo contains the charinfo file's name in the JSON (<code>mii_charinfo_file</code>), so if the file ever gets renamed, don't forget to rename it in the JSON too, or emuiibo will generate a random mii for the file name in the JSON. | |||
|- | |||
! First and last write dates | |||
| These are (as if it wasn't obvious) the first and last time the amiibo was written/modified. When a virtual amiibo is created with emutool, the current date is assigned to both dates, and when the amiibo is modified in console, emuiibo updates the last write date. | |||
|- | |||
! Write counter | |||
| This is a number which is increased everytime the amiibo is modified (and emuiibo does so, imitating Nintendo), but when the number reaches 65535, it is no longer increased (the number is technically a 16-bit number). | |||
|- | |||
! Version | |||
| This value technically represents the version of Nintendo's amiibo library (NFP), so emuiibo just defaults it to 0. | |||
|- | |||
|} | |||
====Areas==== | |||
Areas (application areas, technically) are per-game amiibo savedata. Technically, real amiibos can only save data for a single game, but emuiibo allows as many games as you want (since savedata is stored as files). This savedata is quite small, and tends to be 216 bytes or smaller. | |||
emuiibo saves this data inside bin files at <code>areas</code> directory inside the amiibo's directory, and the bin file's name is the game's area access ID in hex format. | |||
An access ID is a unique ID/number each game has for amiibo savedata, used to check if the game actually has savedata in an amiibo. Here's a list of games and their access IDs: | |||
====Per-game access IDs==== | |||
A list is maintained at [https://switchbrew.org/w/index.php?title=NFC_services#Access_ID Switchbrew]. | |||
==Screenshots== | ==Screenshots== | ||
https://dlhb.gamebrew.org/switchhomebrews/ | '''emuiibo'''<br> | ||
https://dlhb.gamebrew.org/switchhomebrews/ | https://dlhb.gamebrew.org/switchhomebrews/emuiibonx2.png | ||
https://dlhb.gamebrew.org/switchhomebrews/ | |||
https://dlhb.gamebrew.org/switchhomebrews/emuiibonx3.png | |||
https:// | '''emutool'''<br> | ||
https://dlhb.gamebrew.org/switchhomebrews/emuiibonx4.png | |||
==Media== | |||
'''How to use emuiibo with Tesla in switch - switch 10.2.0 Atmosphere 0.14.4 Animal crossing''' ([https://www.youtube.com/watch?v=Wq-bzEU55NI TruganiniGamePlay]) <br> | |||
<youtube>Wq-bzEU55NI</youtube> | |||
==Changelog== | ==Changelog== | ||
''' | '''v0.6.3 2022/02/11''' | ||
* | *emuiibo: | ||
**Fixed some minor issues related to virtual amiibo area saving. | |||
**Fixed a weird internal issue where sometimes emuiibo would become unaccessible under certain circumstances. | |||
*overlay: | |||
**The overlay has almost entirely changed thanks to the huge work of AD2076 and AmonRaNet: | |||
***Really improved UI and design. | |||
***Now, aside from English, the following languages are supported: German, Spanish, Russian, Traditional and Simplified Chinese. | |||
*emutool: | |||
**No changes (not uploading a new release). | |||
'''v0.6.3 2021/04/20''' | |||
*emuiibo: | |||
**Fixed support for latest Atmosphere versions (0.19.x) and for 12.x system updates. Note that this emuiibo version (and next ones) won't work on older Atmosphere versions. | |||
*emutool: | |||
**No changes, only the version value was updated. | |||
'''v0.6.2 2021/02/04''' | |||
*(emutool didn't change for this new release, only the version number was updated.) | |||
*emuiibo: | |||
**Small nx library corrections/improvements. | |||
**Atmosphere 0.18.0 support (always use emuiibo with latest ams if it's supported!). | |||
'''v0.6.1 2020/10/28''' | |||
*emuiibo: | |||
**Fixed controller support - some games couldn't be used with detached JoyCons / other controllers on v0.6, that has been fixed on this version. | |||
**When exporting system miis on startup, now emuiibo doesn't use the mii's name as the mii folder's name, the mii's name is written to a name.txt file instead to avoid potential FS issues with non-UTF8 names, and the mii folder's name will just be an index. | |||
*emutool: | |||
**Added support for creating all available virtual amiibos at once - they will be organized in folders according to their series. | |||
'''v0.6 2020/09/26''' | |||
*emuiibo has been through a complete rewrite in Rust (except for the overlay), so everything has changed internally: | |||
**Support for latest Atmosphere (0.14.4), and next releases unless breaking changes are introduced. | |||
**emuiibo no longer handles conversion of raw amiibo dumps or old emuiibo formats - only the current format is supported (the one used since 0.5.x). | |||
**Heap size has been considerably reduced (last version used 0x40000, current one only uses 0x4000) - in addition, the exefs NSP's size has been reduced too, being now 5 times smaller than 0.5.x. | |||
**Regarding the known issues with time services and sysmodules, emuiibo no longer makes use of this service to avoid creating more issues, even though this implies that virtual amiibos' "last write date" won't be set when a virtual amiibo is modified - luckily, not emulating this anymore doesn't change anything relevant nor break anything. | |||
**emuiibo's IPC interface other processes may use to communicate with it has a minor change - thus, 0.5.x or older overlays WON'T WORK with this version's emuiibo. | |||
*emutool did not change at all. | |||
==Credits== | |||
*Everyone who contributed to the original nfp-mitm project (forks): Subv, ogniK, averne, spx01, SciresM. | |||
*libstratosphere project and libraries. | |||
*AmiiboAPI web API, which is used by emutool to get a proper, full amiibo list, in order to generate virtual amiibos. | |||
*3DBrew for their detailed documentation of amiibos, even though some aspects are different on the Switch. | |||
*LoOkYe for writing emuiibo's wiki and helping with support. | |||
*AD2076 and AmonRaNet for helping with the tesla overlay. | |||
*AmonRaNet for all the work he put into the overlay. | |||
*AmonRaNet, Impeeza, amazingfate, qazrfv1234, shadow2560 and SimoCasa for providing/helping with translations. | |||
*Thog / Ryujinx devs for reversing mii services and various of its types. | |||
*Citra devs for several amiibo formats used in 3DS systems. | |||
*Manlibear for helping with improvements and development of emutool. | |||
*All the testers and supporters from my Discord server who were essential for making this project progress and become what it is now. | |||
== External links == | == External links == | ||
* | * GitHub - https://github.com/XorTroll/emuiibo | ||
* Twitter - https://twitter.com/xortroll | |||
* GBAtemp - https://gbatemp.net/threads/emuiibo-mitming-nfp-services-for-amiibo-emulation.536210/ |
Revision as of 13:40, 28 April 2023
emuiibo | |
---|---|
General | |
Author | XorTroll |
Type | Utilities |
Version | 0.6.4 |
License | GPL-2.0 |
Last Updated | 2022/02/11 |
Links | |
Download | |
Website | |
Source | |
Support Author | |
emuiibo is a background process (and service) which Nintendo Switch's internal NFC (NFP) services to support virtual amiibo emulation.
Installation
You need to the following files:
- emuiibo (grab the latest release here)
- emutool (see emuiibo download above)
- Tesla (grab the latest Tesla-Menu and nx-ovlloader)
How to setup:
- Make sure you downloaded all files mentioned above.
- Create these folders on your SD (if not present):
sd:/emuiibo/amiibo
sd:/switch/.overlays
- Extract all ZIP files and copy the folders on your SD card. It should look like this in the end:
- emuiibo -
sd:/atmosphere/contents/0100000000000352/exefs.nsp
and/flags
folder - emuiibo overlay -
sd:/switch/.overlays/emuiibo.ovl
- tesla-menu -
sd:/switch/.overlays/ovlmenu.ovl
- nx-ovlloader -
sd:/atmosphere/contents/420000000007E51A/exefs.nsp
and/flags
folder
- emuiibo -
If you set up everything correctly, emuiibo is ready to load your amiibos you created via emutool (see below) or via raw .bin amiibo dump fules.
User guide
SD layout
- Emuiibo's directory is
sd:/emuiibo
.
- Virtual amiibos go inside
sd:/emuiibo/amiibo
. For instance, an amiibo namedMyMario
would besd:/emuiibo/amiibo/MyMario/<amiibo content>
.
- However, categories are supported by placing amiibos inside sub-directories (only inside a directory, like 3DS menu categories inside categories are not supported) - for instance:
sd:/emuiibo/amiibo/SSBU/Yoshi
would be aYoshi
amiibo insideSSBU
category.
- A virtual amiibo is detected by emuiibo based on two aspects: a
amiibo.json
and aamiibo.flag
file must exist inside the virtual amiibo's folder mentioned above. If you would like to disable a virtual amiibo from being recognised by emuiibo, just remove the flag file, and create it again to enable it.
- Every time the console is booted, emuiibo saves all the miis inside the console to the SD card. Format is
sd:/emuiibo/miis/<index> - <name>/mii-charinfo.bin
.
emutool - virtual amiibo creation
Emuiibo no longer accepts raw BIN dumps to emulate amiibos. Instead, you can use emutool
PC tool in order to generate virtual amiibos.
First we look on the left half of the program:
- In the first dropdown menu on top, you can choose amiibos from a certain collection.
- In the second dropdown menu next to it, you can choose any amiibo you want to create.
On the right half of the tool:
- You can choose a name for the amiibo you want to create, a custom directory name (if you uncheck "Use name as directory name" below it).
- You can then choose if you want the amiibo to use randomized UUIDs. This means that the console always read it as a new/unique amiibo (some games have restrictions to use the same amiibo only once or once a day). Note that this might cause issues for games which save data into amiibos, so avoid using it on those.
- Then, you can choose if you want to save the amiibo picture shown on the left into the amiibo folder (it will be saved as a PNG file).
Optional:
- If you have a FTP connection on your switch console, you can directly save your amiibo on your SD into: emuiibo/amiibo/.
In the last step you click on "Create virtual amiibo" and choose a location, where you want to save it to. If an SD card with emuiibo is detected, the program will point to that SD's /emuiibo/amiibo
folder.
Now you can copy the generated amiibo folder onto your SD card, in sd:/emuiibo/amiibo/
or sd:/emuiibo/amiibo/<category>/
- you can sort virtual amiibos by categories this way.
emuiibo basic controls
If you set up everything mentioned above, you're ready to use emuiibo ingame.
Tip: Enable it before you start a game, because it does not work in some games if you enable it after launching the game.
To open the Tesla overlay, hold down L1 + D-Pad Down and then press R3 (Right Stick). If you did it, Tesla Overlay will open on the left side of the screen. Now choose emuiibo.
In the emuiibo overlay:
- Manage emulation: enable/disable emuiibo via DPad or L3 (it´s disabled by default).
- View amiibo:
- Choose your amiibo from root (
sd:/emuiibo/amiibo/
). - Choose your amiibo from a category (
sd:/emuiibo/amiibo/<category>/
).
- Choose your amiibo from root (
To go back in the menus, just press B button.
After you selected an amiibo, you can see it's selected on top in the overlay and that it is "connected".
"Connected" is the equivalent of holding a real amiibo figurine/card on the NFC point. To "Disconnect" the amiibo (the equivalent of removing a real amiibo from the NFC point), just select the same amiibo again.
To see if emuiibo is working ingame, check if emuiibo is intercepting the game when it's trying to access amiibos. If it's not, try launching the game with emuiibo enabled first.
Example usage
- Open the overlay and choose emuiibo.
- Enable emuiibo.
- Start the game.
- Navigate to the games NFC feature to use the amiibo and activate it.
- Open the overlay and choose your amiibo (will be connected).
- The game should now register/make use of it.
- If the game tells you to remove the amiibo, disconnect it.
Options
- Emulation status (on/off):
- When emuiibo's emulation status is on, it means that any game trying to access/read amiibos will be intercepted by emuiibo.
- When it's off, it means that amiibo services will work normally, and nothing will be intercepted.
- This is basically a toggle to globally disable or enable amiibo emulation.
- Active virtual amiibo:
- it's the amiibo which will be sent to the games which try to scan amiibos, if emulation is on.
- Via tools such as the overlay, one can change the active virtual amiibo.
- Virtual amiibo status (connected/disconnected):
- When the active virtual amiibo is connected, it means that the amiibo is always "placed", as if you were holding a real amiibo on the NFC point and never moving it - the game always detects it.
- When it is disconnected, it means that you "removed" it, as if you just removed the amiibo from the NFC point.
- Some games might ask you to remove the amiibo after saving data, so you must disconnect the virtual amiibo to "simulate" that removal.
- This is a new feature in v0.5, which fixed errors, since emuiibo tried to handle this automatically in previous versions, causing some games to fail.
All this aspects can be seen/controlled via the overlay.
Supported figures
Some games (like Skylanders) make use of their particular NFC technology, aside from amiibos.
This project ONLY emulates amiibos; therefore, in Skylanders' case, only the two special figurines with amiibo support can be emulated here, where emuiibo will only emulate the "amiibo part" of them.
For developers
emuiibo hosts a custom service, also named emuiibo
, which can be used to control amiibo emulation by IPC commands.
The overlay's code can be a good example to see how to control emuiibo from IPC and C++.
Raw dumps and encryption
When using raw dumps, emuiibo doesn't save everything they have onto the new format, since some bits are encrypted. This is, for instance, why 20-heart Wolf Link amiibo dumps won't work with emuiibo, since the amiibo's app-area, where the console/game saves amiibo savedata, is an encrypted field, and it contains the information BOTW needs in order to recognize the feature.
You can manually extract it, using amiitool. You'll need to find the retail amiibo key to use it.
Running the following will decrypt the raw dump:
amiitool -d -k <key-file-bin> -i <amiibo-raw-dump-bin> -o <out-decrypted-bin>
You'll have the decrypted app-area section at offset 0xDC on the decrypted dump, of length 0xD8. By saving that as <game-access-id>.bin
inside the /areas
folder of a virtual amiibo being used by emuiibo, you can actually import the dump's savedata, which would allow for such things to work. Check below for a list of per-game access IDs.
Amiibo format
Amiibos are, as stated above, directories with an amiibo.json
and an amiibo.flag
file. The flag is mainly there in case people would like to disable an amiibo and then re-enable it later.
The JSON file contains all the aspects and data an amiibo needs to provide to games, except a few aspects (per-game savedata, protocol and tag type...)
This are the properties an amiibo has:
Name | The amiibo's name (max. 40 characters). |
---|---|
UUID | It's a unique identifier for the amiibo, composed of 10 bytes. If the "uuid" field is not present in the JSON, emuiibo will randomize the UUID everytime amiibo data is sent to a game. This has potential benefits in certain games, like in BOTW, where amiibos can only be used once per day, but with randomized UUIDs this can be bypassed, and one can get infinite rewards scanning this amiibo infinite times. |
Mii | Every amiibo has a mii associated with it (it's "owner"). Internally, miis consist on a 88-byte structure known as "charinfo", so emuiibo stores this data in a file (typically mii-charinfo.bin ). For new amiibos, emuiibo uses the console's services to generate a random mii, but for those who would like to use a mii from their console, emuiibo dumps in miis directory the console's miis, so it's just a matter of copying and pasting/replacing charinfo bin files. NOTE: emuiibo contains the charinfo file's name in the JSON (mii_charinfo_file ), so if the file ever gets renamed, don't forget to rename it in the JSON too, or emuiibo will generate a random mii for the file name in the JSON.
|
First and last write dates | These are (as if it wasn't obvious) the first and last time the amiibo was written/modified. When a virtual amiibo is created with emutool, the current date is assigned to both dates, and when the amiibo is modified in console, emuiibo updates the last write date. |
Write counter | This is a number which is increased everytime the amiibo is modified (and emuiibo does so, imitating Nintendo), but when the number reaches 65535, it is no longer increased (the number is technically a 16-bit number). |
Version | This value technically represents the version of Nintendo's amiibo library (NFP), so emuiibo just defaults it to 0. |
Areas
Areas (application areas, technically) are per-game amiibo savedata. Technically, real amiibos can only save data for a single game, but emuiibo allows as many games as you want (since savedata is stored as files). This savedata is quite small, and tends to be 216 bytes or smaller.
emuiibo saves this data inside bin files at areas
directory inside the amiibo's directory, and the bin file's name is the game's area access ID in hex format.
An access ID is a unique ID/number each game has for amiibo savedata, used to check if the game actually has savedata in an amiibo. Here's a list of games and their access IDs:
Per-game access IDs
A list is maintained at Switchbrew.
Screenshots
emuiibo
emutool
Media
How to use emuiibo with Tesla in switch - switch 10.2.0 Atmosphere 0.14.4 Animal crossing (TruganiniGamePlay)
Changelog
v0.6.3 2022/02/11
- emuiibo:
- Fixed some minor issues related to virtual amiibo area saving.
- Fixed a weird internal issue where sometimes emuiibo would become unaccessible under certain circumstances.
- overlay:
- The overlay has almost entirely changed thanks to the huge work of AD2076 and AmonRaNet:
- Really improved UI and design.
- Now, aside from English, the following languages are supported: German, Spanish, Russian, Traditional and Simplified Chinese.
- The overlay has almost entirely changed thanks to the huge work of AD2076 and AmonRaNet:
- emutool:
- No changes (not uploading a new release).
v0.6.3 2021/04/20
- emuiibo:
- Fixed support for latest Atmosphere versions (0.19.x) and for 12.x system updates. Note that this emuiibo version (and next ones) won't work on older Atmosphere versions.
- emutool:
- No changes, only the version value was updated.
v0.6.2 2021/02/04
- (emutool didn't change for this new release, only the version number was updated.)
- emuiibo:
- Small nx library corrections/improvements.
- Atmosphere 0.18.0 support (always use emuiibo with latest ams if it's supported!).
v0.6.1 2020/10/28
- emuiibo:
- Fixed controller support - some games couldn't be used with detached JoyCons / other controllers on v0.6, that has been fixed on this version.
- When exporting system miis on startup, now emuiibo doesn't use the mii's name as the mii folder's name, the mii's name is written to a name.txt file instead to avoid potential FS issues with non-UTF8 names, and the mii folder's name will just be an index.
- emutool:
- Added support for creating all available virtual amiibos at once - they will be organized in folders according to their series.
v0.6 2020/09/26
- emuiibo has been through a complete rewrite in Rust (except for the overlay), so everything has changed internally:
- Support for latest Atmosphere (0.14.4), and next releases unless breaking changes are introduced.
- emuiibo no longer handles conversion of raw amiibo dumps or old emuiibo formats - only the current format is supported (the one used since 0.5.x).
- Heap size has been considerably reduced (last version used 0x40000, current one only uses 0x4000) - in addition, the exefs NSP's size has been reduced too, being now 5 times smaller than 0.5.x.
- Regarding the known issues with time services and sysmodules, emuiibo no longer makes use of this service to avoid creating more issues, even though this implies that virtual amiibos' "last write date" won't be set when a virtual amiibo is modified - luckily, not emulating this anymore doesn't change anything relevant nor break anything.
- emuiibo's IPC interface other processes may use to communicate with it has a minor change - thus, 0.5.x or older overlays WON'T WORK with this version's emuiibo.
- emutool did not change at all.
Credits
- Everyone who contributed to the original nfp-mitm project (forks): Subv, ogniK, averne, spx01, SciresM.
- libstratosphere project and libraries.
- AmiiboAPI web API, which is used by emutool to get a proper, full amiibo list, in order to generate virtual amiibos.
- 3DBrew for their detailed documentation of amiibos, even though some aspects are different on the Switch.
- LoOkYe for writing emuiibo's wiki and helping with support.
- AD2076 and AmonRaNet for helping with the tesla overlay.
- AmonRaNet for all the work he put into the overlay.
- AmonRaNet, Impeeza, amazingfate, qazrfv1234, shadow2560 and SimoCasa for providing/helping with translations.
- Thog / Ryujinx devs for reversing mii services and various of its types.
- Citra devs for several amiibo formats used in 3DS systems.
- Manlibear for helping with improvements and development of emutool.
- All the testers and supporters from my Discord server who were essential for making this project progress and become what it is now.