Repository navigation
Releases
SW2Transfer 2.0.0
Background plugin
SW2Transfer can now also run as a kaiHEN plugin, so transfers work from the moment the console starts, even while a game is running, without the app open.
- Install it from the app: press A for the plugin panel, A again, then restart the console. The plugin travels inside the app; there is nothing else to download.
- Same address, password and multi-connection transfers, over the web page, the command line and FTP.
- While it runs, the app is its screen: it shows the plugin's transfers, speed and log, and Password, Cancel all and Help work as usual. The web page shows a Background badge.
- The panel shows the installed version, offers updates when the app has a newer plugin, and can stop it until restart or uninstall it.
- If the console ever fails to start with it, delete
/kaihen/plugins/sw2transfer.nsofrom the SD card.
FTP
Any FTP client can connect on port 6700 (passive mode), from the app or the plugin. About 28 MB/s up and 19 MB/s down in tests, around 3 times ftpd; REST works for uploads and downloads, so clients that move files in parts get more. With a password set, FTP asks for it.
App
- On-screen buttons that can be tapped.
- New layout: web and FTP addresses side by side with the password status; Transfers and a Log panel under the speed graph; each transfer shows whether it came by web page, command line or FTP.
- The speed graph keeps scrolling until it is clear after a transfer.
Web page and command line
- Each file has a Download button; clicking a file ticks it. Download selected saves several items, or whole folders, as one
transfer.zip(up to 1.5 GB; past that it offers to download the files one by one, or recommends the command line when folders are involved). - Files that are already there are found when their turn comes: asked once to Overwrite all, Skip all or Cancel transfer. On the command line,
--overwrite-existingor--skip-existingdecide ahead of time.
Fixes
- With many connections open, the Switch's socket memory could run out and stall every connection on the console (ftpd too). Socket buffers and connection limits were reworked; tested with up to 64 files at once.
- Uploads start straight away when files are added on the web page.
Install
Copy sw2transfer.nro to sdmc:/switch/sw2transfer/ (replacing the old one) and launch it from hbmenu. Download the updated sw2xfer.py too if you use the command line.
SW2Transfer 1.4.3
Fixed
- Network stall under load. With more than about 12 connections open, the Switch's socket memory ran out and every connection on the console stalled (ftpd included) until SW2Transfer was closed. Socket buffers are now 1 MB (as fast as before in tests: 46 MB/s on one connection, 54 MB/s on 8), and the app never has more than 16 connections open, 8 transfers moving data or 24 files open. Tested with up to 64 files at once.
- The Switch's transfers panel no longer keeps showing a file as running after its connection ended mid-transfer.
Faster with many files
Up to 4 files now move at once, one connection each; connections with no file of their own help a big file with its next chunks, so a file on its own still uses all 8 connections. Applies to the web page (uploads) and sw2xfer.py (uploads and downloads).
100 typical emulator files (saves, configs, box art, ROMs; 21.6 MB):
| Time | Speed | |
|---|---|---|
| SW2Transfer 1.4.3 | 0.9 s | 23 MB/s |
| SW2Transfer 1.4.0 | 3.0 s | 7.2 MB/s |
| FTP (kaiHEN ftpd) | 3.9 s | 5.5 MB/s |
Other changes since 1.4.0
- Web page shows the current folder clearly (and in the tab title).
- Finished rows on the Switch show how many connections the file used.
- The graph label on the Switch has a backing so bars behind it don't hide it.
GET/PUT /api/speed: memory-only network speed test (no SD card access).
Install
Copy sw2transfer.nro to sdmc:/switch/sw2transfer/ (replacing the old one) and launch it from hbmenu. Download the updated sw2xfer.py too if you use the command line.
SW2Transfer 1.4.0
First release of SW2Transfer: a multi-connection file transfer and file management server for the Switch 2 (hbmenu under kaiHEN).
| Upload to Switch | Download from Switch | |
|---|---|---|
| SW2Transfer, 8 connections (default) | 51 MB/s | 43 MB/s |
| SW2Transfer, 1 connection | 28 MB/s | 21 MB/s |
| FTP (kaiHEN ftpd) | 8.6 MB/s | 9.5 MB/s |
Measured with a Mac and the Switch 2 both on Wi-Fi, moving a 256 MB file.
Install
Copy sw2transfer.nro to sdmc:/switch/sw2transfer/ and launch it from hbmenu, then open the address it shows (http://<switch-ip>:6967) in a browser on the same network.
Features
- Web page: upload files and whole folders (drag and drop), download, each file split across several connections
- File management: sortable Name / Size / Created / Modified columns, new folder, rename, delete, multi-select copy and move with a folder picker
- Cancel all transfers and copies from the web page, the Switch (X twice) or the command line; unfinished uploads and copies are cleaned up
sw2xfer.pycommand-line client (Python 3; Mac, Linux, Windows):upload,download,ls,mkdir,rm,mv,cancel,logout,bench- Switch screen with live speed, per-file progress and help (Y)
Password protection
Password protection is off by default: until you set a password, anyone on your network can read, change or delete files on the SD card while the app is open.
- Press − on the Switch to set a password with the on-screen keyboard (twice, to confirm); press − again and leave it blank to remove it.
- The web page and
sw2xfer.pythen ask for it, and stay signed in for 12 hours.sw2xfer.py logoutand the page's Sign out end it early;SW2XFER_PASSWORDsupplies it to scripts. - Changing or removing the password signs everyone out. After 5 wrong passwords in a row, sign-in is refused for 30 seconds.
- Only a salted hash is stored. Traffic is plain HTTP, so this keeps people on your network out; it is not protection on an untrusted network.
Check downloads with shasum -a 256 -c SHA256SUMS.