Go Back   PPCKitchen > PPCKitchen > Tutorials

Reply
 
Thread Tools Display Modes
  #1  
Old 01-19-2009, 08:55 PM
rstoyguy rstoyguy is offline
Member
Carrier: Sprint
PDA: Diamond
ROM: rstg_5_minutes_ago
 
Join Date: Sep 2008
Location: Midwest
Posts: 42
Thanks: 1
Thanked 57 Times in 18 Posts
Rep Power: 0
rstoyguy is on a distinguished road
Default Tutorial: Adding Registry Entries to your Rom (RGU Method)

About this Tutorial
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
This tutorial will show you how to add registry entries to your cooked rom. If you are wanting to learn about the
registry, follow this link first! http://www.wmexperts.com/articles/ho..._registry.html

A little preparation now, can save you a lot of time later.

This tutorial ASSUMES you have working knowledge of cooking your own rom. I AM NOT RESPONSIBLE FOR ANYTHING THAT HAPPENS TO YOU OR YOUR DEVICE by reading this tutorial! This tutorial will work with most windows-mobile based kitchens, Apache, Titan, Vogue and others.


Credits
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
I would like to thank PPCKitchen.org and all those that made the kitchens possible! You all know who they (you) are!
And a special thanks to Hobbesisreal for the Registry tutorial I've linked, and AcesZHigh for providing the
tutorial basics on WinCeRegeditor! And of course mrgeoff, I found that he was the one that started the base for the registry edits in the RGU that I use and have attached!


Terminology used in this tutorial:
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
OEM - Similar to a .CAB file, this is the method used to add files/programs to a cooked Rom. This is copied to
USER_OEM if using the ppckitchen, or into your OEM folder if you are using another kitchen.
GUID - GUID (or UUID) is an acronym for 'Globally Unique Identifier'. It is a 128-bit integer number used to identify resources.
RGU File - The file in the OEM that contains the registry entries.


What you will need:
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
1. CeRegEditor from: http://ceregeditor.mdsoft.pl/
2. zz_MyRegistry_OEM.zip attached to this post.


The steps involved:
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
This tutorial will teach you how to registry entries to your cooked rom. I will show you how to add the registry entries to the attached zzz_My_Registry_OEM by editing the *.RGU file. So here are the steps:

1. Download and extract "zzz_My_Registry_OEM.zip"
2. Copy "zzz_My_Registry_OEM" to your USER_OEM or OEM folder(s).
3. Registry Basics (If you need more, come back later...)
4. RGU Registry Syntax and proper formatting.
5. RGU file and it's formatting requirements.
6. Identify the registry entries you wish to include.
7. Export and/or enter your edits.
8. Flash and enjoy!


1. Download and extract "zzz_My_Registry_OEM.zip"
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
Ok, who needs help with this one? Be sure to extract with paths!


2. Copy your files to the new directory "zzz_My_Registry_OEM".
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
Just copy the files you want into the zzz_My_Files_OEM directory.
I have already created a custom OEM for you with a unique GUID, a sample initflashfiles.txt, and included a XML
file so the ppckitchen will identify your OEM.


3. Registry Basics
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
First I think we need a little education on registry formats. There are 5 types of registry entries I deal with on
a regular basis. These are:
1. DWord : For entering numerical data
2. String for entering alphanumerical data
3. Multi-string - advanced
4. Hex or binary data - advanced
5. DecDword - A decimal valued DWord. Not currently supported by BuildOS.

All entries must have proper syntax or buildos will not like it and say "Error building xxxxxx Hives". All entries
must have 3 components. The Key or location name, the Value Name, and finally the data. Let's take a look at the registry edit to kill the SMS Sent notification as it would appear as a registry entry for a RGU file:

Code:
; No SMS Sent Notification
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Inbox\Settings]
"SMSNoSentMsg"="1"
Let's examine the three lines above.
Line 1, is how to add a comment. Anything preceded by a ";" is considered a comment to the end of the line.
Line 2, is the Keyname where the value is located that you want to modify. If it does not exist, it will be
created. The Keyname is enclosed in brackets, [ and ].
Line 3, is the Valuename and the data. The value name is always enclosed in quotes.


