• Introducing XDA Computing: Discussion zones for Hardware, Software, and more!    Check it out!
  • Fill out your device list and let everyone know which phones you have!    Edit Your Device Inventory

[XDA_UC][UC][SASHIMI][S4X] S4X_Auto & S4X_Backup [DEC.02.2010] XDA_UC Mods & Answers

Search This thread

blast0id

Senior Member
[XDA_UC][UC][SASHIMI][S4X] S4X_Auto & S4X_Backup [DEC.02.2010] XDA_UC Mods & Answers

* * * << PLEASE CHECK THE UPDATES/NOTES TOWARDS THE BOTTOM OF THIS POST >> * * *
If you need to know about Energy's version of XDA_UC, or are not familiar with it, but use his ROMs please CLICK HERE NOW!!!

I have done some extensive modding of the MortScript from SASHIMI (by bengilah @ www.winmo-experts.com) and XDA_UC (by Noonski here @XDA) and have come up with a couple additions meant mainly for Energy's custom XDA_UC as it lacks some of the features that Noonski's version does, well now you can have ALL THAT & MORE!

What does S4X_AutoLauncher.mscr do?
  • 01. it loads the S4X_Auto Script (S4X_Auto_*version*.mscr) with an updated version of MortScript.exe (4.3b15) and waits for it to finish (this way you don't have to install new version of mortscript for the mod to work!).
S4X_Auto script does the following, in the following order:
  • 01. shuts down sense, kills manila.exe and any processes found in the "autoKillApps" section of the autoSettings.ini.
  • 02. deletes AppData folder from device, if instructed by autoSettings.ini to do so.
  • 03. installs CERT files found in XDA_UC_\_Mod_\filesCERT (+ subfolders)
  • 04. provisions any XML files that have "email" or "wifi" in the name of the file.
  • 05. silently sets windows them from the autoSettings.ini, place the filename.tsk(only - spaces are OK, but NO path) of the theme in the INI like this:
    Code:
    [AutoSettings]
    theme=filename.tsk
    if it is a theme that is not present on the rom you can place the file in the folder XDA_UC\_Mod_\filesTSK, and it will get copied to windows before being set as the default theme. if no theme is set in the autoSettings.ini, then any TSK files present in XDA_UC\_Mod_\filesTSK will be copied to windows, then a dynamic menu with all available themes will be shown, and you can choose one, if none is chosen (10sec timeout), then the default cooked theme will be left as the default.
  • 06. installs CABs, located in root of XDA_UC\_Mod_\filesCAB, silently to device
  • 07. installs CABs, located in root of XDA_UC\_Mod_\filesCAB or any subfolder thereof (EXCEPT FOR \netCF, \Dialer, \SDAuto or \SKIP), silently to device.
  • 08. if a SASHIMI ".auto" file is present, it will install the cab semi-silently (no user interaction required), to device or storage card (see XDA_UC\_Mod_\_bin\INI\sample-file.auto for example)
  • 09. install a custom dialer if there are CABs present in XDA_UC\_Mod_\filesCAB\Dialer (+ subfolders), shuts down the proper processes first and if that isn't possible it will skip installation so that there are no errors.
  • 10. installs netCF CABs silently to device if present in XDA_UC\_Mod_\filesCAB\netCF (+ subfolders) (uses THIS method. )
  • 11. looks for CABs in folder: XDA_UC\_Mod_\filesCAB\SDAuto(+ subfolders), installs them silently to your SD. The cabs don't HAVE to be UC compatible, but you will have to do some manual things if they aren't UC compatible... NOTE: not all CABs work with this method, if they don't work, please place them in folder: XDA_UC\_Mod_\filesCAB\Manual, for full user interaction when necessary. This is no longer a separate script, I have integrated it. credit to bengilah @ winmo-experts.com
  • 12. SKIPS all CABs located in XDA_UC\_Mod_\filesCAB\SKIP (+ subfolders)
  • 13. installs *.XDA, *.XDAI, *.XDAS & *.XDAZ files found in XDA_UC\_Mod_\filesXDA (subfolders as well)
  • 14. imports all reg files found in XDA_UC\_Mod_\filesREG (+ subfolders)
  • 15. provisions XML files found in XDA_UC\_Mod_\filesXML (+ subfolders)
  • 16. executes EXE files found in XDA_UC\_Mod_\filesEXE (+ subfolders), if a parameter(s) is found in exeparams.ini, then it is run with those parameters
  • 17. looks for *.wgt/*.widget files in folder: XDA_UC\_Mod_\filesWGT, and installs them with wmwidgetInstaller.exe (if present in ROM) automatically (not silent, but usually no user input is required).
  • 18. looks for folders under folder: XDA_UC\_Mod_\filesSense\****, and copies the content of each folder to \Windows, this is useful for keeping your fixes/mods seperated so that when a new rom comes out that includes the fix/mod you can just delete that folder and it won't be copied to device anymore during XDA_UC setup =)
  • 19. copies all files/folders from folder: XDA_UC\_Mod_\filesRoot, to the root of the device IE: XDA_UC\_Mod_\filesRoot\My Documents gets copied to \My Documents...etc...
  • 20. if present, executes deleteOps.ini and deletes files and/or folders, see the XDA_UC\_Mod_\_bin\INI folder for sample .ini's
  • 21. if present *.pib file in XDA_UC\_Mod_\filesPIM, starts PIMBackup and waits until user is finished importing settings, then...
  • 22. looks for PIM.VOL in folder: XDA_UC\_Mod_\filesPIM, renames current, copies backup, then places a self actuating and deleting script in \Windows\Startup that will delete the old renamed PIM.VOL file at the next boot.
  • 23. runs any MSCR (MortScripts) found in XDA_UC\_Mod_\filesMSCR (+ subfolders), if parameters exist in scriptparams.ini, then it runs the script with the given parameters.
  • 24. imports CHT settings file, if present in folder: XDA_UC\_Mod_\filesCHT
  • 25. finally, I have added logging (no matter whether script is ran manually or automatically by XDA_UC) and on-screen notifications (only during initial XDA_UC setup), the log file can be found in folder: XDA_UC\_Mod_\_bin\LOG\S4X_Auto_ver#_LOG.txt
  • XX. For ALL CAB & Widget file installs, looks for an entry in customlinks.ini, if present moves the link to the specified directory in the start menu after installation is complete

What does S4X_SDAutoLauncher.mscr do?
  • 01. It loads the sdauto script with an updated version of MortScript.exe (4.3b15) and waits for it to finish (this way you don't have to install new version of mortscript for it to work!).
S4X_SDAuto_1.0.mscr script does the following, in the following order:
  • 01. files are installed alphanumerically: 0, 1, a, A
  • 02. supports SASHIMI ".auto" files, to automate installation of non UC compliant CABs (ie: pop up messages/windows during installation)
  • 03. it writes a log to XDA_UC\_Mod_\_bin\LOG\S4X_SDAuto_1.0_LOG.txt

What does S4X_Backup do?

I DID NOT WRITE (MOST OF) THIS CODE, I ONLY MODDED IT TO MAKE IT WORK THE WAY I WANTED/NEEDED IT TO!!!!
  • 01. * Full minus file > customRegXport, PIMBackup & CHTBackup
  • 02. * FullBackupXport > Filebackup.ini, Regexport.ini, PIMBackup & CHTBackup
  • 03. * CustomRegXport > run regexport.ini ONLY
  • 04. * PIMBackup > Backs up PIM data with PIMBackup, if a file already exists in XDA_UC\_Mod_\filesPIM folder, it copies the file(s) to folder: XDA_UC\_Mod_\_Manual\filesPIM
  • 05. * CHTBackup > Backs up Co0kie Home Tab data and saves it as "chtsettings.cht" in folder: XDA_UC\_Mod_\filesCHT
  • 06. * filebackup > runs filebackup.ini ONLY
  • 07. * Full Export > full registry exported saved in folder: XDA_UC\_Mod_\_Manual\filesREG
  • 08. * View Regexport.ini > Shows you the contents of regexport.ini
  • 09. * View Filebackup.ini > Shows you the contents of filebackup.ini
  • 10. * _ E X I T _ * > self explanatory ;-)
  • 11. when doing a REG export I added a check of fileSkipOverOrArchive in autoSettings.ini (found in XDA_UC\_Mod_\_bin\INI), 0 = ARCHIVE, 1 = OVERWRITE, 2 = SKIP), if set to ARCHIVE a subfolder is created in XDA_UC\_Mod_\_Manual\filesREG and the files present in XDA_UC\_Mod_\filesREG are moved there before export starts. this way you have a backup of previous reg settings.
Please see post #3 for examples of filebackup.ini and regexport.ini

In an attempt to keep THIS post clean, I am not going to post the code from these two scripts. I will attach my XDA_UC_Mod [latest], which contains both of these scripts which you can extract from the zip and look at all you want.

I am going to post the contents of my filebackup.ini and regexport.ini's for reference, for you non-SASHIMI converts or SASHIMI users who never took the time to learn that wonderful part of SASHIMI. See posts #2 (autoSettings.ini) and #3 (filebackup.ini, regexport.ini, example ini's) for that info...


Future Plans:
  • 1. a way to automate PIMBackup restore w/an .ini
  • 2. completely modularize the mod and allow an .ini to set/determine what actions are performed, hopefully to make process slightly quicker as only script code needed will be loaded/executed
  • 03. regKeyDelete.ini - to automatically delete some keys from registry [ie: bootloader and init entries...etc...] will be written much like the regexport.ini from sashimi

Instructions
If you only want functionality to install cabs to SDCard silently, then just download the S4X_SDAuto_Mod and extract the zip to the ROOT of XDA_UC folder, otherwise if you want the full mod download the S4X_Auto_plus_Backup_Mod and extract it to the ROOT of XDA_UC folder, there is no need for both as the S4X_SDAuto_Mod is included in the full mod.

  • 1. choose file and unzip to ROOT of XDA_UC folder
  • 2. if running EITHER mod manually, run the .mscr file in root of XDA_UC or .exe in the _bin folder, do NOT run the .mscr file in the XDA_UC\_Mod_\_bin folder unless you have a 4.3b11+ version of MortScript already installed on your system
  • 3. to use S4X_Backup run S4X_Backup.exe in the XDA_UC\_Mod_\_bin folder of XDA_UC or from the start menu > tools > S4X_Backup (only present if you've used xda_uc setup with my mod)
--------------------------------------------
S4X_Auto & Backup Mod [Latest] - mediafire mirror
S4X_SDAuto Mod[Latest] - mediafire mirror
--------------------------------------------
EDIT 12/27/2010 ATTENTION: As I am currently unable to keep up with the updates at the moment, XDA user powinmo, is providing some code updates at THIS POST, please download the full package, then download his code update if you are a first time user. Otherwise you can just download his update, to fix the current issues. Changelog for his update is HERE.
 

Attachments

  • S4X_SDAuto_1.1.zip
    145.7 KB · Views: 322
  • S4X_Auto_plus_Backup_Mod_1.6.7z
    929.5 KB · Views: 557
Last edited:

blast0id

Senior Member
autoSettings.ini

Here are some basic explanations of what the settings in autoSettings.ini do. =)

Code:
[AutoSettings]
[b][color="red"]If for some odd reason device shuts off, reboots...etc during setup/customization, if this is ON (1), it will retry the last task, if OFF (0) it will continue after the last attempted task.[/color][/b]
aggresiveResume=1
[b][color="red"]If set to ON (1), will automatically remove appData folder from device[/color][/b]
appDataDelete=1
[b][color="red"]this relates to the S4X_Backup mod, if set to 0 it will "ARCHIVE" (copy to _Mod_\_Manual\filesREG\ARCHIVE_[date]) any existing REG files before exporting the new ones to _Mod_\filesREG[/color][/b]
fileSkipOverOrArchive=0
[b][color="red"]if ON (1) will display the fullpath in status updates[/color][/b]
FullPathStatus=0
[b][color="red"]If set to 0, will use mortscript built-in process kill function first (default is 0), if set to 1, will use SKTools.exe #KILLPROC command line function first to try to kill the process. I highly recommend keeping it on 0, but if you have trouble with apps not getting killed (IE: for dialer cab install, PIMBackup restore...etc) then try changing this.[/color][/b]
killApp=0
[b][color="red"]If ON (1), will automatically reboot device after AutoSetup/Customization is complete[/color][/b]
RebootAfterAuto=0
[b][color="red"]if ON (1), the autoProgressFile will be deleted after setup/customization is complete, maybe good for debugging, so you can look at file if there are issues[/color][/b]
resetAutoFlag=0
[b][color="red"]when copying files, or deleting them, if ON (1) will remove all file attributes and set only "ARCHIVE" attrib[/color][/b]
ResetReadOnly=1
[b][color="red"]will set a reg entry, if the script is run via the "AUTORUN" feature, ie: using the 2577 folder found under _Mod_\_bin[/color][/b]
SetAutoRunFlag=1
[b][color="red"]If ON (1), will keep open a status message window, that will update with each completed/skipped/failed task... everything is always logged to _Mod_\_bin\LOG\*LOG.txt, so not necessary for debugging, only if you want visual confirmation while you watch it work...[/color][/b]
statusOn=1
[b][color="red"]this pertains to the TSKfiles portion of the script, you can use the filename of any theme located in \Windows or _Mod_\filesTSK, it will automatically be set during setup/customization[/color][/b]
theme=EnergyROM 2010.tsk
[b][color="red"]If ON (1) will use FdcSoft TskMgr.exe (located in _Mod_\_bin) to import REG files, default (0) will use SKTools.exe (also located in _bin folder)[/color][/b]
UseTaskMgrRegImport=0

[b][color="red"]below is a list of apps/processes that the script will attempt to kill during the "disable htc sense GUI" portion of the script. you can add any app/process you like, but be careful and only use the process name and extension, do not include the path[/color][/b]
[autoKillApps]
app01=manila.exe
app02=AudioManager_eng.exe
app03=AlbumSearcher.exe
app04=changescreen.exe
app05=gyrator2.exe
app06=quickmenu.exe
app07=repllog.exe
app08=sipgt_app.exe
app09=tmail.exe
 
Last edited:

blast0id

Senior Member
filebackup.ini
- anything set to "Auto" will backup to _Mod_\filesRoot
- anything set to "Manual" will backup to _Mod_\_Manual\filesRoot
- so that it doesn't actually get copied to your device during the
- copy2root part of my script, you must do it manually.

Code:
[Appz_Config]
FileBackupDirMode=Auto
ArkSwitch=\Program Files\Arkswitch\Theme\config.xml
changeScreen=\Windows\changeScreen.config
ET9_1=\Windows\ET9*.Cdb
ET9_2=\Windows\ET9*.Rdb
Lumos=\Program Files\Lumos\settings.txt

[Gen_Filez_Backup]
FileBackupDirMode=Auto
ShakeSave=\ShakeAndSave\*.*

[Opera_9]
FileBackupDirMode=Auto
Bookmarks1=\Windows\Opera9\opera6.adr
Bookmarks2=\Windows\Opera9\Profile\opera6.adr
Cookies1=\Windows\Opera9\cookies4.dat
Cookies2=\Windows\Opera9\Profile\cookies4.dat
Secure=\Windows\Opera9\secure\wand.dat
Settings=\Windows\Opera9\opera.ini
Skin=\Windows\Opera9\Skin\*.*

[Opera_10]
FileBackupDirMode=Manual
cookies=\Program Files\Opera Mobile 10\profile\cookies4.dat
pass=\Program Files\Opera Mobile 10\profile\secure\wand.dat
prof1=\Program Files\Opera Mobile 10\profile\datastorage\*.*,*
prof2=\Program Files\Opera Mobile 10\profile\op*.dat
prof3=\Program Files\Opera Mobile 10\profile\*.ini

[Sounds]
FileBackupDirMode=Manual
MP31=\Windows\*.mp3
WAV1=\Windows\*.wav
WMA3=\Windows\*.wma
MP32=\Windows\Rings\*.mp3
WAV2=\Windows\Rings\*.wav
WMA3=\Windows\Rings\*.wma

[AppData_StartMenu_StartUp]
FileBackupDirMode=Manual
htcAudMgr=\Application Data\HTC\AudioManager_Eng\*.*,*
htcDownMgr=\Application Data\HTC\DownloadManager\*.*,*
htcStocks=\Application Data\HTC\ygo\*.*,*
htcTwitter=\Application Data\HTC\Twitter\*.*,*
StartMenu=\Windows\Start Menu\Programs\*.*,*
StartUp=\Windows\StartUp\*.*
Themes=\Windows\*.tsk

regexport.ini
- anything set to "Auto" gets saved to _Mod_\filesREG
- anything set to "Manual" gets saved to _Mod_\_Manual\filesREG


NOW SUPPORTS (as of version 1.1) 6Fg8's customRegExport Mod, see below for explanation and HEED THE WARNING!!!
The mod allows additional parameters in REGEXPORT.INI:
Code:
[COLOR=Blue]key1=<yourkeypath1>
key2=<yourkeypath2>,<value1>,<value2>,<value3>, ... ,<valueN>
key3=<yourkeypath3>,*[/COLOR]

key1 is the traditional way of exporting registry keys as its already implemented. It exports this key including all values/subkeys.
key2 specifies a key, plus the value names you want to export (value1-valueN). Value names are CASE SENSITIVE (!), if they dont match you end up with an empty key.
key3 specifies a key, plus ALL values, but WITHOUT subkeys.

WARNING: DO NOT mix filtered (like in key2, key3 examples) and unfiltered keys (key1) in the same section, as this will lead to missing values. If you need to do this, split them into separate sections.

examples from my own usage:
Code:
[COLOR=Purple][B][Opera vibration][/B][/COLOR]
[COLOR=Blue]RegExportDirMode=Auto
key1=HKEY_LOCAL_MACHINE\Software\Opera\Defaults,VibrationEnabled
[/COLOR] 
[COLOR=Purple][B][power+backlight settings][/B][/COLOR]
[COLOR=Blue]RegExportDirMode=Auto
key1=HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Power\Timeouts,BattSuspendTimeout,BattSuspendTimeoutSave,ACSuspendTimeout,ACSuspendTimeoutSave
key2=HKEY_CURRENT_USER\ControlPanel\BackLight,BatteryTimeout,BatteryTimeoutUnchecked,ACTimeoutUnchecked
[/COLOR]
Code:
[1000_MySettings]
RegExportDirMode=Auto
Attachments=HKLM\System\Inbox\Settings\AttachPath
AudioGateway=HKLM\Software\Microsoft\Bluetooth\AudioGateway
Backlight=HKCU\ControlPanel\Backlight
BLTimeouts=HKLM\System\CurrentControlSet\Control\Power\Timeouts
Clock=HKLM\Software\Microsoft\Clock
JPG1=HKCR\.jpg
Notifications=HKCU\ControlPanel\Notifications
Phone=HKCU\ControlPanel\Notifications\Phone
PhVol=HKCU\ControlPanel\PhoneVolume
PictureLoc=HKLM\System\Pictures\Camera\OEM\PictureLocation
SavLocAud=HKCR\SystemFileAssociations\audio\shell\save\Save Location
SavLocIE=HKCU\Software\Microsoft\Internet Explorer\Main\Default storage location
SavLocImg=HKCR\SystemFileAssociations\image\shell\save\Save Location
SavLocVid=HKCR\SystemFileAssociations\video\shell\save\Save Location
SoundCategories=HKCU\ControlPanel\SoundCategories
Sounds=HKCU\ControlPanel\Sounds
TCPWindowsSize=HKLM\Comm\tcpip\Parms
Volume=HKCU\ControlPanel\Volume
Wallpaper=HKCU\ControlPanel\Desktop
WMV1=HKCR\.wmv

[1001_TarkimSettings]
RegExportDirMode=Auto
KeyConfig=HKLM\Software\KeyboardConfig

[1002_HTCSoftwareHKCU]
RegExportDirMode=Auto
Camera=HKCU\Software\HTC\Camera
DownloadMgr=HKCU\Software\HTC\DownloadManager
Manila=HKCU\Software\HTC\Manila
People=HKCU\Software\HTC\People
TaskManager=HKCU\Software\HTC\TaskManager

[1003_HTCSoftwareHKLM]
RegExportDirMode=Auto
AudioBooster=HKLM\Software\HTC\AudioBooster
AudioManager=HKLM\Software\HTC\AudioManager_Eng
Camera=HKLM\Software\HTC\Camera
Config=HKLM\Software\HTC\Manila\Configuration
Facebook=HKLM\Software\HTC\FacebookSDK
InternetPush=HKLM\\Software\HTC\Manila\InternetPush
PhoneExtended=HKLM\Software\HTC\PHONE\PhoneExtendSetting
SlidingSound=HKLM\Software\HTC\SlidingSound
StartUpAnimation=HKLM\Software\HTC\HTCAnimation
Twitter=HKCU\Software\HTC\TwitterApp
YouTube=HKLM\Software\HTC\YouTube

[1004_Co0kie]
RegExportDirMode=Auto
Co0kie=HKLM\Software\HTC\Manila\Co0kie
Home=HKLM\Software\HTC\Manila\Home
Tasks=HKLM\Software\HTC\Manila\Tasks

[1005_HTCAccountMgr]
RegExportDirMode=Manual
AccountManager=HKLM\Software\HTC\HTCAccountManager

[1006_StartMenuIcons]
RegExportDirMode=Auto
StartMenuIcons=HKLM\Security\Shell\StartInfo\Start

[1007_MySoftwareHKCU]
RegExportDirMode=Auto
7zip=HKCU\Software\7-zip
ArkSwitch=HKCU\Software\ARKconcepts
DualBoot=HKCU\Software\Gen.Y
Changescreen=HKCU\Software\idevelopstuff\changescreen
FacebookApp=HKCU\Software\Microsoft\Facebook
Modaco=HKCU\Software\Modaco
Mort=HKCU\Software\Mort
Mosko=HKCU\Software\mosko.mobi
neuLight=HKCU\Software\Wei Enterprise
Palringo=HKCU\Software\Parlingo
PIMBackup=HKCU\Software\FdcSoft
QuickMenu=HKCU\Software\AlenSoft
RSS=HKCU\Software\Ilium Software
SIPChange=HKCU\Software\The Paradigm Group
SK=HKCU\Software\sk
TotalCommander=HKCU\Software\Ghisler
xTep=HKCU\Software\xTep

[1008_MySoftwareHKLM]
RegExportDirMode=Auto
Adobe=HKLM\Software\Adobe
AdvancedConfig=HKLM\Software\AdvancedConfig
eT9=HKLM\Software\Tegic\eT9
IE=HKLM\Software\Microsoft\Internet Explorer
Opera=HKLM\Software\Opera
PocketMusic=HKLM\Software\PocketMind
SRS=HKLM\Software\SRS
TouchInCallScreen=HKLM\Software\Marzens

[1009_Services]
RegExportDirMode=Auto
Stowaway=HKLM\Services\Stowaway
HTCVol=HKLM\Services\HTCVOLUME
MyPhone=HKLM\Services\MyPhoneService
MediaLibrary=HKLM\Services\MLUService
WinLive=HKLM\Services\Windows Live
PushInternet=HKLM\Services\PushInternetEngine
BTSyncServ=HKLM\Services\BthAsPlugin

deleteops.ini
- below is an example of the deleteops.ini
- used to delete individual files or entire folders
- wildcard (*) can be used

Code:
[DeleteFile]
file1=\Windows\StartUp\HTC*Up.lnk
file2=\Windows\StartUp\sdim.lnk
file3=\Windows\StartUp\Setup*.lnk
file4=\Windows\StartUp\LockDevice.lnk

[DeleteFolder]
folder1=\Windows\Start Menu\Programs\Games
folder2=\Windows\Start Menu\Programs\GPS
folder3=\Windows\Start Menu\Programs\*net
folder4=\Windows\Start Menu\Programs\Multimedia
folder5=\Windows\Start Menu\Programs\Office Mobile
folder6=\Windows\Start Menu\Programs\Tools

anyfilename.auto
- below is an example of an ".auto" file
- used to automate cab installs that require user input

Code:
[AutoFile]
InstallLocation= (0 = device, 1 = storage card)
WindowTitle="Keyboard and Mouse Setup" (name of window to perform actions on)

[ScriptCommands]
1=SendLeft
2=sleep(100)
3=SendCR
4=sleep(1500)
5=SendOK



customlinks.ini
- if you want a link for a specific cab to be installed
- to a different directory than the default
- put exact cab file name without extension as first param
- wildcard (*) can be used
- after cab is installed, the link will be moved to where you want it

Code:
[LNK Files]
Myapp-version*=Programs\MyApps
regedit.Rpr_ARM=Programs\Registry Tools
kevtris=NONE
*=Programs\Other Tools

exeparams.ini
- same as above, filename (no ext) as it exists in _Mod_\filesEXE as first parameter
- parameters go after the equals sign

Code:
[EXE Parameters]
cusTSK=\Windows\Windows Mobile Green.tsk



scriptparams.ini
- same as above, scriptname (no ext) as it exists in _Mod_\filesMSCR as first parameter
- parameters go after the equals sign, inside the quotes

Code:
[Script Parameters]
MyScript="varone=one vartwo=two varthree=three"
 
Last edited:

Cingularman

Member
Dec 22, 2006
11
0
Your zip file

Your zip file doesn't work. It gives errors when you try to unzip it.

BTW I search the whole xda for a post saying this and I didn't find one...lol
 

blast0id

Senior Member
Great reference Ben..as always very well done!
thanks, just trying to be a contributing member, even if "my" stuff isn't exactly 100% original... MortScript is getting easier by the minute for me, coming from self taught php background a lot of it is similar or the same even... I'm sure there's some languages that php resembles... but I'm not really a programmer of any sort, just an accomplished "tinkerer" heh...
 

shannyb1972

Member
Jul 3, 2009
39
1
I posted this in the Energy thread - it was suggested I ask here... any help would be great. Thanks.

Hi -

Can you give me a step by step on the order in which you do stuff after flashing (when to reinsert the sim card, when to run PIM Backup, etc.)? I basically stole your entire XDA_UC (thank you btw!) just adding a couple files and reg settings for some applications and a few things don't seem to work for me (i.e., my favorite people never come back in the right order or even the right people, my hotmail gets screwed up, etc.). I just can never seem to get any of the backups to work exactly right and I've tried SASHIMI, NRG's Export/Importer, and XDA_UC. I just think I'm doing something at the wrong time and things are stepping on each other or something. Anyway, thanks for the help!

PS I'm installing the latest 23xxx CHT rom via SD card ...
 

blast0id

Senior Member
Hi -

Can you give me a step by step on the order in which you do stuff after flashing (when to reinsert the sim card, when to run PIM Backup, etc.)? ...snip...

PS I'm installing the latest 23xxx CHT rom via SD card ...

sorry for the slow reply, had to pick up my Dad from his elbow surgury and ran into car trouble on the way home (he just spent almost 6k on fixing that stupid thing in about a 2mo period... lol)

anywas... if THIS POST doesn't answer all your questions feel free to ask anything more specific =)
 

blast0id

Senior Member
Maybe we ought to start sponsoring you (like we did NRG for a new Fuze) so you can get a European car? :):)

lol... no, not my car = crap. my dad's car... lol... my car, Lexus IS300 = wrecked (not the one in sig) into the back of my best friends truck, back in July, was looking (rubbernecking) at flipped car on other side of road, road was wet, person in front of my friend slammed on their brakes to turn left (while I was looking at flipped car) I slid into back of my friends Nissan Titan (I now call them wreckalexuses) LOL I will get another one soon enough, I just got screwed by my insurance company AND GAP coverage and ended up having to pay out because they decided to total it... only thing holding me back at the moment is a 9-5er (or 11-7, hell I'd take anything right now... lol) so no worries...

Look at me! I'm cluttering my own thread!!! heheeee
 

ceesheim

Retired Forum Moderator
Jun 11, 2009
3,455
2,287
No Android Fanboys Please !!!
here is a quick question:
I want to copy a folder and his content from storage card to My Documents\My Pictures.

so from : Storage Card\XDA_UC\Files\ ( ProGloss_60%) this is the folder to be copied )

to : \\\My Documents\My Pictures

how can I do that ?
 

shannyb1972

Member
Jul 3, 2009
39
1
sorry for the slow reply, had to pick up my Dad from his elbow surgury and ran into car trouble on the way home (he just spent almost 6k on fixing that stupid thing in about a 2mo period... lol)

anywas... if THIS POST doesn't answer all your questions feel free to ask anything more specific =)

Sorry about the car trouble... no worries, I don't consider less than 24 hours a slow response to a message board anyway. You regular posters on this free community board are more responsive than my help desk at work!

Anyway, your post explains very clearly what you do up to flashing the rom. My question is more about the order to do things AFTER you flash. For example, I flashed the latest yesterday and it says "update complete". What is the order I should do things at that point? When to replace the sim, when to hard reset, when to run PIM backup, do I need to manually disable anything that's running, etc.?

Thanks for your help!
 

blast0id

Senior Member
here is a quick question:
I want to copy a folder and his content from storage card to My Documents\My Pictures.

so from : Storage Card\XDA_UC\Files\ ( ProGloss_60%) this is the folder to be copied )

to : \\\My Documents\My Pictures

how can I do that ?

if that's all you want copied then just place it in XDA_UC\Root\My Documents\My Pictures

then use this part of my copy2root script, put it in a txt file and rename the txt to .mscr and place in the XDA_UC folder :
Code:
  XCopy( "\Storage Card\XDA_UC\Root\*.*", "", TRUE, TRUE )
if you're already using my mod then just place place them in the folder as I first stated and they will be copied during the setup...
 

blast0id

Senior Member
For example, I flashed the latest yesterday and it says "update complete". What is the order I should do things at that point? When to replace the sim, when to hard reset, when to run PIM backup, do I need to manually disable anything that's running, etc.?

Thanks for your help!
O.K... gotcha...

after update:
1. at "update complete" put mSD in
2. put battery back in
3. reboot
4. wait for xda_uc message to pop-up, hit "YES" to start
5. after setup is complete (wait for the second message saying customization is complete, I click NO here)
6. this is where I run TouchProTweak to setup a couple things I haven't figure out how to do via reg settings.
7. remove back cover and slide SIM in over battery (if you don't want to do it this way then slide2shutdown, remove battery and insert SIM)
8. restart
9. wait for connection setup, do setup
10. here is where I enter into manila my facebook, twitter and youtube passwords and link facebook accounts from the all people > updates tab
11. start enjoying your freshly setup rom!

I don't hard reset, because of task29... so far (2wks) I haven't noticed any issues due to not hard resetting after first screen calibration.

as for people tab not being in right order... I don't know if anyone has figured out a fix for that... I don't really use it other than to have those particular people in it, so it doesn't really bother me if it comes back in correct order or not...
 

slinkygn

Member
May 5, 2007
31
1
Boy, I hope this isn't a dumb question... I've searched without any luck, but I can't imagine no one has tried this yet: Is there a way to export ActiveSync settings for XDA_UC? I couldn't find anything like that in the Settings Exporter.
 

Top Liked Posts

  • There are no posts matching your filters.
  • 2
    benjamminzIS -

    I've been meaning to post for some time to say thanks for your scripts. Appreciate your efforts thus far and understand how family takes priority.

    Also wanted to ask about how you would normally like to handle any possibly code update submissions from other users... I can offer to help maintain the code.

    I've followed most of the thread since the 1.6 release. I've had some problems with the code for certain things I needed done, and have done the following:

    1. fixed pimRestore sub
    * "sourcPIM" to "sourcePIM" (from some prior posts)

    2. refactored sub tskKill
    * exitSub in MortScript 4.3.0.11 is broken and the taskKill sub terminates prematurely depending on the code path
    * eliminated the need to use exitSub
    * this caused items like dialerCAB to fail when it could not kill cprog.exe (for CDMA ROMs) properly. This is probably causing other items to fail as well and folks likely think it is something else not working.

    3. modified sub restoreCHT
    * fails if your filename is not exactly "chtbackup.cht" (default)
    * if default filename is not found, the sub will check for the most recent .cht file in the "filesCHT" directory and use that
    * no longer relies on the "default" filename if not found
    * changes are only for CHT 1.8.5 so far as I stopped using CHT 2.0.0.0 for now

    4. added MortScriptVersion output string to Init messages so we can debug what versions of MortScript is in use

    5. modified checking of xdauc.mscr so that the script works with Energy ROMs from Nov 2010 onwards

    Note stuff like tskKill failing is something that I've had problems with since I stated using v1.6 on a bunch of TP2s regardless of the custom ROM (Energy/Stock/etc). It took me a while to figure out it was the ExitSub function that is broken in MortScript 4.3b11 itself.

    I can post an updated version of S4X_Auto.mscr (eg call it 1.6.1) if that is fine with you and others... or I can provide the diff/patch code.

    In the works:
    a. CHT 2.0.0.0 settings restore as I play with it on a test TP2 unit I have
    b. reviewing customlinks.ini handling
    c. checking on your TO DO of pimbackup via ini or some other automated method
    2
    I just used the code to flash the latest Energy ROM. I used the Full Minus backup first. Most things worked really well. It even seemed to import a lot of the cookie settings. One thing I noticed is that I was suprised to see that the Compact start menu was already loaded. It is what I normally use to save memory. What I found however was that it seemed to be operating on top of the standard start menu; ie no memory was gained. I still had to select the compact menu to get the memory I was expecting. Is there something in this code that tried to load the Compact menu but did not disable the Standard menu?

    have you done any editing of the regexport.ini??? or did you just leave it as it is in the package? if you haven't edited it at all, then you may need to add the lines necessary to backup the compact start menu reg settings... I personally don't know where they are, and I don't have my winmo phone with me right now so I can't really look... but since you did a full minus file backup, and (probably) used just the default regexport.ini then quick menu is one of the things already in the default regexport.ini as I used it myself... but the compact start menu entries are not... sorry I can't be of more help right now, but either ask around in the energy threads if anyone knows what the reg entries are for CSM or do some digging in the registry and I'm sure you'll find it... you could also always do a hard reset, then do a full regexport, then change the compact start menu settings from the app, then do another full regexport and then compare the two regexports with winDiff or similar program (Notepad++ comes with a nice compare plugin too)
    2
    To help out benjamminzIS and other users, I am providing my updates to the scripts where applicable.

    Please see the initial discussions starting at post 282:
    http://forum.xda-developers.com/showpost.php?p=10091804&postcount=282

    Attached is: (Jan.17.2011)
    1. S4X_SDAuto_1.62_[updateONLY].zip = updates to the 1.6/1.61 S4X_Auto.mscr script and this file contains the updated mscr file itself and a changelog text file. No package just yet - when/if I do I will update this post.

    Attached is: (Dec.27.2010)
    1. S4X_SDAuto_1.61_[updateONLY].zip = updates to the 1.6 S4X_Auto.mscr script and this file only contains the updated mscr file itself. No package just yet - when/if I do I will update this post.

    2. diff-1.6-to-1.6.1.patch.txt = patch/diff file from 1.6 to my changes

    Please see the next post for my changelogs and additional information.

    Feel free to test and let me know if there are any issues or other items you'd like me to check/fix/research. No promises on issue items that I do not specifically use or have the ability to simulate/test.
    2
    Changelog for updates by powinmo:

    110117
    Version 1.62

    1. Eliminated extra ProcExists checks around tskKills due to prior sub refactoring in 1.61

    2. fixed "sub tandem" so that tandem installs like .cab+.reg work now
    * the calls to FileInstallMethods never passed the proper fType and sType values to allow the tandem item to run
    ** eg, xyz.cab and xyz.reg never installs the xyz.reg file because it continued to pass the "CABfiles" fType/sType vs "REGfiles"
    * tested and verified at least a few .cab+.reg tandem installs

    3. fixed "Sub cabInteract" for failing on Manual CAB installations
    * the free space check during a Manual CABfiles install would fail because the SpaceFree check did not have a valid InstallDestination to use
    ** as a result CAB files in the filesCAB\Manual would sometimes fail due to insufficient free space on the target (would read 0 bytes free on bogus target)

    4. modified "Sub autoPhase" to add in second install pass on:
    a. registry
    * \Storage Card\XDA_UC\_Mod_\files2REG (localized as needed)
    Runs after filesCHT is processed
    * Allows for a final set of .reg imports prior to exiting S4X
    b. mscr
    * Location \Storage Card\XDA_UC\_Mod_\files2MSCR (localized as needed)
    * Runs after filesCHT and files2REG is processed
    * Allows for a final set of mscr scripts to run prior to exiting S4X

    eg, allows for something like after a CHT Import, you can import a direct registry tweak to override some CHT settings from a file in files2REGfrom a .reg file in files2REG

    5. Expose free space check multipler to target location during CAB file installations
    * Sashimi (and S4X inherited) defaulted to a value of 4
    ** if your target destination does not have 4 x the size of your CAB file free, the CAB will not install
    * exposed in autosettings.ini:
    ! section: [AutoSettings]
    ! key name: "freeSpaceMultipler"
    ! value: 1 to 99
    * default to 3 x CABsize if not defined in autosettings.ini

    5. Expose WaitFor text window during SDAuto CAB installations
    * Sashimi (and S4X inherited) defaulted to a value of 10 to 20
    ** if your target CAB did not load wceload within the timeout period it may cause the script to hang or skip
    * exposed in autosettings.ini:
    ! section: [AutoSettings]
    ! key name: "txtWindowWaitFor"
    ! value: 1 to 99
    * default to 25 seconds to wait for the wceload text window to become active
    * may need longer depending on how slow your device is and how large the CAB installations are

    9. tweaked pretty tabbing/spacing for a few lines here and there

    Other:
    a. CHTE2.0.0.0 importing still has issues with loading all settings. Known issue based on what I've seen in the CHTE2.0.0.0 threads.
    b. CHTE1.8.5.1 importing works fine.
    c. Running subsquent S4X sessions may "lockup" when trying to install SDAuto CABs. Basically any Text Window operation (WaitFor or WndExists) may crash after the first execution of S4X. This leads to the script just hanging there and will require you to manually kill the mortscript process. This looks like an issue with Mortscript b11 that S4X has packaged in, and not any fault of a custom ROM or S4X itself.



    101227:

    0. bumped version to 1.61 temporary so my updates can be differentiated from original author until they merge changes

    1. fixed/modified pimRestore sub
    * corrected: "sourcPIM" to "sourcePIM"
    * corrected: sType for PIMRestore registry write was missing - subsequent S4X executions would apply or miss PIB/PIM restores
    * added ability to execute an auto type script for PIB automation
    - auto-type scripts must be in the filesPIM directory
    - if "pimbackup.restore.mscr" was found, this script is run each time a PIB file is restored
    - if <filename>.mscr is found for a specific <filename>.PIB file, this script is run only for that PIB and overrides running the "pimbackup.restore.mscr" file

    2. refactored sub taskKill
    * exitSub(0) in MortScript 4.3.0.11 is broken and the taskKill sub terminates prematurely
    * eliminated the need to use exitSub
    * this caused items like dialerCAB to fail when it could not kill cprog.exe (for CDMA ROMs) properly
    ! If you have seen very odd behavior with items that required a taskkill, this MAY fix your problems...

    3. modifed sub chtRestore
    * fails if your filename is not exactly "chtbackup.cht" (default)
    * if default filename is not found, the sub will check for the most recent .cht file in the "filesCHT" directory and use that
    * no longer relies on the default filename
    * tested against CHT Editor 2.0.0.0 final and 1.8.5.1 - both work fine

    4. added MortScriptVersion output string to Init messages so we can debug what versions of MortScript is in use

    5. modified checking of xdauc.mscr so that the script works with Energy ROMs from Nov 2010 onwards

    6. tweaked pretty tabbing/spacing for a few lines here and there
    1
    OK, here's the fix for the newer energy ROMs... find the S4X_Auto.mscr in the XDA_UC\_Mod_\_bin folder and edit it as such:
    Code:
    ######################################################
    # PREPARING TO RUN MOD ###############################
    ######################################################
    
    	@backLightSettings
    [color=red]	If( scriptProcExists( "xdauc.mscr" ) )
    		waitForActive( "Reset", 30 )
    		sendRight( "Reset" )
    		sendCR( "Reset" )
    	EndIf[/color]

    delete only that which is in RED. enjoy =)