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

pspHBSortTool

From GameBrew
pspHBSortTool
Psphbsorttool.png
General
AuthorPartQual
TypePC Utilities
Version4.0.0
LicenseFreeware
Last Updated2011/07/20
Links
Download
Website

This is a utility for Windows that enables you to "sort" HB items on your PSP into a preferred display order. It is designed around Bubbletune's Game Categories plugin and also allows you to move items between categories.

It also includes category sorting and savedata backup utilities.

Notes:

  • This application was built using C# and needs the .NET Framework v2 to run.
  • File/Folder timestamps on the source drive are updated by this application. The details of these changes are listed in the instructions. Please do note use this app if you need file/folder timestamps to remain constant.
  • The app can still be used even if you don't use game categories - all the HB items will simply appear to be in the "{Uncategorised}" category.

User guide

How to use

Upon loading, the app will search for a PSP drive on a best guess basis. You can select your own drive choice from the "PSP Drive" DDL if this search is unsuccessful.

Upon drive selection, the app will load the relevant information from the ISO, GAME, GAME150 and GAME5XX folders. In particular, the system will check for CAT_** folders, and mark the information appropriately. "GAME5XX" can be changed (see below reference to INI file).

The information can be reset/reloaded by clicking Reload, and will automatically be reloaded when selecting a different drive. A reload will also be prompted by a significant action, such as moving items between categories.

Using the "Categories" DDL you can view all recognised HB items grouped by category. The category list is created by merging from the various source folders (as they are by the plugin), and each can be sorted:

  • manually - using Up/Down buttons, or by drag'n'drop;
  • in bulk - by clicking column headers.

Multiple changes can be made by switching between the categories as they are retained in memory until "Reload" or "Save Changes" is clicked. You can also sort everything at once using the "{All Items}" category.

When you're ready simply click "Save Changes" to push the necessary changes up to the source files/folders (see below). To "cancel" changes, simply "Reload".

Tools/Notes

There is a growing set of extra items/tools:

(a) "Context Menu" vs "Content Browser" vs "Multiple MS"

The plugin's "content browser" mode uses different file/folder values to organise the display. This selection allows you to choose your preferred method of sorting. Details of the differences can be found below.

(b) "Sort Categories"

There is a built-in mini-version of the tool which can sort the categories themselves. This is launched via the "Sort Categories" button. Please note that in content browser mode the categories will always be displayed on the PSP alphabetically - so this button is disabled in this mode.

(c) "SaveData Tool"

This built-in mini-tool allows you to Browse/BackUp/Restore/Delete SaveData items. Unlike other SaveData BackUp tools this one will persist the timestamps of the relevant file/folders so that after a restore the SaveData items haven't all been set to today's date (which annoys me).

As an additional security check you to have to enable delete functionality each time by ticking the "Enable Deletes" checkbox (pre-ticking this will eventually be added as an INI file item).

(d) "Right-Click menu"

When you R/Click on an item in the main grid a context menu will appear giving these options:

  • Change Category - allows you to move the current item between categories (and to create a new one).
  • Edit Filename - allows you to edit the filename of the current object (can be useful if the filename is too long).
  • Reduce Filename - will automatically reduce the length of the filename (+ category) to the length set by the WarningLevel value. The last part of the filename becomes "[...]" to indicate a shortened name.
  • Show File Info - displays a popup window detailing some (potentially) useful/interesting file information.
  • Delete This Item - allows you to delete the chosen item from your memory stick. Please note that ALL DELETES ARE PERMANENT.

--

  • Change Category - allows you to move the current item between categories (and to create a new one if you wish);
  • Show File Info - displays a popup window detailing some (potentially) useful/interesting file information.
  • Delete This Item - allows you to delete the chosen item from your memory stick. Please note that because of the way memory cards work all deletes are permanent.
  • Edit Filename - allows you to edit the filename of the current object (can be useful if the filename is too long for PSP to display);
  • Reduce Filename - will automatically reduce the length of the filename (+ category) to the length set by the WarningLevel value. The last part of the filename becomes "[...]" to indicate a shortened name.
  • Set Filename From Title - borrows from the above funtions to quickly change the filename to match the title.
  • [BETA] HexEdit Title - This is BETA functionality - to be used at your own risk. It *should* replace the bytes in the file stream with those representing a replacement title. Note that titles MUST remain the same length, so entry is size restricted and results will be padded (with underscores) to ensure this. Compressed (CSO) files cannot be changed. Please note that all changes are permanent (so backup first).

(e) "Double-Click"