4. RGU Registry Syntax and proper formatting.
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
That was simple enough, now let's look at the syntax required for the above registry values. These will be
followed by the names from above, an example or two to show the syntax, and then a few comments.

1. DWord : for entering numerical data. This is a HEXADECIMAL VALUE!

"Value1"=dword:00000001
"Value2"=dword:000001cf
"Value3"=dword:1cf

The key here is the value must be in hex! The actual data can be 8 digits long padded by zeroes. You could also omit the leading zeroes and that will work as well.

2. String : For entering alphanumerical data

"Value1"="blah, blah, blah"

This is straight forward. Most data here is text and simply enclosed in quotes. There are some advanced
functions, but I am here to show the basics. PM me or read below on exporting values.

3. Multi-string - advanced

"Curr0"=multi_sz:"alarm2", "", "alarm2", "default", "Empty", "alarm2", "infbeg", "infend", "infend", "", "", "",
"alarm2", "infbeg", "infend", "infend", "alarm2", "", "", "voicbeep", "RecEnd"

This is one that I almost always Export.

4. Hex or binary data - advanced

"AlarmHandle"=hex:\
21,00,00,35,2B,00,00,32,1F,00,00,35,2A,00,00,34,2D ,00,00,34,00,00,00,00,\
18,00,00,36

This is multi-line and I ALWAYS Export these!

5. DecDword - A decimal valued DWord. Not currently supported by BuildOS.
This is not supported by the current kitchens. I was introduced to this while making custom OEM's. It sure would be sweet though!

The OEM below is ALREADY LOADED with most of the registry edits I use in my rom!
Attached Files
File Type: zip zzz_My_Registry_OEM.zip (2.9 KB, 172 views)

Last edited by rstoyguy; 01-19-2009 at 08:57 PM.
Reply With Quote
The Following 7 Users Say Thank You to rstoyguy For This Useful Post:
Choc73 (07-10-2009), crazaytalent (05-08-2009), Deviation (10-07-2009), humble (03-11-2009), mcbean2k (03-13-2009), NagromNniuq (09-09-2009), necosino (10-20-2009)
Sponsored Links
  #2  
Old 01-19-2009, 08:56 PM
rstoyguy rstoyguy is offline
Member
Carrier: Sprint
PDA: Diamond
ROM: rstg_5_minutes_ago
 
Join Date: Sep 2008
Location: Midwest
Posts: 42
Thanks: 1
Thanked 57 Times in 18 Posts
Rep Power: 0
rstoyguy is on a distinguished road
Default

5. RGU file and it's formatting requirements.
-=-=-=- -=-=-=- =-=-=- -=-=-=- -=-=-=-
Now that you have that down, let's talk about the kitchen requirements of a basic RGU file and it's format.

There are 4 basic rules:

1. The first line must be "REGEDIT4"
2. The second line is usualy a blank line. (enter will do just fine.)
3. any thing on a line after a ";" is ignored. This can be at the beginning of the line or after your entry. Comment well so you know what you have!
4. The end of the file always need to have two blank lines! Again enter will work. And while it is debated 1 or two, I always put two to be safe...

Here a complete sample RGU file including the SMS Notification hack from above:

Code:
REDEDIT4
 
; No SMS Sent Notification
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Inbox\Settings]
"SMSNoSentMsg"="1"

6. Identify the registry entries you wish to include.
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
Site to learn more about registry:
http://www.wmexperts.com/articles/ho..._registry.html
You can also find some great links here for additional registry entries...


7. Export and/or enter your edits.
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
The easiest way to do this is by using CeRegistry Editor mentioned above. Here are the steps as explained by
Aceszhigh from his tutorial: Tutorial: Integrating Custom Registry Settings into a ROM w/ ProvXML - Lazy Man's Way

