Skip to content
This repository has been archived by the owner on Jul 17, 2023. It is now read-only.

Commit

Permalink
external USB HDD support exFAT and NTFS
Browse files Browse the repository at this point in the history
  • Loading branch information
dezem committed Dec 19, 2020
1 parent 6328b8a commit 5f8203d
Show file tree
Hide file tree
Showing 26 changed files with 938 additions and 170 deletions.
Binary file modified AtmoXL-Titel-Installer-Main.jpg
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ DATA := data
INCLUDES := include include/ui include/data include/install include/nx include/nx/ipc include/util include/Plutonium/Plutonium/Output-switch/include
APP_TITLE := AtmoXL Titel Installer
APP_AUTHOR := AtmoXL - forked from Awoo Installer by Huntereb & Behemoth
APP_VERSION := 1.3.5
APP_VERSION := 1.4.1
ROMFS := romfs

#---------------------------------------------------------------------------------
Expand All @@ -66,9 +66,9 @@ ASFLAGS := -g $(ARCH)
LDFLAGS = -specs=$(DEVKITPRO)/libnx/switch.specs -g $(ARCH) -Wl,-Map,$(notdir $*.map)

LIBS := `curl-config --libs` # Networking
LIBS += -lSDL2_mixer -lopusfile -lopus -lmodplug -lmpg123 -lvorbisidec -logg # Audio
LIBS += -lSDL2 -lc -lSDL2_ttf -lSDL2_mixer -lopusfile -lopus -lmodplug -lmpg123 -lvorbisidec -logg # Audio
LIBS += -lpu -lSDL2_gfx -lSDL2_image -lwebp -lpng -ljpeg `sdl2-config --libs` `freetype-config --libs` # Graphics
LIBS += -lmbedtls -lmbedcrypto -lminizip -lzstd # Memes
LIBS += -lz -lssh2 -lusbhsfs -lntfs-3g -lmbedtls -lmbedcrypto -lmbedx509 -lminizip -lnx -lstdc++fs -lzzip -lzstd # Memes

#---------------------------------------------------------------------------------
# list of directories containing libraries, this must be the top level containing
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ A No-Bullshit NSP, NSZ, XCI, and XCZ Installer for Nintendo Switch