Double-Clicking a row on the main grid has the same effect as R/Clicking and selecting "Show File Info" (see above) - i.e. it will display the same popup window of (potentially) useful/interesting file information.

(f) The "warning" column

With long filenames the addition of the category folder name sometimes means the PSP does not display the HB item. So a threshold warning marker was added which simply displays a "X" if the combined name gets too long. Strangely it seems the threshold value is not totally fixed but can vary (with the combination of category length and ISO filename length) so the threshold value is changeable via a tool under menu option "Settings >> Adjust Warning Level" (also see the INI section below).

Strangely EBOOT.PBP based folders seem to need an even smaller total path, and content browser method changes these values still further. To use this function with these modes you might want to play with the value a bit...

(g) The "size" column

The default setting is for this to calculate the entire size of a HB folder rather than just show the size of the Eboot file as this gives a more accurate representation of the used space on the drive. However, if the HB is formed of lots of small files the size calculation can become slow and get annoying. Hence there is a setting to switch this off and show the size of just the Eboot file under menu option "Settings >> Eboot Size" (also see INI section below).

ISO files are, of course, always shown as single files.

A value of 0 specifically means "no Eboot was found" - very small values (<1mb) are rounded to 1mb for display. All other values are rounded down.

(h) INI files

The system uses simple defaults - but there is an option to persist preferences via an INI file. You have to manually create one (using menu item "Settings >> Save Settings To INI File") but once one exists the values will update automatically.

The INI file is normally created in the same folder as the app EXE.

The following values can be understood:

  • WarningLength - defaults to 60 (max 99, min 9)
    • This stores the preferred value for the "filename length warning";
  • GameFolder - defaults to "GAME5XX"
    • This is to allow an element of future-proofing.
  • Target - defaults to "ContextMenu"
    • Setting to "ContentBrowser" allows the targetting checkbox setting to be persisted;
  • EbootSize - defaults to "Folder"
    • Setting to "Eboot" allows the file/folder sizing choice to be persisted.
  • IncludePic1 - defaults to "Yes"
    • Setting to "False" or "No" forces decoding of Pic1.png data to be skipped. This value can only be changed manually, but may help speed up loading times on very packed memory cards and can sometimes be useful if you are scanning items with badly constructed embedded images (such as some hand-converted PSX files).
  • StartMaximised - defaults to "Yes"
    • Setting to "False" or "No" starts the app in normal mode. This value can only be changed manually.
  • IconSize - defaults to "Medium"
    • Directly affects the size of the icon displayed in the main grid. Other settings are "Small", "Large" or "FullSize".

The INI file can of course be updated manually, and is read when the app is loaded.

(i) INI path override

The combination of "Windows 7", "Program Files" and "Use INI File" doesn't work because of Windows UAC etc. To use this app from "Program Files" you need to manually create a dummy file (called "useAppData.ini") in the same folder as the EXE file. This forces the app to use "LocalUser\AppData" for the INI files instead of the folder with the EXE.

This should only needed if you don't want to run as portable app and instead prefer to "manually install" into Program Files area.

(j) "Clean Up Empty Categories"

This application allows you to move items between categories, creating new ones on the fly as desired. This can, of course, leave empty folders behind on the source drive.

This tool (from menu item "Tools >> Clean Up Category Folders") will recurse through the CAT_** folders deleting any that are found to be empty.

If you use this tool, PLEASE take care that you have backed up any data you regard as essential to prevent accidental loss. There is a double redundancy check to ensure only empty folders are deleted (and prevent such data loss), but better safe than sorry.

(k) "Clean Up ReadOnly Items"

More often than not, files marked as RO (read-only) have been marked that way by mistake. Although this application provides code to handle this additional security on files, the warning messages can become annoying.

This tool (from menu item "Tools >> Clean Up ReadOnly Items") will clear the RO flag from any files so marked, enabling the main sorting functions to work as intended.

(k) "Validate Compressed Items"

It is not unknown for cso files to retain the ".iso" extension. As this tool makes a few assumptions about files based on their extension it was sensible for there to be a way to test the validity of these extensions.

This tool simply checks for the "magic" compression indicator in all iso and cso files and reports back any mismatches. The tool will also rename any affected files, should the user choose to do so.

(l) "Options"

For those who prefer to set all their options at once there is now a "proper" options screen (from menu item "Tools > Options"). Using this will always force a reload as some options affect the display.

Changes made to source files/folders

This tool updates various source file/folder datetimes into an order that the PSP will correctly reflect on screen. This section briefly outlines which values will be changed.