Quote:
Originally Posted by aceszhigh
This part of the tutorial is only for if your tweak does NOT involve creating a completely new
registry key (as opposed to changing the value of an existing key).
1. Install CERegEditor (attached below). This program allows you to access/edit/export your device's registry from
your PC. Very useful!
2. Make sure you have an ActiveSync connection established. Fire up CERegEditor and click Connection -> connect. At
this point your device's registry should come up.
3. Navigate to the key you want to export. This could either be: a) a reg key you have already tweaked on your
current rom, or b) a key that you want to tweak on your future rom.
4. Now click EDIT -> export. NOT Export AS
For me, an error message usually pops up here. Click OK and disregard it.
Type in whatever name you want for the File Name.
SAVE AS a .ceReg! and click save
5. Now, if you are exporting a key from your device which already has been edited the way you want it...Do nothing
for this step.
If you prefer the value of the key to be changed, then open up your .reg file in NOTEPAD and change the value.
Now to open this file, right click on the new *.cereg file and select Open With... then Notepad. Now cut and
paste into the OEM's RGU file. Don't forget formatting!!!!

8. Flash and enjoy!
-=-=-=- -=-=-=- -=-=-=- =-=-=- -=-=-=-
Build your rom and Flash! Now everyTime you need to hard reset, re-flash, you can keep your registry edits if you
wish and know how...

This has been a great timesaver for me in the past, and I hope it will be for too. If you can think of an idea for
another tutorial, send me a pm to let me know and I will see what I can do...
HAVE FUN!!!

You can also find some great links here for additional registry entries...


Note: I will edit the content over the next few day to ensure accuracy and clear content....
Reply With Quote
The Following 5 Users Say Thank You to rstoyguy For This Useful Post:
crazaytalent (05-08-2009), Deviation (10-07-2009), humble (03-11-2009), NagromNniuq (09-09-2009), TheGovernor11 (03-04-2010)
  #3  
Old 01-19-2009, 08:57 PM
rstoyguy rstoyguy is offline
Member
Carrier: Sprint
PDA: Diamond
ROM: rstg_5_minutes_ago
 
Join Date: Sep 2008
Location: Midwest
Posts: 42
Thanks: 1
Thanked 57 Times in 18 Posts
Rep Power: 0
rstoyguy is on a distinguished road
Default

Adding Registry Entries to your Rom (RGU Method)

Reserved for commonly asked questions...

And a partial peek inside the RGU:
Quote:
REGEDIT4

;*** Change Power Settings ***
;================================================= ====
[HKEY_CURRENT_USER\ControlPanel\BackLight]
"ACBrightNess"=dword:00000005
"BatteryTimeout"=dword:0000001E
"BrightNess"=dword:00000005
"ACTimeout"=dword:0000003C
[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Contro l\Power\Timeouts]
"ACSuspendTimeout"=dword:0000012c
[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Contro l\Power\Timeouts]
"BattSuspendTimeout"=dword:0000003C

;*** First Boot Fixes ***
;================================================= =====
[HKEY_LOCAL_MACHINE\Software\Microsoft\Clock]
"GMT_OFFSET"=dword:00000168
"AppState"=hex:11
"TZIndex"=dword:00000004
"HomeDST"=dword:00000001
[HKEY_LOCAL_MACHINE\Drivers\BuiltIn\RIL]
"NITZEnable"=dword:00000001
[HKEY_CURRENT_USER\CONTROLPANEL\PHONEEXTENDFUNCTION \CDMA]
"SyncSystemTime"=dword:00000001