## Features
- Installs NSP/NSZ/XCI/XCZ files and split NSP/XCI files from your SD card
- Installs NSP/NSZ/XCI/XCZ files and split NSP/XCI files from your USB HDD exFAT and NTFS (NTFS currently works only with AMS)
- Installs NSP/NSZ/XCI/XCZ files over LAN or USB from tools such as [NS-USBloader](https://github.com/developersu/ns-usbloader)
- Installs NSP/NSZ/XCI/XCZ files over the internet by URL or Google Drive
- Verifies NCAs by header signature before they're installed
Expand All @@ -19,3 +20,5 @@ A No-Bullshit NSP, NSZ, XCI, and XCZ Installer for Nintendo Switch
- Adubbz and other contributors for [Tinfoil](https://github.com/Adubbz/Tinfoil)
- XorTroll for [Plutonium](https://github.com/XorTroll/Plutonium) and [Goldleaf](https://github.com/XorTroll/Goldleaf)
- blawar and nicoboss for [NSZ](https://github.com/nicoboss/nsz) support
- blawar for [tinleaf](https://github.com/blawar/tinleaf)
- DarkMatterCore, XorTroll and Rhys Koedijk for [libusbhsfs](https://github.com/DarkMatterCore/libusbhsfs)
2 changes: 2 additions & 0 deletions include/ui/MainApplication.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include "ui/netInstPage.hpp"
#include "ui/sdInstPage.hpp"
#include "ui/usbInstPage.hpp"
#include "ui/usbHDDInstPage.hpp"
#include "ui/instPage.hpp"
#include "ui/optionsPage.hpp"

Expand All @@ -17,6 +18,7 @@ namespace inst::ui {
netInstPage::Ref netinstPage;
sdInstPage::Ref sdinstPage;
usbInstPage::Ref usbinstPage;
usbHDDInstPage::Ref usbhddinstPage;
instPage::Ref instpage;
optionsPage::Ref optionspage;
};
Expand Down
2 changes: 2 additions & 0 deletions include/ui/mainPage.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ namespace inst::ui {
void netInstallMenuItem_Click();
void usbInstallMenuItem_Click();
void settingsMenuItem_Click();
void usbHDDInstallMenuItem_Click();
void exitMenuItem_Click();
void onInput(u64 Down, u64 Up, u64 Held, pu::ui::Touch Pos);
Image::Ref titleImage;
Expand All @@ -25,6 +26,7 @@ namespace inst::ui {
pu::ui::elm::MenuItem::Ref installMenuItem;
pu::ui::elm::MenuItem::Ref netInstallMenuItem;
pu::ui::elm::MenuItem::Ref usbInstallMenuItem;
pu::ui::elm::MenuItem::Ref usbHDDInstallMenuItem;
pu::ui::elm::MenuItem::Ref settingsMenuItem;
pu::ui::elm::MenuItem::Ref exitMenuItem;
};
Expand Down
31 changes: 31 additions & 0 deletions include/ui/usbHDDInstPage.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#pragma once
#include <filesystem>
#include <pu/Plutonium>

using namespace pu::ui::elm;
namespace inst::ui {
class usbHDDInstPage : public pu::ui::Layout
{
public:
usbHDDInstPage();
PU_SMART_CTOR(usbHDDInstPage)
pu::ui::elm::Menu::Ref menu;
void startInstall();
void onInput(u64 Down, u64 Up, u64 Held, pu::ui::Touch Pos);
TextBlock::Ref pageInfoText;
void drawMenuItems(bool clearItems, std::filesystem::path ourPath);
Image::Ref titleImage;
TextBlock::Ref appVersionText;
private:
std::vector<std::filesystem::path> ourDirectories;
std::vector<std::filesystem::path> ourFiles;
std::vector<std::filesystem::path> selectedTitles;
std::filesystem::path currentDir;
TextBlock::Ref butText;
Rectangle::Ref topRect;
Rectangle::Ref infoRect;
Rectangle::Ref botRect;
void followDirectory();
void selectNsp(int selectedIndex);
};
}
28 changes: 28 additions & 0 deletions include/usbHDDInstall.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
/*
Copyright (c) 2017-2018 Adubbz
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/

#pragma once
#include <filesystem>
#include <vector>
namespace hddInstStuff {
void installNspFromFile(std::vector<std::filesystem::path> ourNspList, int whereToInstall);
}
2 changes: 1 addition & 1 deletion include/util/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
namespace inst::config {
static const std::string appDir = "sdmc:/switch/AtmoXL-Titel-Installer";
static const std::string configPath = appDir + "/config.json";
static const std::string appVersion = "1.3.5";
static const std::string appVersion = "1.4.1";

extern std::string gAuthKey;
extern std::string lastNetUrl;
Expand Down
6 changes: 6 additions & 0 deletions libusbhsfs.LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Copyright (c) 2020, DarkMatterCore <pabloacurielz@gmail.com>.
Copyright (c) 2020, XorTroll.

Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
19 changes: 18 additions & 1 deletion romfs/lang/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
"sd": "Von SD-Karte installieren",
"net": "Über LAN oder Internet installieren",
"usb": "Über USB installieren",
"hdd": "Über USB HDD installieren",
"set": "Einstellungen",
"exit": "Beenden"
},
"hdd": {
"title": "USB HDD",
"notfound": "USB HDD ist nicht angeschlossen."
},
"net": {
"title": "Netzwerk Verbindung nicht verfügbar",
"desc": "Überprüfe ob der Flugzeug-Modus deaktiviert ist und ob du mit einem lokalen Netzwerk verbunden bist"
Expand Down Expand Up @@ -62,7 +67,7 @@
"title": "Hilfe",
"desc": "Kopiere NSP, NSZ, XCI oder XCZ Dateien auf deine SD Karte,\nsuche nach ihnen und wähle die zu installierenden Titel aus und drücke dann \ue0b3."
},
"top_info": "Wähle Dateien zur Installation vom Server aus und drücke dann \ue0b3!",
"top_info": "Wähle Dateien zur Installation von der SD-Karte aus und drücke dann \ue0b3!",
"source_string": " von der SD Karte",
"delete_info": " installiert! Soll es von der SD-Karte gelöscht werden?",
"delete_info_multi": " Dateien erfolgreich installiert! Sollen diese von der SD-Karte gelöscht werden?",
Expand All @@ -81,6 +86,18 @@
"buttons": "\ue0e2 (Halten) Hilfe \ue0e1 (Halte) Abbrechen",
"buttons2": "\ue0e0 Datei auswählen \ue0e3 Alle auswählen \ue0ef Datei(en) installieren \ue0e1 Abbrechen"
},
"hdd": {
"help": {
"title": "Hilfe",
"desc": "Kopiere NSP, NSZ, XCI oder XCZ Dateien auf deine USB HDD,\nsuche nach ihnen und wähle die zu installierenden Titel aus und drücke dann \ue0b3."
},
"top_info": "Wähle Dateien zur Installation von der USB HDD aus und drücke dann \ue0b3!",
"source_string": " von der USB HDD",
"delete_info": " installiert! Soll es von der USB HDD gelöscht werden?",
"delete_info_multi": " Dateien erfolgreich installiert! Sollen diese von der USB HDD gelöscht werden?",
"delete_desc": "Die originalen Dateien werden nach der Installation nicht mehr benötigt",
"buttons": "\ue0e0 Datei auswählen \ue0e3 Alle auswählen \ue0ef Datei(en) installieren \ue0e1 Abbrechen"
},
"target": {
"desc0": "Wo soll ",
"desc1": " installiert werden?",
Expand Down
19 changes: 18 additions & 1 deletion romfs/lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
"sd": "Install from SD card",
"net": "Install over LAN or internet",
"usb": "Install over USB",
"hdd": "Install over USB HDD",
"set": "Settings",
"exit": "Exit"
},
"hdd": {
"title": "USB HDD",
"notfound": "USB HDD is not connected."
},
"net": {
"title": "Network connection not available",
"desc": "Check that airplane mode is disabled and you're connected to a local network."
Expand Down Expand Up @@ -62,7 +67,7 @@
"title": "Help",
"desc": "Copy your NSP, NSZ, XCI, or XCZ files to your SD card, browse to and\nselect the ones you want to install, then press the Plus button."
},
"top_info": "Select what files you want to install, then press the Plus button!",
"top_info": "Select what files you want to install from SD card, then press the Plus button!",
"source_string": " from SD card",
"delete_info": " installed! Delete it from the SD card?",
"delete_info_multi": " files installed successfully! Delete them from the SD card?",
Expand All @@ -81,6 +86,18 @@
"buttons": "\ue0e2 (Hold) Help \ue0e1 (Hold) Cancel",
"buttons2": "\ue0e0 Select File \ue0e3 Select All \ue0ef Install File(s) \ue0e1 Cancel"
},
"hdd": {
"help": {
"title": "Help",
"desc": "Copy your NSP, NSZ, XCI, or XCZ files to your USB HDD, browse to and\nselect the ones you want to install, then press the Plus button."
},
"top_info": "Select what files you want to install from USB HDD, then press the Plus button!",
"source_string": " from USB HDD",
"delete_info": " installed! Delete it from the USB HDD?",
"delete_info_multi": " files installed successfully! Delete them from the USB HDD?",
"delete_desc": "The original files aren't needed anymore after they've been installed",
"buttons": "\ue0e0 Select File \ue0e3 Select All \ue0ef Install File(s) \ue0e2 Help \ue0e1 Cancel"
},
"target": {
"desc0": "Where should ",
"desc1": " be installed to?",
Expand Down
19 changes: 18 additions & 1 deletion romfs/lang/es-419.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
"sd": "Instalar desde tarjeta SD",
"net": "Instalar a través de red local o Internet",
"usb": "Instalar por USB",
"hdd": "Instalar a través de USB HDD",
"set": "Ajustes",
"exit": "Salir"
},
"hdd": {
"title": "USB HDD",
"notfound": "El disco duro USB no está conectado."
},
"net": {
"title": "Conexión de red no disponible",
"desc": "Verifica que el modo avión esté deshabilitado y que estés conectado a una red."
Expand Down Expand Up @@ -62,7 +67,7 @@
"title": "Ayuda",
"desc": "Copia los archivos NSP, NSZ, XCI o XCZ a tu tarjeta SD, navega hacia ellos,\nselecciona los que quires instalar y luego pulsa el botón +."
},
"top_info": "¡Selecciona los archivos que quieres instalar, y pulsa el botón +!",
"top_info": "¡Selecciona los archivos que quieres instalar desde la tarjeta SD, y pulsa el botón +!",
"source_string": " desde la tarjeta SD",
"delete_info": " instalado. ¿Borrarlo de la tarjeta SD?",
"delete_info_multi": " archivos instalados con éxito. ¿Borrarlos de la tarjeta SD?",
Expand All @@ -81,6 +86,18 @@
"buttons": "\ue0e2 (Mantener) Ayuda \ue0e1 (Mantener) Cancelar",
"buttons2": "\ue0e0 Selecionar Archivo \ue0e3 Seleccionar Todo \ue0ef Instalar Archivo(s) \ue0e1 Cancelar"
},
"hdd": {
"help": {
"title": "Ayuda",
"desc": "Copia los archivos NSP, NSZ, XCI o XCZ a tu USB HDD, navega hacia ellos,\nselecciona los que quires instalar y luego pulsa el botón +."
},
"top_info": "¡Selecciona los archivos que quieres instalar desde la USB HDD, y pulsa el botón +!",
"source_string": " desde la USB HDD",
"delete_info": " instalado. ¿Borrarlo de la USB HDD?",
"delete_info_multi": " archivos instalados con éxito. ¿Borrarlos de la USB HDD?",
"delete_desc": "Los archivos originales no hacen falta después de ser instalados",
"buttons": "\ue0e0 Selecionar Archivo \ue0e3 Seleccionar Todo \ue0ef Instalar Archivo(s) \ue0e2 Ayuda \ue0e1 Cancelar"
},
"target": {
"desc0": "¿Dónde debería instalarse ",
"desc1": "?",
Expand Down
19 changes: 18 additions & 1 deletion romfs/lang/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
"sd": "Installer à partir de la carte SD",
"net": "Installer à partir d'un LAN ou d'internet",
"usb": "Installer à partir d'un périphèrique USB",
"hdd": "Installer sur un disque dur USB",
"set": " Paramètres",
"exit": " Quitter"
},
"hdd": {
"title": "Disque dur USB",
"notfound": "Le disque dur USB n'est pas connecté."
},
"net": {
"title": "Connection au réseau impossible",
"desc": "Vérifiez que le mode avion est désactivé et que vous êtes connecté à un réseau local."
Expand Down Expand Up @@ -62,7 +67,7 @@
"title": "Aide",
"desc": "Copiez vos fichiers NSP, NSZ, XCI ou XCZ sur votre carte SD, recherchez et\nsélectionnez ceux que vous voulez installer, puis appuyez sur le bouton Plus."
},
"top_info": "Sélectionnez les fichiers que vous voulez installer, puis appuyez sur le bouton Plus !",
"top_info": "Sélectionnez les fichiers que vous voulez installer à partir de la carte SD, puis appuyez sur le bouton Plus !",
"source_string": " à partir de la carte SD",
"delete_info": " Installation réussie! Supprimer de la carte SD?",
"delete_info_multi": " fichiers installés avec succès ! Les supprimer de la carte SD ?",
Expand All @@ -81,6 +86,18 @@
"buttons": "\ue0e2 (Maintenir) Aide \ue0e1 (Maintenir) Annuler",
"buttons2": "\ue0e0 Sélectionnez un fichier \ue0e3 Tout sélectionner \ue0ef Installer un/des fichier(s) \ue0e1 Annuler"
},
"hdd": {
"help": {
"title": "Aide",
"desc": "Copiez vos fichiers NSP, NSZ, XCI ou XCZ sur votre disque dur USB, recherchez et\nsélectionnez ceux que vous voulez installer, puis appuyez sur le bouton Plus."
},
"top_info": "Sélectionnez les fichiers que vous voulez installer à partir de la disque dur USB, puis appuyez sur le bouton Plus !",
"source_string": " à partir de la disque dur USB",
"delete_info": " Installation réussie! Supprimer de la disque dur USB?",
"delete_info_multi": " fichiers installés avec succès ! Les supprimer de la disque dur USB ?",
"delete_desc": "Les fichiers originaux ne sont plus nécessaires une fois qu'ils ont été installés.",
"buttons": "\ue0e0 Sélectionnez un fichier \ue0e3 Tout sélectionner \ue0ef Installer un/des fichier(s) \ue0e2 Aide \ue0e1 Annuler"
},
"target": {
"desc0": "",
"desc1": " doit-il être installé?",
Expand Down
19 changes: 18 additions & 1 deletion romfs/lang/it.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@
"sd": "Installa dalla SD",
"net": "Installa via LAN o da internet",
"usb": "Installa via USB",
"hdd": "Installa tramite USB HDD",
"set": "Impostazioni",
"exit": "Esci"
},
"hdd": {
"title": "USB HDD",
"notfound": "USB HDD non è collegato."
},
"net": {
"title": "Connessione alla rete non disponibile",
"desc": "Controlla che la modalità aereo sia disattivata e che tu sia connesso ad una rete."
Expand Down Expand Up @@ -62,7 +67,7 @@
"title": "Aiuto",
"desc": "Copia i tuoi file NSP, NSZ, XCI, o XCZ nella SD, cercali e\nseleziona quelli che vuoi installare, poi premi Il tasto Più."
},
"top_info": "Seleziona quali file vuoi installare, poi premi Il tasto Più!",
"top_info": "Seleziona quali file vuoi installare dalla SD, poi premi Il tasto Più!",
"source_string": " dalla SD",
"delete_info": " installato! Cancellarlo dalla SD?",
"delete_info_multi": " file installati correttamente! Cancellarli dalla SD?",
Expand All @@ -81,6 +86,18 @@
"buttons": "\ue0e2 (Tieni premuto) Aiuto \ue0e1 (Tieni premuto) Annulla",
"buttons2": "\ue0e0 Seleziona File \ue0e3 Seleziona tutto \ue0ef Installa i File \ue0e1 Annulla"
},
"hdd": {
"help": {
"title": "Aiuto",
"desc": "Copia i tuoi file NSP, NSZ, XCI, o XCZ nella USB HDD, cercali e\nseleziona quelli che vuoi installare, poi premi Il tasto Più."
},
"top_info": "Seleziona quali file vuoi installare dalla USB HDD, poi premi Il tasto Più!",
"source_string": " dalla USB HDD",
"delete_info": " installato! Cancellarlo dalla USB HDD?",
"delete_info_multi": " file installati correttamente! Cancellarli dalla USB HDD?",
"delete_desc": "I file originali non sono più necessari dopo averli installati",
"buttons": "\ue0e0 Seleziona File \ue0e3 Seleziona tutto \ue0ef Installa i File \ue0e2 Aiuto \ue0e1 Annulla"
},
"target": {
"desc0": "Dove vuoi installare ",
"desc1": " ?",
Expand Down

0 comments on commit 5f8203d

Please sign in to comment.