Skip to content

Commit

Permalink
Update v1.60
Browse files Browse the repository at this point in the history
  • Loading branch information
TheOfficialFloW committed Mar 17, 2017
1 parent 49e6b9b commit daf6b30
Show file tree
Hide file tree
Showing 56 changed files with 521 additions and 105 deletions.
13 changes: 12 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,18 @@ FUNCTION(ADD_RESOURCES out_var)
SET(${out_var} "${result}" PARENT_SCOPE)
ENDFUNCTION()

file(GLOB res_files RELATIVE ${CMAKE_SOURCE_DIR} resources/*.png resources/*.txt resources/*.bin resources/*.suprx resources/*.skprx)
file(GLOB res_files RELATIVE
${CMAKE_SOURCE_DIR}
resources/default/*.png
resources/default/*.txt
resources/electron/*.png
resources/electron/*.txt
resources/*.png
resources/*.txt
resources/*.bin
resources/*.suprx
resources/*.skprx
)
add_resources(vitashell_res ${res_files})

add_executable(VitaShell
Expand Down
45 changes: 28 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,45 @@
VitaShell is an alternative replacement of the PS Vita's LiveArea. It offers you a file manager, package installer, built-in FTP and much more.
This homebrew was an entry of the Revitalize PS Vita homebrew competition and won the first prize. HENkaku's molecularShell is also based on VitaShell.

### How to use an USB flash drive as Memory Card on a PS TV ###
- Format your USB flash drive as exFAT or FAT32.
- Launch VitaShell and press /\ in the 'home' section.
- Select 'Mount uma0:' and attach your USB flash drive. You can now copy stuff from/to your USB stick.
- Once 'uma0:' is listed under the partitions, press /\ again and choose 'Mount USB ux0:'.
- Your USB flash drive is now acting as a Memory Card.
- To sync all your apps on your USB flash drive, press /\ and choose 'Refresh livearea'. This will NOT refresh PSP games.
- If you wish to revert the patch, press /\ and select 'Umount USB ux0:'.

### Customization ###
You can customize those files:
- **colors.txt**: All colors adjustable
- **archive_icon.png**: Archive icon
- **audio_icon.png**: Audio icon
- **battery.png**: Battery border icon
- **battery_bar_charge.png**: Charging battery bar
- **battery_bar_green.png**: Green battery bar
- **battery_bar_red.png**: Red battery bar
- **bg_audioplayer.png**: Background for audio player
- **bg_browser.png**: Background for file browser
- **bg_hexeditor.png**: Background for hex editor
- **bg_texteditor.png**: Background for text editor
- **bg_photoviewer.png**: Background for photo viewer
- **bg_audioplayer.png**: Background for audio player
- **settings.png**: Background for settings
- **wallpaper.png**: Wallpaper
- **dialog.png**: Dialog menu image (Can be any size. This image file will be stretched by VitaShell to fit the dialog box. Suggestion: Don't use motives, as it will not look good with wrong proportion).
- **bg_texteditor.png**: Background for text editor
- **context.png**: Context menu image (Can be any size. Suggestion: It will look great if you add alpha channel to your image).
- **context_more.png**: Context menu more image (Can be any size. Suggestion: It will look great if you add alpha channel to your image).
- **battery.png**: Battery border icon
- **battery_bar_green.png**: Green battery bar
- **battery_bar_red.png**: Red battery bar
- **battery_bar_charge.png**: Charging battery bar
- **ftp.png**: Ftp icon
- **audio_icon.png**: Audio icon
- **archive_icon.png**: Archive icon
- **cover.png**: Default album cover
- **dialog.png**: Dialog menu image (Can be any size. This image file will be stretched by VitaShell to fit the dialog box. Suggestion: Don't use motives, as it will not look good with wrong proportion).
- **fastforward.png**: Fastforward icon
- **fastrewind.png**: Fastrewind icon
- **file_icon.png**: File icon
- **folder_icon.png**: Folder icon
- **ftp.png**: Ftp icon
- **image_icon.png**: Image icon
- **pause.png**: Pause icon
- **play.png**: Play icon
- **settings.png**: Background for settings
- **sfo_icon.png**: SFO icon
- **text_icon.png**: Text icon
- **cover.png**: Default album cover
- **play.png**: Play icon
- **pause.png**: Pause icon
- **fastforward.png**: Fastforward icon
- **fastrewind.png**: Fastrewind icon
- **wallpaper.png**: Wallpaper


**Theme setting:** VitaShell will load the theme that is set in **'ux0:VitaShell/theme/theme.txt'** (THEME_NAME = "YOUR_THEME_NAME")
Expand Down Expand Up @@ -99,6 +108,8 @@ Be sure you pull request your customized design or language file there.
- Added possibility to refresh the livearea.
- Added scrolling text for long filenames.
- Added 'Sort by' option to context menu (R trigger combo removed).
- Added 'Electron' theme by Acemad, the winner of the VitaShell theme contest.
- Added theme selector.
- Improved property dialog animation.
- Fixed text editor bugs.
- Fixed bug where USB cable wasn't recognized.
Expand Down
140 changes: 98 additions & 42 deletions init.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,33 +24,60 @@

#include "audio/vita_audio.h"

INCLUDE_EXTERN_RESOURCE(folder_icon_png);
INCLUDE_EXTERN_RESOURCE(file_icon_png);
INCLUDE_EXTERN_RESOURCE(archive_icon_png);
INCLUDE_EXTERN_RESOURCE(image_icon_png);
INCLUDE_EXTERN_RESOURCE(audio_icon_png);
INCLUDE_EXTERN_RESOURCE(sfo_icon_png);
INCLUDE_EXTERN_RESOURCE(text_icon_png);
INCLUDE_EXTERN_RESOURCE(ftp_png);
INCLUDE_EXTERN_RESOURCE(battery_png);
INCLUDE_EXTERN_RESOURCE(battery_bar_red_png);
INCLUDE_EXTERN_RESOURCE(battery_bar_green_png);
INCLUDE_EXTERN_RESOURCE(battery_bar_charge_png);

INCLUDE_EXTERN_RESOURCE(cover_png);
INCLUDE_EXTERN_RESOURCE(play_png);
INCLUDE_EXTERN_RESOURCE(pause_png);
INCLUDE_EXTERN_RESOURCE(fastforward_png);
INCLUDE_EXTERN_RESOURCE(fastrewind_png);
INCLUDE_EXTERN_RESOURCE(english_us_txt);

INCLUDE_EXTERN_RESOURCE(theme_txt);
INCLUDE_EXTERN_RESOURCE(colors_txt);
INCLUDE_EXTERN_RESOURCE(english_us_txt);

INCLUDE_EXTERN_RESOURCE(default_colors_txt);
INCLUDE_EXTERN_RESOURCE(default_archive_icon_png);
INCLUDE_EXTERN_RESOURCE(default_audio_icon_png);
INCLUDE_EXTERN_RESOURCE(default_battery_bar_charge_png);
INCLUDE_EXTERN_RESOURCE(default_battery_bar_green_png);
INCLUDE_EXTERN_RESOURCE(default_battery_bar_red_png);
INCLUDE_EXTERN_RESOURCE(default_battery_png);
INCLUDE_EXTERN_RESOURCE(default_cover_png);
INCLUDE_EXTERN_RESOURCE(default_fastforward_png);
INCLUDE_EXTERN_RESOURCE(default_fastrewind_png);
INCLUDE_EXTERN_RESOURCE(default_file_icon_png);
INCLUDE_EXTERN_RESOURCE(default_folder_icon_png);
INCLUDE_EXTERN_RESOURCE(default_ftp_png);
INCLUDE_EXTERN_RESOURCE(default_image_icon_png);
INCLUDE_EXTERN_RESOURCE(default_pause_png);
INCLUDE_EXTERN_RESOURCE(default_play_png);
INCLUDE_EXTERN_RESOURCE(default_sfo_icon_png);
INCLUDE_EXTERN_RESOURCE(default_text_icon_png);

INCLUDE_EXTERN_RESOURCE(electron_colors_txt);
INCLUDE_EXTERN_RESOURCE(electron_archive_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_audio_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_battery_bar_charge_png);
INCLUDE_EXTERN_RESOURCE(electron_battery_bar_green_png);
INCLUDE_EXTERN_RESOURCE(electron_battery_bar_red_png);
INCLUDE_EXTERN_RESOURCE(electron_battery_png);
INCLUDE_EXTERN_RESOURCE(electron_bg_audioplayer_png);
INCLUDE_EXTERN_RESOURCE(electron_bg_browser_png);
INCLUDE_EXTERN_RESOURCE(electron_bg_hexeditor_png);
INCLUDE_EXTERN_RESOURCE(electron_bg_photoviewer_png);
INCLUDE_EXTERN_RESOURCE(electron_bg_texteditor_png);
INCLUDE_EXTERN_RESOURCE(electron_context_png);
INCLUDE_EXTERN_RESOURCE(electron_context_more_png);
INCLUDE_EXTERN_RESOURCE(electron_cover_png);
INCLUDE_EXTERN_RESOURCE(electron_dialog_png);
INCLUDE_EXTERN_RESOURCE(electron_fastforward_png);
INCLUDE_EXTERN_RESOURCE(electron_fastrewind_png);
INCLUDE_EXTERN_RESOURCE(electron_file_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_folder_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_ftp_png);
INCLUDE_EXTERN_RESOURCE(electron_image_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_pause_png);
INCLUDE_EXTERN_RESOURCE(electron_play_png);
INCLUDE_EXTERN_RESOURCE(electron_sfo_icon_png);
INCLUDE_EXTERN_RESOURCE(electron_text_icon_png);

INCLUDE_EXTERN_RESOURCE(user_suprx);
INCLUDE_EXTERN_RESOURCE(usbdevice_skprx);
// INCLUDE_EXTERN_RESOURCE(kernel_skprx);
// INCLUDE_EXTERN_RESOURCE(umass_skprx);
INCLUDE_EXTERN_RESOURCE(kernel_skprx);
INCLUDE_EXTERN_RESOURCE(umass_skprx);

INCLUDE_EXTERN_RESOURCE(changeinfo_txt);

Expand All @@ -60,29 +87,57 @@ static DefaultFile default_files[] = {
DEFAULT_FILE("ux0:VitaShell/language/english_us.txt", english_us_txt, 0),

DEFAULT_FILE("ux0:VitaShell/theme/theme.txt", theme_txt, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/colors.txt", colors_txt, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/folder_icon.png", folder_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/file_icon.png", file_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/archive_icon.png", archive_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/image_icon.png", image_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/audio_icon.png", audio_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/sfo_icon.png", sfo_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/text_icon.png", text_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/ftp.png", ftp_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery.png", battery_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_red.png", battery_bar_red_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_green.png", battery_bar_green_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_charge.png", battery_bar_charge_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/cover.png", cover_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/play.png", play_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/pause.png", pause_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/fastforward.png", fastforward_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/fastrewind.png", fastrewind_png, 0),

DEFAULT_FILE("ux0:VitaShell/theme/Default/colors.txt", default_colors_txt, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/archive_icon.png", default_archive_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/audio_icon.png", default_audio_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery.png", default_battery_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_charge.png", default_battery_bar_charge_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_green.png", default_battery_bar_green_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/battery_bar_red.png", default_battery_bar_red_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/cover.png", default_cover_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/fastforward.png", default_fastforward_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/fastrewind.png", default_fastrewind_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/file_icon.png", default_file_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/folder_icon.png", default_folder_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/ftp.png", default_ftp_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/image_icon.png", default_image_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/pause.png", default_pause_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/play.png", default_play_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/sfo_icon.png", default_sfo_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Default/text_icon.png", default_text_icon_png, 0),

DEFAULT_FILE("ux0:VitaShell/theme/Electron/colors.txt", electron_colors_txt, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/archive_icon.png", electron_archive_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/audio_icon.png", electron_audio_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/battery.png", electron_battery_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/battery_bar_charge.png", electron_battery_bar_charge_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/battery_bar_green.png", electron_battery_bar_green_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/battery_bar_red.png", electron_battery_bar_red_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/bg_audioplayer.png", electron_bg_audioplayer_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/bg_browser.png", electron_bg_browser_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/bg_hexeditor.png", electron_bg_hexeditor_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/bg_photoviewer.png", electron_bg_photoviewer_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/bg_texteditor.png", electron_bg_texteditor_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/context.png", electron_context_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/context_more.png", electron_context_more_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/cover.png", electron_cover_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/dialog.png", electron_dialog_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/fastforward.png", electron_fastforward_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/fastrewind.png", electron_fastrewind_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/file_icon.png", electron_file_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/folder_icon.png", electron_folder_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/ftp.png", electron_ftp_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/image_icon.png", electron_image_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/pause.png", electron_pause_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/play.png", electron_play_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/sfo_icon.png", electron_sfo_icon_png, 0),
DEFAULT_FILE("ux0:VitaShell/theme/Electron/text_icon.png", electron_text_icon_png, 0),

DEFAULT_FILE("ux0:VitaShell/module/user.suprx", user_suprx, 1),
DEFAULT_FILE("ux0:VitaShell/module/usbdevice.skprx", usbdevice_skprx, 1),
// DEFAULT_FILE("ux0:VitaShell/module/kernel.skprx", kernel_skprx, 1),
// DEFAULT_FILE("ux0:VitaShell/module/umass.skprx", umass_skprx, 1),
DEFAULT_FILE("ux0:VitaShell/module/kernel.skprx", kernel_skprx, 1),
DEFAULT_FILE("ux0:VitaShell/module/umass.skprx", umass_skprx, 1),

DEFAULT_FILE("ux0:patch/VITASHELL/sce_sys/changeinfo/changeinfo.xml", changeinfo_txt, 1),
};
Expand Down Expand Up @@ -244,6 +299,7 @@ void installDefaultFiles() {
sceIoMkdir("ux0:VitaShell/module", 0777);
sceIoMkdir("ux0:VitaShell/theme", 0777);
sceIoMkdir("ux0:VitaShell/theme/Default", 0777);
sceIoMkdir("ux0:VitaShell/theme/Electron", 0777);

sceIoMkdir("ux0:patch", 0006);
sceIoMkdir("ux0:patch/VITASHELL", 0006);
Expand Down
48 changes: 48 additions & 0 deletions modules/kernel/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
cmake_minimum_required(VERSION 2.8)

if(NOT DEFINED CMAKE_TOOLCHAIN_FILE)
if(DEFINED ENV{VITASDK})
set(CMAKE_TOOLCHAIN_FILE "$ENV{VITASDK}/share/vita.toolchain.cmake" CACHE PATH "toolchain file")
else()
message(FATAL_ERROR "Please define VITASDK to point to your SDK path!")
endif()
endif()

project(kernel)
include("${VITASDK}/share/vita.cmake" REQUIRED)

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wl,-q -Wall -O3 -nostdlib")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-rtti -fno-exceptions")

add_executable(kernel
main.c
)

target_link_libraries(kernel
SceIofilemgrForDriver_stub
SceSysclibForDriver_stub
SceSysmemForDriver_stub
SceModulemgrForKernel_stub
SceModulemgrForDriver_stub
SceThreadmgrForDriver_stub
taihenForKernel_stub
taihenModuleUtils_stub
)

vita_create_self(kernel.skprx kernel CONFIG exports.yml UNSAFE)

vita_create_stubs(stubs kernel ${CMAKE_SOURCE_DIR}/exports.yml KERNEL)

install(DIRECTORY ${CMAKE_BINARY_DIR}/stubs/
DESTINATION lib
FILES_MATCHING PATTERN "*.a"
)

install(FILES vitashell_kernel.h
DESTINATION include
)

add_custom_target(copy
COMMAND cp kernel.skprx ../../../resources/kernel.skprx
DEPENDS kernel.skprx
)
15 changes: 15 additions & 0 deletions modules/kernel/exports.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
VitaShellKernel:
attributes: 0
version:
major: 1
minor: 0
main:
start: module_start
stop: module_stop
modules:
VitaShellKernelLibrary:
syscall: true
functions:
- shellKernelIsUx0Redirected
- shellKernelRedirectUx0
- shellKernelUnredirectUx0
Loading

0 comments on commit daf6b30

Please sign in to comment.