;*** Change Misc Settings ***
;================================================= ======
[HKEY_LOCAL_MACHINE\Software\Microsoft\Shell]
"ShowTitleBarClock"=dword:00000002
[HKEY_LOCAL_MACHINE\Software\OEM\TFLOSettings]
"EnableSound"=dword:00000000
[HKEY_LOCAL_MACHINE\System\ErrorReporting\DumpSetti ngs]
"DumpEnabled"=dword:00000000
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Inbox\Settin gs]
"SMSNoSentMsg"="1"
[HKEY_LOCAL_MACHINE\SOFTWARE\OEM\SMS]
"RecvTimeStamp"=dword:00000001
;Enhance GPS
[HKEY_LOCAL_MACHINE\SOFTWARE\HTC\SUPL AGPS]
"GPSMode"=dword:4
;1/2 second delay for End Button during call
[HKEY_LOCAL_MACHINE\Software\HTC\Phone\PhoneExtendS etting]
"EndCallTime"=dword:50
;disable start/end call sounds
[HKEY_CURRENT_USER\ControlPanel\Sounds\Dialing]
"Script"=""
[HKEY_CURRENT_USER\ControlPanel\Sounds\Ending]
"Script"=""
;disable vol up/down beeps during call
[HKEY_CURRENT_USER\ControlPanel\Sounds\LoudestInCal lVolume]
"Script"=""
[HKEY_CURRENT_USER\ControlPanel\Sounds\QuietestInCa llVolume]
"Script"=""
[HKEY_CURRENT_USER\ControlPanel\Sounds\StandardInCa llVolume]
"Script"=""

; *** Peformance Changes ***
;================================================= =============
[HKEY_LOCAL_MACHINE\System\GDI\GLYPHCACHE]
"limit"=dword:00008000
[HKEY_LOCAL_MACHINE\System\StorageManager\FATFS]
"CacheSize"=dword:00002000
"EnableCache"=dword:00000001
[HKEY_LOCAL_MACHINE\System\StorageManager\Filters\f sreplxfilt]
"ReplStoreCacheSize"=dword:00001000
[HKEY_LOCAL_MACHINE\Comm\AsyncMac1\Parms]
"DisablePowerManagement"=dword:00000000
[HKEY_LOCAL_MACHINE\Comm\Irsir1\Parms]
"DisablePowerManagement"=dword:00000000
[HKEY_LOCAL_MACHINE\Comm\PPTP1\Parms]
"DisablePowerManagement"=dword:00000000
[HKEY_LOCAL_MACHINE\Comm\L2TP1\Parms]
"DisablePowerManagement"=dword:00000000
[HKEY_LOCAL_MACHINE\Drivers\SDCARD\ClientDrivers\Cl ass\SDMemory_Class]
"DisablePowerManagement"=dword:00000000

Reply With Quote
The Following 4 Users Say Thank You to rstoyguy For This Useful Post:
crazaytalent (05-08-2009), Deviation (10-07-2009), humble (03-11-2009), NagromNniuq (09-09-2009)
  #4  
Old 05-08-2009, 02:22 PM
crazaytalent crazaytalent is offline
Junior Member
Carrier: sprint
PDA: htc hernab/touch pro
ROM: starman 6.5 v 1.4
 
Join Date: Apr 2009
Posts: 14
Thanks: 12
Thanked 2 Times in 2 Posts
Rep Power: 0
crazaytalent is on a distinguished road
Default issue savin rgu file after entering changes

thanks for all the help with this, i think i finally got it!... one problem now... after opening rgu w/ notepad and entering my reg edit into the file, w/ the appropriate formatting, im having trouble closing and saving the rgu... i keep gettin a can not create the.... rgu.file eroor, make sure file name and path are correct... seeing as the file is already there and all i did was edit/make an addition, im not getting this error? file name and path must be correct... the path is in the zzz_my registry oem folder< user oems< build os< ppckitchen<program files<c drive... or something like that, correct?

the only thing im thinking is that Im suing the wrong program to make these changes? but im using notepad... any help?

thanks again!
Reply With Quote
  #5  
Old 05-08-2009, 03:38 PM
crazaytalent crazaytalent is offline
Junior Member
Carrier: sprint
PDA: htc hernab/touch pro
ROM: starman 6.5 v 1.4
 
Join Date: Apr 2009
Posts: 14
Thanks: 12
Thanked 2 Times in 2 Posts
Rep Power: 0
crazaytalent is on a distinguished road
Default

just had the thought, instead of editing the pre made rgu file int the zzzz_registry folder, to just copy and past the notepad file from the .cereg export into the the overall folder... is that what you meant... because i was trying to just cut and paste the text into rgu file w/in that folder, but that way it wont save aftrer Ive mad my changes....let me know if im on the right track w/ adding the whole .cereg file to the registry oem folder...

thanks!
Reply With Quote
  #6  
Old 05-29-2009, 07:47 AM
crazaytalent crazaytalent is offline
Junior Member
Carrier: sprint
PDA: htc hernab/touch pro
ROM: starman 6.5 v 1.4
 
Join Date: Apr 2009
Posts: 14
Thanks: 12
Thanked 2 Times in 2 Posts
Rep Power: 0
crazaytalent is on a distinguished road
Default

Quote:
Originally Posted by crazaytalent View Post
thanks for all the help with this, i think i finally got it!... one problem now... after opening rgu w/ notepad and entering my reg edit into the file, w/ the appropriate formatting, im having trouble closing and saving the rgu... i keep gettin a can not create the.... rgu.file eroor, make sure file name and path are correct... seeing as the file is already there and all i did was edit/make an addition, im not getting this error? file name and path must be correct... the path is in the zzz_my registry oem folder< user oems< build os< ppckitchen<program files<c drive... or something like that, correct?

the only thing im thinking is that Im suing the wrong program to make these changes? but im using notepad... any help?

thanks again!
Quote:
Originally Posted by crazaytalent View Post
just had the thought, instead of editing the pre made rgu file int the zzzz_registry folder, to just copy and past the notepad file from the .cereg export into the the overall folder... is that what you meant... because i was trying to just cut and paste the text into rgu file w/in that folder, but that way it wont save aftrer Ive mad my changes....let me know if im on the right track w/ adding the whole .cereg file to the registry oem folder...

thanks!
Any help with this... still havin trouble saving my rgu edits into the rgu file....
Reply With Quote
  #7  
Old 05-29-2009, 07:30 PM
rstoyguy rstoyguy is offline
Member
Carrier: Sprint
PDA: Diamond
ROM: rstg_5_minutes_ago
 
Join Date: Sep 2008
Location: Midwest
Posts: 42
Thanks: 1
Thanked 57 Times in 18 Posts
Rep Power: 0
rstoyguy is on a distinguished road
Default

Is it not letting you save from notepad? Try right clicking and check the file attributes. Remove the read-only attribute... If it is not building, then can you post your RGU and we can help find the error...
Reply With Quote
The Following User Says Thank You to rstoyguy For This Useful Post:
crazaytalent (06-01-2009)
  #8  
Old 06-01-2009, 05:20 PM
crazaytalent crazaytalent is offline
Junior Member
Carrier: sprint
PDA: htc hernab/touch pro
ROM: starman 6.5 v 1.4
 
Join Date: Apr 2009
Posts: 14
Thanks: 12
Thanked 2 Times in 2 Posts
Rep Power: 0
crazaytalent is on a distinguished road
Default

thanks... that seems to have been it... didnt realizer the file was read only... i will be adding a few more reg edit to the file and try a new build tomorrow... thanks for all your help!
Reply With Quote
  #9  
Old 06-03-2009, 06:11 PM
crazaytalent crazaytalent is offline
Junior Member
Carrier: sprint
PDA: htc hernab/touch pro
ROM: starman 6.5 v 1.4
 
Join Date: Apr 2009
Posts: 14
Thanks: 12
Thanked 2 Times in 2 Posts
Rep Power: 0
crazaytalent is on a distinguished road
Default

seems to be an issues w/ vista... i was able to edit the changes to the rgu file that i wanted to add on to, on my external HD.... but on my C:/ it wouldnt let me, even after uncecking the read only box.... so what I ended up doing was making all of my registry add ons to the rgu on my external hd, and then copying and overwriting it to the folder on the c:/ drive...

thanks for all your help!
Reply With Quote
Reply

Bookmarks


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -6. The time now is 01:36 PM.


Design By: Miner Skinz.com
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.