(a) When targeting "Multiple MS" or "Context Menu" mode(s):

  • ISO/CSO Files: File Created Date of ISO/CSO file is updated;
  • HB EBoots (GAME/GAME150/GAME5XX): Folder Modified Date of container is updated;
  • Category Folders: Folder Modified Date of "CAT_**" folder is updated.

(b) When targeting "Content Browser" mode:

  • ISO/CSO Files: File Created Date of ISO/CSO file is updated;
  • HB EBoots (GAME/GAME150/GAME5XX): File Modified Date of EBOOT.PBP file is updated.

(c) GCLight

  • ISO/CSO Files: File Created Date of ISO/CSO file is updated;
  • HB EBoots (GAME/GAME150/GAME5XX): Folder Modified Date of container is updated;
  • Category Folders: Folder Modified Date of "all folders without EBOOT.PBP file" is updated.

(d) When sorting for "No Plugin"

  • ISO/CSO Files: File Created Date of ISO/CSO file is updated;
  • HB EBoots (GAME/GAME150/GAME5XX): Folder Modified Date of container is updated;

In addition, any actions involving moving items between categories, editing filenames and/or changing RO status will be moving/renaming/creating/changing files/folders on the selected source drive.

The new BackUp/Restore tools and Delete functions also bring in file deletion and overwriting possibilities.

To allow for the way more recent FWs seem to work, when saving changes the isocache.bin file is deleted - this forces the PSP to reread the (new) timestamps (ie those being set by this app).

The BETA "HexEdit Title" function is a particular risk as there is no possible validation on this kind of byte swapping activity. There is, therefore, an increased risk of permanent damage to files if this BETA function is used.

The new BackUp/Restore tools and Delete functions also bring in file deletion and overwriting possibilities.

These changes are, of course, made at your own risk.

Screenshots

psphbsorttool2.png

Compatibility

The program was tested on the following:

  • WinXP / Vista / Win7;
  • 5.00 M33-6 / 6.39 PRO-B7;
  • Phat / Slim;
  • Game Categories v12 / GCLight v1.3 / GCLite v1.2.

Changelog

v4.0

  • Added support for GCLight and GCLite.
  • Enabled multi-select on main screen.
  • Added drag/drop from Explorer (to add new items on the fly).
  • Several functions now have batch options (e.g. via multi-select).
  • New tool to validate extensions for compressed files.
  • Rescan option (to add new drive on the fly).
  • Added autoscroll to main grid (enables drag/drop with long lists).
  • GUI tweaks (e.g. change "Target" to "Mode" and seal DDLs).
  • Other minor optimisations.

v3.1

  • User requested tool to set filename from title.
  • User requested tool to HexEdit the title [BETA FUNCTIONALITY].
  • New option to choose icon size.
  • Improve "skip warnings" function to reduce number of steps involved.
  • GUI tweaks (e.g. improve progress bars).
  • New options screen (groups existing options in one place).
  • Several parsing optimisations.
  • Other minor optimisations.

v3.0

  • Complete New Tool for SaveData (BackUp/Restore etc).
  • Tweak GUI (some people didn't understand "Target Content Browser").
  • IniFile path override for users who want to run from "Program Files".
  • Added a delete option.
  • Minor optimisations.

v2.2.1

  • Minor optimisations.

v2.2

  • Better handling for read-only files;
  • New tool to remove read-only flags;
  • Additional handling code for old-style xxx - xxx% HB folders;
  • Minor optimisations.

v2.1.2

  • Minor optimisations.

v2.1.1

  • Minor bugfix.

v2.1

  • Finished adding support for CSO files (icons/titles etc).
  • Added "view detailed file info" as R/Click and DoubleClick options.
  • Added handling code for old-style xxx - xxx% HB folders.
  • Added some visual cues for loading/saving.
  • Improved item identifiers to handle multiple items with same name.
  • Optimised some data reading code to help improve startup/reload times.
  • Handled yet more odd exceptions (usually related to dodgy image data).

v2.0

  • Upgraded background DevEnv.
  • Added icon and title to on-screen information (not for CSOs).
  • Added lots of error handling for odd events.
  • Added rollback option when file/folder lock encountered.

v1.2

  • Added new tool to "clean up" empty category folders.

v1.1.2

  • Added support for CSO files.

v1.1.1

  • Tweak UI and IniFile stuff.

v1.1

  • Include drag and drop on main grid.
  • Addition of Category Tool (R/Click item on main grid).
  • Addition of "Move Between Categories" and file renaming options.

v1.0

  • Initial Release.

Credits

Much credit goes to Bubbletune for Game Categories.

External links

Advertising: