Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

3DS:Dump titles and game cartridges and Formatting an SD card/Linux: Difference between pages

From Hacks Guide Wiki
(Difference between pages)
change headings for consistency with other articles (Template:Anchor is used so old links can work)
 
Undo MSET9 Fresh mention - Linux
Tag: Undo
 
Line 1: Line 1:
{{TOC right}}{{info|text=For support (in English) with GodMode9, as well as help with scripting and to get updates and info, join [https://discord.gg/BRcbvtFxX4 GodMode9 on Discord].}}
This is an add-on section for formatting an SD card to FAT32.


Aside from creating and restoring NAND backups, GodMode9 has the functionality to dump installed titles to an installable <code>.cia</code> file, to dump game cartridge data to a <code>.3ds</code> ROM file, and to directly install a game cartridge to the system.
This page is for Linux users only. If you are not on Linux, check out the [[Special:MyLanguage/Formatting an SD card/Windows|Windows]] or [[Special:MyLanguage/Formatting an SD card/Mac|Mac]] pages.


== Updating GodMode9 ==
== Instructions ==
{{warning|Before beginning these steps, copy all of your SD card's contents to a folder on your computer.}}


{{info|text=These instructions are written for use with GodMode9 v2.0.0 or later. If you have an older version of GodMode9, follow these instructions to update it.}}
{{warning|The commands in this guide are case-sensitive. Enter them exactly as written, or there may be unintended consequences.}}
<tabber>
|-|fdisk=


=== What You Need ===
<span>
# Make sure your SD card is '''not''' inserted
# Open a terminal window and type <code>watch lsblk</code>
# Insert the SD card and watch for a new device appearing in lsblk
# Observe the output for the new device. It should match something like this: {{#tag:syntaxhighlight|
NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0    179:0    0  3,8G  0 disk
└─mmcblk0p1 179:1    0  3,7G  0 part /run/media/user/FFFF-FFFF
|lang=text}}
# Take note of the name of the device that now appears. In our example above, it was <code>mmcblk0p1</code>, but it could show up as <code>sda</code> or <code>sdb</code>, if you use a USB adapter
#* If <code>RO</code> is set to 1, make sure the lock switch is not slid down
# Hit CTRL + C to exit the menu
# Install the <code>fdisk</code> and <code>dosfstools</code> packages using your package manager of choice
# Type <code>sudo fdisk /dev/<device name></code>
# Enter <code>t</code> and then enter <code>0c</code>
# Enter <code>a</code> and then <code>p</code> - observe the output, and make sure the device is now formatted correctly
# If there are no issues, enter <code>w</code> - this will save changes and exit the fdisk prompt
# Type <code>sudo mkfs.vfat /dev/<device name>1 -s 64</code> to reformat the new partition
#* If the SD card is over 32GB in size, change <code>64</code> to <code>128</code>
# Type <code>sudo eject /dev/<device name></code>, then remove and reinsert the SD card
# Copy your data back onto the SD card
</span>


* The latest release of [https://github.com/d0k3/GodMode9/releases/latest GodMode9]
|-|cfdisk=


=== Instructions ===
<span>
# Make sure your SD card is '''not''' inserted
# Open a terminal window and type <code>watch lsblk</code>
# Insert the SD card and watch for a new device appearing in lsblk
# Observe the output for the new device. It should match something like this: {{#tag:syntaxhighlight|
NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0    179:0    0  3,8G  0 disk
└─mmcblk0p1 179:1    0  3,7G  0 part /run/media/user/FFFF-FFFF
|lang=text}}
# Take note of the name of the device that now appears. In our example above, it was <code>mmcblk0p1</code>, but it could show up as <code>sda</code> or <code>sdb</code>, if you use a USB adapter
#* If <code>RO</code> is set to 1, make sure the lock switch is not slid down
# Hit CTRL + C to exit the menu
# Install the <code>cfdisk</code> and <code>dosfstools</code> packages using your package manager of choice
# Type <code>sudo cfdisk /dev/<device name></code>
# Choose the <code>Delete</code> option and delete any existing partitions
# Choose the <code>New</code> option, keep partition size at the recommended size, and choose primary partition type
# Choose the <code>Type</code> option, scroll up until you see <code>b W95 FAT32</code> and select it
# Finally, choose the <code>Write</code> option.
# Choose the <code>Quit</code> option
# Type <code>sudo eject /dev/<device name></code>, then remove and reinsert the SD card
# Copy your data back onto the SD card
</span>


# Power off your device
|-|parted=
# Insert your SD card into your computer
# Copy <code>GodMode9.firm</code> from the GodMode9 <code>.zip</code> to the <code>/luma/payloads/</code> folder on your SD card
# Copy the <code>gm9</code> folder from the GodMode9 <code>.zip</code> to the root of your SD card
# Reinsert your SD card into your device
 
== Dumping a game cartridge<span class="anchor" id="Dumping a Game Cartridge"></span> ==
 
{{info|text=Insert the game cartridge you intend to dump into your device
* 3DS game cartridges will be dumped to a <code>.3ds</code> format
* NDS game cartridges will be dumped to a <code>.nds</code> format}}
 
# Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
# Navigate to <code>[C:] GAMECART</code>
# Follow the steps applicable to your game cartridge:
#* '''3DS Game Cartridge:''' Press {{B|A}} on <code>[TitleID].trim.3ds</code> to select it, then select <code>NCSD image options...</code>, then select <code>Decrypt file (0:/gm9/out)</code>.
#* '''NDS Game Cartridge:''' Press {{B|A}} on <code>[TitleID].nds</code> to select it, then select <code>Copy to 0:/gm9/out</code>
#** Trimmed dumps are not recommended for NDS games in general, as they can cause various playback issues
# Your non-installable <code>.3ds</code> or <code>.nds</code> formatted file will be outputted to the <code>/gm9/out/</code> folder on your SD card
 
== Installing a game cartridge directly to the system<span class="anchor" id="Installing a Game Cartridge Directly to the System"></span> ==
 
{{info|text=This will only work for 3DS games; it is not possible to install an NDS game cartridge to the system as a title.}}
 
# Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
# Navigate to <code>[C:] GAMECART</code>
# Press {{B|A}} on <code>[TitleID].trim.3ds</code> to select it, then select NCSD image options…, then select Install game image
# Press {{B|A}} to unlock SysNAND (lvl1) writing, then input the key combo given
# Once the process is complete, your game will show up in the HOME Menu as an installed title.
 
== Dumping a 3DS game cartridge to CIA<span class="anchor" id="Dumping a 3DS Game Cartridge to .CIA"></span> ==
 
{{info|text=This should only be used if [[#Installing a Game Cartridge Directly to the System|Installing a Game Cartridge Directly to the System]] does not work.}}
 
# Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
# Navigate to <code>[C:] GAMECART</code>
# Press {{B|A}} on <code>[TitleID].trim.3ds</code> to select it, then select NCSD image options…, then select Build CIA from file
# Your installable <code>.cia</code> formatted file will be outputted to the <code>/gm9/out/</code> folder on your SD card
 
== Dumping an installed title<span class="anchor" id="Dumping an Installed Title"></span> ==
 
{{info|text=This allows dumping of both System- and User-installed digital titles, such as ones downloaded from the eShop.}}
 
# Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
# Press {{B|Home}} to bring up the action menu
# Select Title manager
# Select one of the following depending on the type of title you wish to dump
#* '''User Installed Title''': <code>[A:] SD CARD</code>
#* '''System Title / DSiWare''': <code>[1:] NAND / TWL</code>
# Select the title you wish to dump
# Select Manage Title…
# Select Build CIA (standard)
# Your installable <code>.cia</code> formatted file will be outputted to the <code>/gm9/out/</code> folder on your SD card
 
== Backup GBA VC saves<span class="anchor" id="Backup GBA VC Saves"></span> ==
 
{{info|text=The game will be outputted to the <code>/gm9/out/</code> folder on your SD card with the name <code>&lt;TitleID&gt;.gbavc.sav</code>.}}
 
{{info|text=To identify a <code>&lt;TitleID&gt;.gbavc.sav</code> file’s Title ID, you can get a listing of all games on the system and their corresponding Title IDs by pressing {{B|Home}} to bring up the action menu, selecting <code>Title manager</code>, and selecting <code>[A:] SD CARD</code>.}}
 
# Do the following process for each GBA VC game that you want to back up the save for:
 
* Launch the GBA VC game
* Exit the GBA VC game
* Power off your device
* Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
* Navigate to <code>[S:] SYSNAND VIRTUAL</code>
* Press {{B|A}} on <code>agbsave.bin</code> to select it
* Select AGBSAVE options…
* Select Dump GBA VC save
* Press {{B|A}} to continue
* Press {{B|Start}} to reboot your device
 
== Restore GBA VC saves<span class="anchor" id="Restore GBA VC Saves"></span> ==
 
{{info|text=To identify a <code>&lt;TitleID&gt;.gbavc.sav</code> file’s Title ID, you can get a listing of all games on the system and their corresponding Title IDs by pressing {{B|Home}} to bring up the action menu, selecting <code>Title manager</code>, and selecting <code>[A:] SD CARD</code>.}}
 
# Do the following process for each GBA VC game that you want to restore the save for:
#* Launch the GBA VC game
#* Exit the GBA VC game
#* Power off your device
#* Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
#* Navigate to <code>[0:] SDCARD</code> -&gt; <code>gm9</code>
#* Press {{B|Y}} on the <code>&lt;TitleID&gt;.gbavc.sav</code> file you wish to restore to copy it
#* Press {{B|B}} to return to the main menu
#* Navigate to <code>[S:] SYSNAND VIRTUAL</code>
#* Press {{B|A}} on <code>agbsave.bin</code> to select it
#* Select AGBSAVE options…
#* Select Inject GBA VC save
#* Press {{B|A}} to continue
#* Press {{B|Start}} to reboot your device
#* Launch the GBA VC game
#* Exit the GBA VC game
 
== Encrypting / Decrypting a CIA file<span class="anchor" id="Encrypting / Decrypting a .CIA file"></span> ==
 
{{info|text=For organizational purposes, copy each <code>.cia</code> file you wish to encrypt / decrypt to the <code>/cias/</code> folder on your SD card}}
 
# Press and hold {{B|Start}}, and while holding {{B|Start}}, power on your device. This will launch GodMode9
# Navigate to <code>[0:] SDCARD</code> -&gt; <code>cias</code>
# Press {{B|A}} on the <code>.cia</code> file to select it, then select CIA image options…
# Select the option to perform the desired function:
#* '''Encrypt to 0:/gm9/out:''' Create an encrypted copy of the selected <code>.cia</code> file in the <code>/gm9/out/</code> folder on your SD card
#* '''Decrypt to 0:/gm9/out:''' Create a decrypted copy of the selected <code>.cia</code> file in the <code>/gm9/out/</code> folder on your SD card
#* '''Encrypt inplace:''' Replace the selected <code>.cia</code> file with an encrypted version
#* '''Decrypt inplace:''' Replace the selected <code>.cia</code> file with a decrypted version
# Your encrypted / decrypted <code>.cia</code> will be outputted to the desired location


<span>
# Make sure your SD card is '''not''' inserted
# Open a terminal window and type <code>watch lsblk</code>
# Insert the SD card and watch for a new device appearing in lsblk
# Observe the output for the new device. It should match something like this: {{#tag:syntaxhighlight|
NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0    179:0    0  3,8G  0 disk
└─mmcblk0p1 179:1    0  3,7G  0 part /run/media/user/FFFF-FFFF
|lang=text}}
# Take note of the name of the device that now appears. In our example above, it was <code>mmcblk0p1</code>, but it could show up as <code>sda</code> or <code>sdb</code>, if you use a USB adapter
#* If <code>RO</code> is set to 1, make sure the lock switch is not slid down
# Hit CTRL + C to exit the menu
# Install the <code>parted</code> and <code>dosfstools</code> packages using your package manager of choice
# Type <code>sudo parted /dev/<device name> mklabel msdos</code>
# Type <code>sudo parted -a opt /dev/<device name> mkpart primary fat32 0% 100%</code>
# Type <code>sudo eject /dev/<device name></code>, then remove and reinsert the SD card.
# Copy your data back onto the SD card.
</span>
</tabber>
{{hg imported|Guide_3DS}}
{{hg imported|Guide_3DS}}


[[Category:Nintendo 3DS guides]]
[[Category:General guides]]

Revision as of 18:16, 11 April 2024

This is an add-on section for formatting an SD card to FAT32.

This page is for Linux users only. If you are not on Linux, check out the Windows or Mac pages.

Instructions

Warning icon Before beginning these steps, copy all of your SD card's contents to a folder on your computer.
Warning icon The commands in this guide are case-sensitive. Enter them exactly as written, or there may be unintended consequences.

  1. Make sure your SD card is not inserted
  2. Open a terminal window and type watch lsblk
  3. Insert the SD card and watch for a new device appearing in lsblk
  4. Observe the output for the new device. It should match something like this:
    NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
    mmcblk0     179:0    0   3,8G  0 disk
    └─mmcblk0p1 179:1    0   3,7G  0 part /run/media/user/FFFF-FFFF
    
  5. Take note of the name of the device that now appears. In our example above, it was mmcblk0p1, but it could show up as sda or sdb, if you use a USB adapter
    • If RO is set to 1, make sure the lock switch is not slid down
  6. Hit CTRL + C to exit the menu
  7. Install the fdisk and dosfstools packages using your package manager of choice
  8. Type sudo fdisk /dev/<device name>
  9. Enter t and then enter 0c
  10. Enter a and then p - observe the output, and make sure the device is now formatted correctly
  11. If there are no issues, enter w - this will save changes and exit the fdisk prompt
  12. Type sudo mkfs.vfat /dev/<device name>1 -s 64 to reformat the new partition
    • If the SD card is over 32GB in size, change 64 to 128
  13. Type sudo eject /dev/<device name>, then remove and reinsert the SD card
  14. Copy your data back onto the SD card

  1. Make sure your SD card is not inserted
  2. Open a terminal window and type watch lsblk
  3. Insert the SD card and watch for a new device appearing in lsblk
  4. Observe the output for the new device. It should match something like this:
    NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
    mmcblk0     179:0    0   3,8G  0 disk
    └─mmcblk0p1 179:1    0   3,7G  0 part /run/media/user/FFFF-FFFF
    
  5. Take note of the name of the device that now appears. In our example above, it was mmcblk0p1, but it could show up as sda or sdb, if you use a USB adapter
    • If RO is set to 1, make sure the lock switch is not slid down
  6. Hit CTRL + C to exit the menu
  7. Install the cfdisk and dosfstools packages using your package manager of choice
  8. Type sudo cfdisk /dev/<device name>
  9. Choose the Delete option and delete any existing partitions
  10. Choose the New option, keep partition size at the recommended size, and choose primary partition type
  11. Choose the Type option, scroll up until you see b W95 FAT32 and select it
  12. Finally, choose the Write option.
  13. Choose the Quit option
  14. Type sudo eject /dev/<device name>, then remove and reinsert the SD card
  15. Copy your data back onto the SD card

  1. Make sure your SD card is not inserted
  2. Open a terminal window and type watch lsblk
  3. Insert the SD card and watch for a new device appearing in lsblk
  4. Observe the output for the new device. It should match something like this:
    NAME        MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
    mmcblk0     179:0    0   3,8G  0 disk
    └─mmcblk0p1 179:1    0   3,7G  0 part /run/media/user/FFFF-FFFF
    
  5. Take note of the name of the device that now appears. In our example above, it was mmcblk0p1, but it could show up as sda or sdb, if you use a USB adapter
    • If RO is set to 1, make sure the lock switch is not slid down
  6. Hit CTRL + C to exit the menu
  7. Install the parted and dosfstools packages using your package manager of choice
  8. Type sudo parted /dev/<device name> mklabel msdos
  9. Type sudo parted -a opt /dev/<device name> mkpart primary fat32 0% 100%
  10. Type sudo eject /dev/<device name>, then remove and reinsert the SD card.
  11. Copy your data back onto the SD card.