BAGPlug (SCDS2 Entry)

Discussion in 'NDS - Emulation and Homebrew' started by BassAceGold, Mar 26, 2011.

  1. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
    BAGPlug Release 3-5 fix 1:

    A replacement plugin menu for the Supercard DSTwo

    Notable features & Quick instructions

    - (OPTIONAL RECOMMENDED) format sd card to FAT16/FAT (cards 4gb or less)
    - Place _bagui folder on root of card
    - Copy DSTwo.nds and boot.ini to _dstwo folder on root of card
    -(OPTIONAL) Configure emulator support via arg files (See "Adding new file support:" below). Binary locations may need
    to be updated to their current path on your card.
    [Skinning support]
    -png files, 8 bit, 16 bit, 24 bit and 32 bit bitmap files
    *NOTE* backgrounds must be 16 or 24 bit bmp so fast rendering can be used for a smoother browser
    -Windows and sub windows are just color codes defined via the skin.ini file. These color values are 16 bit colors,
    the included ColorConvert.exe program can be used for converting 24 bit RGB color values to 16 bit color values
    (PA_RGB in the program)
    [Custom icons]
    -uses 32 x 32 bitmap or png files
    -must be named the same as the file with and in the same directory OR they can be placed in a directory as defined
    in the current skin.ini under "Custom_Icon_Folder".
    BAGSFC.plg - the file you want to have a custom icon
    BAGSFC.plg.png/BAGSFC.plg.bmp- the icon file
    [Game Covers]
    - 16 bit and 24 bit bitmaps, or any format of png file supported. Transparency effects will not be used for performance purposes
    - can be any size as long as it fits on screen
    - can be either png or bmp files
    - must be named exactly the same as the game file including the file extension (see note below for commercial roms)
    -CoverArt.ini file must be present in the same directory as the media/game files
    ini file example:
    [Cover Art]
    #path to folder with covers
    folder = /_bagui/cover art/nds
    #image type
    type = png
    *Commercial NDS roms use the game ID for covers and do not need the file extension in the title of the cover file.
    [Media Player]
    -Mp3, Ogg, Wav supported.
    -All songs in current directory as the current song being played are automatically queued for automatic track changes
    -Music player can be backgrounded (Press X or the backgrounding icon) for file browsing while listening to tunes
    -an audio file can be set to launch on boot. Press select on a supported audio file and select "set boot song" option.
    -a boot song can be removed by selecting the option to do so when select is pressed on any supported audio file.
    [Settings menu]
    -Allows to instantly swap skins with no rebooting
    -Contains settings for various display options
    -contains settings for setting CPU clock speeds for various actions
    [Hiding Files / Folders]
    -Files and Folders can be hidden from view simply by adding them to the hiddenfiles.txt and hiddenfolders.txt files in /_bagui/user files/ folder
    -Files and Folders can also be hidden while in the menu by pressing select on the desired file or folder, and selecting the hide option.
    [Supported File formats]
    -Standard supported files include PLG, NDS (homebrew and commercial via EOS 1.11), SNES file formats (including zip archives), Mp3, Wav, Ogg, .mpc (mario paint composer DS files), .bmp (Etch)
    -New file formats can be added via arg files (in /_bagui/ext folder) for programs which can accept boot args
    -File formats can be set to open in multiple different programs
    --eg: a zip file can contain a snes rom or a gba rom, a pop up will come up and ask which program to launch said file in. This program list can be edited in the arg files for the specified file type
    [Adding new file support]
    Programs that support launch arguements can be used open specific files selected within BAGplug. For example an emulator such as nesDS which can open .nes files.
    *Example setup using nesDS*
    First, a .arg file must be created in /_bagui/ext/ which will contain the instructions for launching .nes files within the menu.
    The name format of .arg files is quite simply the extension of the file format to support with a .arg extension. In this case, the file will be called "nes.arg".
    Format of .arg files
    nesDS://Title of the program
    "/_bagui/nesDS/nesDS.nds"//file path to program
    [$PRGMPATH$,$FILEPATH$]//launch arguments
    //-EOSSETTINGS//use default supercard menu to launch the file if necessary
    - $PRGRMPATH$ will pass on the file location of the launched program to the program itself, this is standard.
    - $FILEPATH$ will pass on the rom location from the menu to the program, this is what is needed for the program to load the correct file.
    - There are no limits as to how many arguements to pass on to a program however the program will only take what it needs.
    - Order of args may vary depending on programs, so be sure to watch out for that
    - The -EOSSETTINGS flag can be added to program arg which will have BAGplug use EOS (1.11 and up) to launch the file. This can be used for homebrew that have issues
    with the default launcher, or if you would want to multiboot different versions of EOS.
    More than one program can be added to a .arg file. When the file is launched,
    the open with dialog will open allowing you to choose which program to use. See smc.arg for an example
    Individual arg files can be created for specific files and will have priority over global arg files.
    These files must be in the same directory with the same name as the file eg. super mario kart.smc / super mario kart.smc.arg
    [Favorites menu]
    -Any supported file type can be linked in this menu (snes roms, zip files, nds roms, image files, ogg and wav files, etc)
    -Favorites list is just a text file containing file paths to all the files you want to save for quick launching
    -Can add files to the favorites list via the normal browser, or remove files within the favorites menu (select button)
    -Pressing /select/ on a file or folder brings up the file operations menu where you can selected an option
    -Files will be pasted in the current directory you are browsing regardless of what is high-lighted
    -All menu have some sort of pad and stylus input
    -if L and R buttons are pressed, you can take a screenshot of the both screens
    -NDS roms can be zipped with NitroZip to save space on the SD card when the roms are not in use.
    -BAGPlug keeps track of which roms are unzipped, these roms can be viewed by clicking the nzip icon on the side bar. This icon only appears when at least 1 rom has been unzipped
    -Once a rom is unzipped, it won't need to be unzipped again unless it is deleted in the NZIP manager.
    -There is no limit to how many roms can be left unzipped at a time, it is up to the user to ensure there is enough free space on the SD card to unzip future roms.

    Change log
    Release 3 - 5:
    -top screen is now force updated when taking screen shots
    -screen shots are now saved in */_bagui/screen shots/
    -screens are now turned off, then on again when taking screen shots (screen shot feedback)
    -new screen shot naming scheme
    -improved coverart.ini organization
    Release 3 - 4:
    Includes fixes 3 - 1
    -fixed copy/cut & paste corruption
    Includes fixes 3 - 2
    -fixed boot song not loading
    -fixed a stylus input error in nzip manager
    -fixed unzipped files not being added to unzipped.txt
    -slightly optimized nds icon loading
    3-4 changes:
    -_bagui folder can now be placed anywhere on the SD card, as long as the DSTwo.nds file from this release is used for loading
    -improved failsafe launching in DSTwo.nds
    -updated manual.txt
    Make sure to update all the required file paths when moving the _bagui folder (boot.ini, *.arg files, skin.ini files, etc)
    Release 3 - 3:
    -can now hide files and folders within BAGplug
    -fixed memory leak in file ops menu
    -fixed favorites list refreshing
    -contains 3-2 fixes 1 and 2
    -all external lists (favorites, hiddenfiles, hiddenfolders, unzipped) are automatically updated based on if the file/folder does not exist or has the wrong path
    -error messages for file support are now loaded from language.ini
    -Etch and Mario Paint Composer DS are now included and configured
    *Upgrade Notes*
    -language.ini has been updated
    Release 3 - 2:
    -fixed exiting of "open with" sub menu
    -added -EOSSETTINGS flag for arg files which forces BAGplug to fill in globalsettings.ini for the launched program. (internal launcher will launch the default EOS version installed for commercial roms)
    *Upgrade Notes*
    -nds.arg has been updated to show use of -EOSSETTINGS flag
    Release 3 - 1:
    -fixed freezing in favorites when scrolling
    -fixed audio skipping when entering directories with lots of files
    -fixed memory corruption in DSTwo.nds breaking arg support for .plg files. Should be more robust for various sd cards/formats now
    -improved memory management for icons
    -fixed stylus input in open with menu
    -fixed memory leaks in graphics loading/cloning functions of core library - cleaning up nds icon handling and no file icon corruption
    -fixed icon transparecy support
    -improved open with handling in favorites menu
    -improved performance in favorites menu with game covers
    -improved performance in scrolling nds files in browser
    -covers for non-commercial nds files require the file extension in the cover name. eg: game.nes / game.nes.png
    -improved minimizing from media player to current menu
    -fixed freezing when deleting favorites
    -fixed crashing when entering EOS Settings
    -improved scroll bar handling
    -optimized nds icon loading
    -optimized directory scanning
    -added option to enable nds icon transparency
    -improved handling of text lists (favorites, hidden files / folders)
    -favorites.txt, hiddenfiles.txt, hiddenfolders.txt, and settings.ini now go in /bagui/user files/ folder
    -nzip support added with built in nzip manager for deleting unzipped games
    -nzip cpu speed option added to settings
    -optimized top screen refreshing in main browser
    -misc bug fixes
    -NitroZip tool included
    -added "NZIP" section to readme
    -modified the "Adding new file support" section to include information on file specific arg files in readme
    -updated "Game Covers" section in readme
    *upgrade notes*
    -New skin parts: delete, exit, nzip, selectall -see BAGplug 3.0 or Default skin for examples
    -more text added to language.ini
    -favorites.txt, hiddenfiles.txt, hiddenfolders.txt, settings.ini, unzipped.txt all go in /_bagui/user files/
    -nzip.arg added to /_bagui/ext/ folder
    Release 3:
    -fixed eos settings appearing in favorites screen for non-nds files
    -unicode strings are now written in extlink.dat
    -fixed custom icons not loading when in the same directory as the file
    -custom icons now need to include the extension of the file it is for in the file name (BAGSFC.plg / BAGSFC.plg.png)
    -improved handling of globalsettings.ini
    -added unicode support to text, all text is now loaded externally for easy translations. A new font will need to be created to support all characters
    -added stylus double clicking to favorites menu
    -fixed browser scrolling glitches after changing skins
    -minor UI tweaks
    -DSGAME.nds is now recognized as homebrew rather than a commercial game
    -new skin: BAGPlug 3.0
    -updated DSTwo.nds with homebrew menu 2.0 loader
    Release 2 - 9:
    -fixed file sorting on root skipping an item
    -can toggle whether to hide favorited items in the browser or not. Directory display does not get updated until re-entry
    if a new file is added to your favorites (This is not a bug, it prevents lag in folders with lots of files).
    -custom icons can either be png or bitmap files and do not need a .ico extension anymore
    -improved stylus controls in the settings and open with menus
    -added EOS Settings for roms, (press select on a commercial rom or Y in favorites). This lets you switch between clean/patch mode, turn cheats on/off and select one of the multi saves.
    Release 2 - 8:
    -AM/PM is no longer displayed on 24 hour clock
    -no longer tries to open last folder if that folder doesn't exist
    -added ability to preview skins - press Y when highlighting a skin the the settings menu ->new section in skin.ini
    -enterLastDirWhenBoot in the globalsettings.ini is now set to 1 when launching a rom, auto run in the DSTwo menu requires it set to 1.
    -fixed some icon mix ups in the browser
    Release 2 - 7:
    -added extlink support
    -improved internal DS name displaying
    -removed the show all files option in settings
    -removed hide folders setting in favor of using hiddenfolders.txt
    -fixed a memory leak in the favorites menu
    -tweaked favorites menu loading
    -added hiddenfiles.txt support
    -fixed an error in extensions handling in the browser
    Release 2 - 6:
    -added ability to create a list of hidden folders using "hiddenfolders.txt" in the /_bagui/ folder. One folder is listed per line with no ending '/'. eg. to hide the "_bagui" folder -> /_bagui
    -fixed issue with back paging through a directory and icons not loading properly
    -fixed issue where DSGAME would display a blank name when using internal nds file names
    -can now set the favorites menu to auto show on boot
    -can now set an audio file to play on boot (press select on an audio file)
    Release 2 - 5:
    -added Properties menu which contains info on file types, size and for nds roms, the game ID
    -fixed memory corruption in nds internal name caching
    -other tiny fixes
    Release 2 - 4:
    -fixed backgrounding and returning from media player in sub menus
    -fixed memory leak in song loading
    -added 24 hour clock option
    -fixed nds internal names
    -fixed the day display on the clock
    -covers are now loaded in the favorites menu
    -fixed a memory leak with favorites icons
    -included a font creation program - dsFont
    Release 2 - 3:
    -fixed freezing when accessing an empty favorites list
    -favorites menu now ignores blank lines in the favorites.txt
    -fixed glitch with music playing and the file options menu
    -fixed issue with internal nds names while listening to music
    -fixed a bug where the stylus couldn't select bottom half of files in directories with few files/folders
    -can now use left and right on the d-pad to select cpu frequency in options
    -fixed a bug in shortening names with more than one '.'
    Release 2 - 2:
    -fixed a small memory leak
    -added the option to display internal nds file names
    -fixed division by 0 error when in favorites menu with exactly 15 favorites
    -fixed cursor flickering issue
    Release 2 - 1:
    - nds covers are now identified using game id's
    Release 2:
    -increase max files per folder to 1024 and max folders to 64
    -fixed a memory leak in skin listing
    -fixed menu icons updating on skin changes
    -improved file icon handling, common icons are now cached when loaded
    -added page scrolling in main browser using left and right on the d-pad
    -fixed png support for graphics
    -added the option change cpu settings for various menu portions
    -improved windowing
    -stylus & pad support for all menus
    -fixed media player freeze when launching audio from root directory
    -added cut, copy, paste actions to filebrowser
    -can now add and remove favorites
    -changed background music controls (L and R now change tracks)
    -added mp3 support to media player
    -added ability to have a background for the favorites menu
    -added scrolling to the favorites menu
    -added ability to enable or disable short names in the favorites menu
    -media player is now fully customizable
    -added commercial rom support via EOS 1.11
    -CATSFC has been added as an alternative choice for snes games
    -much faster file sorting
    -custom icons can be set to be loaded from a folder on a per skin basis
    -can now hide or display file extensions
    -fixed various issues with windows and flickering
    -added top screen background
    -added cover art display on top screen
    FAT16 is highly recommended over FAT32 for a considerable speed boost in loading and browsing. The Supercard seems to support FAT16 using 64kb clusters which should cover sd cards up to 2tb.
    Release 1:
    initial release

    [​IMG] [​IMG]

    Download here
    Latest DSTwo.nds (3DS, NDS arg, and boot garbage fixed)

    French translation - Chris77:

    Cover pack(NDS roms):
    Part 1:
    (thanks to Aguilera_87 for creating them)
    Mirror 1
    Mirror 2 -thanks Dter ic
    Mirror 3
    Part 2:
    (thanks pcjco!)
    Mirror 1

    Homebrew cover & iconpack by 2-bias
    Download (

    thanks to VatoLoco to the following packs:
    [​IMG] Homebrew Boxart & Icons

    [​IMG] Atari2600

    [​IMG] Atari7800

    [​IMG] NES

    [​IMG] SNES(*.sfc)
    [​IMG] SNES(*.zip)

    [​IMG] NeoGeo

    amaro999's instructions for setting up SNES boxarts -

    Short list of some popular programs that support args + extlink.dat:
    Etch - a DS paint app which can open bitmaps(requires BAGplug DSTwo.nds)
    CATSFC -snes emulator, supports .smc .sfc and .zip files
    BAGSFC - same as CATSFC
    Iku Reader - ebook reader
    nesDS - nintendo emulator
    Mario Paint Composer DS -exactly as it sounds(requires BAGplug DSTwo.nds)
    Stella DS - Atari 2600 emulator (requires BAGplug DSTwo.nds)
    A7800DS2 - Atari 7800 emulator
    NeoDS - Neo Geo AES/MVS emulator

    Instructions for setting up covers:;#entry3557023

    Troubleshooting NDS rom loading:
    -Make sure you are using EOS 1.11 or later (press start, click help and look at the bottom of the window in the DSTwo menu).
    -Check the "globalsettings.ini" file in the "/_dstwo/" folder and see if both "lastRomRun" and "enterLastDirWhenBoot" are set to 1. The menu should auto set those.
    -Open the "lastsave.ini" file in the "/_dstwo/" directory and make sure the fullname matches the rom you are trying to play/ The menu should auto set this as well.

    Once you have gone through this list and are still getting errors, let me know in which parts an error occured.

    Troubleshooting custom icons:
    -Icons must be .png or .bmp files (32 pixels by 32 pixels)
    [Warning, in BAGplug release 3.0, icon names will need to include the file extension of the file it is for( test.plg / test.plg.png) to avoid icons loading for all files named "test"]
    -Icons must have the same file name as the file you are creating the icon for. Eg. test.plg / test.png

    -in "/_bagui/skin/YOURSKIN/", open the "skin.ini" file, make sure that "Custom_Icon_Folder" under the "[Main Browser]" section of the ini has a valid path to your icon folder
    -Copy the icons to the folder defined in the skin.ini file

    -in "/_bagui/skin/YOURSKIN/", open the "skin.ini" file, make sure that "Custom_Icon_Folder" under the "[Main Browser]" section of the ini is left blank
    -Copy the icons to the desired file folders.

    Improving BAGplug Performance
    BAGplug does quite a bit of random reading from the SD card for things such as icons and box art. These can cause lagging or bad performance when scrolling through files. Here are a few tips to optimize BAGplug to (hopefully) make it run smoother:

    -Make sure your SD card is formatted with 64k clusters

    -Box art is loaded after X (5 is the default) number of program cycles without user input in the browser. You can change this value in your settings.ini with the 'top_display_refresh' variable. 60 = 1 second, 30 = half a second etc. The default value may be to fast and cause lagging when scrolling with covers.

    -Last resort: Change the CPU speed in the BAGplug options menu. A reboot of the menu may be needed to get working properly after switching CPU speeds.
  2. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
    [​IMG] The Catboy is impressed!
    How do you add the covers?
  3. Vigilante

    Vigilante TempLurker

    Jan 1, 2010
    CyberSpace IQ:OVER 9000
    I am seeing an imenu competitor here.Nice work work anyways.
  4. Ron

    Ron somehow a weeb now.

    Dec 10, 2009
    great improvement from release 1.
    Good luck!
  5. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
    Game Covers
    - can be any size as long as it fits on screen
    - can be either png or bmp files
    - must be named exactly the same as the game file excluding the file extension (Zelda.nds / Zelda.png)
    -CoverArt.ini file must be present in game directory

    ini file example:

    [Cover Art]
    #path to folder with covers
    folder = /_bagui/cover art/nds
    #image type
    type = png

    so if you have your games in /DSGames/,
    you would have /DSGames/CoverArt.ini

    All games in the folder are covered by the one ini file. Sub folders will need their own ini files.
  6. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
    Thanks [​IMG]
    What about setting up the SNES emulator? Can it just be any folder since I tried to start up a snes game and it wouldn't boot
  7. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
    You may need to modify the smc.arg, sfc.arg and or zip.arg files to have the correct binary paths to the emulators. Just open them as a regular text file and make the changes.
  8. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
    Ah, thanks!
  9. bigpaws

    bigpaws Cat with da Big Paws!

    Nov 22, 2009
    United States
    Nintendo World
    I like how this is turning out. too bad i wont be using my dstwo for a while. maybe by then this will be perfected.

  10. tigris

    tigris Sentient Existential Anthropomorphic Sweet Potato

    Jun 19, 2010
    The Tibetan Himalayas
    I don't have the card, but the UI looks sexy :3
  11. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
    Is there a program to download SNES and NES covers?
  12. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
  13. RoMee

    RoMee ??

    Sep 3, 2010
    United States
    awesome work BassAceGold

    so I'm guessing the download don't come with all the cover art and .ini
  14. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
  15. Shabutie78

    Shabutie78 GBAtemp Fan

    Jul 6, 2010
    United States
    trying it out now and i'm loving it [​IMG]
    great work, BAG. this makes the DS2 feel quick and snappy, similar to akaio instead of being slowed down by a plugin menu.
    only thing i can think of for you to implement would be internal name display on the bottom screen (not the top screen like the DS2 ds_game plugin).

    also, are you sure you can format cards over 2GB in FAT16 with 64k clusters?
    my windows won't let me do it, nor will either of my linux installations.
  16. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
    Windows 7 x64 let me format my 4gb card to 64k clusters just fine.
  17. Shabutie78

    Shabutie78 GBAtemp Fan

    Jul 6, 2010
    United States
    it says my 8GB card is too large to format in FAT16. no problem, i'll just use your menu to format it.
    misread the readme, i thought there was an option to format using BAGPlug.
    any idea how to get soft reset to take you back to BAGPlug instead of ds_game?
  18. BassAceGold

    BassAceGold Testicles

    Aug 14, 2006
    Currently there is no way to soft reset back into BAGPlug. It may be possible if one were to rename DSGAME.nds to something else, and then make a copy of DSTwo.nds and rename that as DSGAME.nds. However I would need to fix the menu to use the newly named (old) DSGAME.nds for launching.

    Guess there is no way yet, it just freezes when I try the idea I had.
  19. Lilith Valentine

    Lilith Valentine GBATemp's Succubus™ The Adorable Enby

    Sep 13, 2009
    Hiding from Area 51 guards
    I just tried that. I renamed the dsgame.nds to dsgame2.nds (I am so creative!) Then copied and renamed the dstwo.nds to dsgame.nds. Then edited nds.arg so it let to dsgame2.nds and it loaded the game (yay!), but then when I restarted it just showed 2 white screens (boo!)
  20. 2-bias

    2-bias GBAtemp Regular

    Jul 30, 2009
    Gambia, The
    Well done.
    But there is something i wan't to request. The Hide Option is not so good. Not all Folders have a starting _ so they won't be hidden. Can't you add the option to read the file attributes? Most of my folders/files are hidden with Windows/DSOrganize so they won't show up in most Applications. I would be great to have that in BagPlug too.

    Edit: And can you make a separate bagplug.nds that can be used to load BagPlug from Moonshell or DSOrganize? I know the first release of iMenus dstwo.nds redirects just to imenu.plg. The new dstwo.nds is the Bootloader and it's kinda anoying to reset my DS all the Times.
Quick Reply
Draft saved Draft deleted