[Q]scripts tutorial - Galaxy Y GT-S5360 General

what language do I need to learn in order to write scripts.

maybe java

Heartlessangel2001 said:
what language do I need to learn in order to write scripts.
Click to expand...
Click to collapse
I dont know what language to learn but you can easily get tut. by googling them. If you are talking about updater scripts then the language used in it is similar to the language used in linux
Sent from my GT-S5360 using XDA

if you mean the one in the app...its java n c+. the one in kernel c+. in init.d script, linux command. the one in updater script, updater binary script.

Related

[Q] [HELP] ROM NOT WORKING - installation aborts

I have ported a rom for galaxy y. but when i try to install it. It shows installation aborted
any one pls help me.......
ROM's LINK
LINK UPDATED SOON.................................
I use HTC Android kitchen and cygwin
........................................................................................
i dont know about update script. plsssss HELPPP
U have to make a thread in general sec
Use CWM or another updater-script.
this question is about developing a new rom. IMO its ok to post here.
@dineshlives: did you use dsixdia kitchen? if yes, you should modify the script. the script generated by dsixdia doesn't work for SGY. if you only have minor modification (without custom kernel or a2sd) you may check hybrid's or myss's script. if you use custom kernel or a2sd. you may see bazz's, or repencis's. those two last is harder to use and may not work. but both hybrid's or myss's works fine without any modification as long as you don't touch /system/bin and /system/xbin.
HELP
kurotsugi said:
this question is about developing a new rom. IMO its ok to post here.
@dineshlives: did you use dsixdia kitchen? if yes, you should modify the script. the script generated by dsixdia doesn't work for SGY. if you only have minor modification (without custom kernel or a2sd) you may check hybrid's or myss's script. if you use custom kernel or a2sd. you may see bazz's, or repencis's. those two last is harder to use and may not work. but both hybrid's or myss's works fine without any modification as long as you don't touch /system/bin and /system/xbin.
Click to expand...
Click to collapse
I dont know much about script
pls help me
can u provide link for the script.................
plssssssss help im new for developing roms
tell me...what feature do you want to be added in your rom?
dineshlives said:
I dont know much about script
pls help me
can u provide link for the script.................
plssssssss help im new for developing roms
Click to expand...
Click to collapse
open their roms and copy the scripts from META-INF folder
Questions or Problems Should Not Be Posted in the Development Forum
Please Post in the Correct Forums & Read the Forum Rules
Moving to Q&A
hell_lock said:
open their roms and copy the scripts from META-INF folder
Click to expand...
Click to collapse
thats not enough...he should copy /system/bin and /system/xbin too.
kurotsugi said:
thats not enough...he should copy /system/bin and /system/xbin too.
Click to expand...
Click to collapse
wow ty fr tellin dat..
which type of rom it is
Custom obviously!
Sent from my AURORA ULTRA GT-S5360 through XDA Premium Customized by Androhacker Xavier
What you have to do (keeping in mind that you are new) is take boot.img of some other rom.
Sent from my AURORA ULTRA GT-S5360 through XDA Premium Customized by Androhacker Xavier
Just make it flashable
kurotsugi said:
tell me...what feature do you want to be added in your rom?
Click to expand...
Click to collapse
just make the rom flashable
Its a sony ericsson xperia mod for sgy
somkll said:
which type of rom it is
Click to expand...
Click to collapse
Its a sony ericsson xperia mod for sgy
I've made a guide to customize or make a new rom. you may check it on dev section.

[HELP] Kernel and Kernel Modules

Hi to all devs here,
I am currently creating a new ROM with modified stock kernel. Currently I have basic features for the ROM and for my kernel, what I have is init.d support. I would like to add the following kernel modules:
DroidWall
Governors and IO Scheduler
BaCem
EXT4
Now, would copying the modules to system/lib/modules do the trick? Or do I need anything else? I'm currently new in creating custom ROMS, so any help/advise is greatly appreciated.
Also, can anyone give me the link for SpareParts.apk? I have seen many spareparts.apk but all of them are from creeds rom.
Thanks,
Carl
you'll need init.d script to call the modules. for bacem tweak, you should put the init.d script from irfan's thread since it also contain the script needed to set the voltage and fix the bug in bacem tweak. for another modules, you'll only need to call the modules in boot via init.d script. you can use these script
Code:
#!/system/bin/sh
insmod <location of modules1>
insmod <location of modules2>
the modules are usually stored in /sytem/lib/modules so you'll need to replace <location of modules> with /system/lib/modules/<module name>. after boot you can check whether if the modules loaded or not by typing "lsmod" in terminal.
EDIT: you can find sparepart.apk in my thread about one pack tweak.
can i use ur kernel in m stock rom...if yes put it
Sent from my GT-S5360 using xda premium
kurotsugi said:
you'll need init.d script to call the modules. for bacem tweak, you should put the init.d script from irfan's thread since it also contain the script needed to set the voltage and fix the bug in bacem tweak. for another modules, you'll only need to call the modules in boot via init.d script. you can use these script
Code:
#!/system/bin/sh
insmod <location of modules1>
insmod <location of modules2>
the modules are usually stored in /sytem/lib/modules so you'll need to replace <location of modules> with /system/lib/modules/<module name>. after boot you can check whether if the modules loaded or not by typing "lsmod" in terminal.
EDIT: you can find sparepart.apk in my thread about one pack tweak.
Click to expand...
Click to collapse
Thank you sir kurotsugi. BTW, do i need to include the extension of the module like this:
Code:
insmod /system/lib/modules/modulename.ko
CarlDeanCatabay said:
Thank you sir kurotsugi. BTW, do i need to include the extension of the module like this:
Code:
insmod /system/lib/modules/modulename.ko
Click to expand...
Click to collapse
Sure...
Sent from my GT-S5360 using xda app-developers app
be carefull if yo're using ext4 as a modules. it should be mounted first before another script running and don't ever change your /data, /system, and /cache partition to ext4.
kurotsugi said:
be carefull if yo're using ext4 as a modules. it should be mounted first before another script running and don't ever change your /data, /system, and /cache partition to ext4.
Click to expand...
Click to collapse
Sir...if i change ext3 to ext4 in ur ope pack tweak, can i mount ext4?
Sent from my GT-S5360 using xda app-developers app
theoritically it will work only if your kernel support it and you have loaded ext4 modules before mount command. never interested to test it. ext3 is easier and better.
kurotsugi said:
theoritically it will work only if your kernel support it and you have loaded ext4 modules before mount command. never interested to test it. ext3 is easier and better.
Click to expand...
Click to collapse
Bro, how to change /system /data and /cache from ext4 to rfs ??
our default system partition is already in rfs. you can modify ext4 file from maroc to revert it.
kurotsugi said:
our default system partition is already in rfs. you can modify ext4 file from maroc to revert it.
Click to expand...
Click to collapse
I know, but somehow i format /cache to ext4. Maybe. Coz when i create backup nandroid file is cache.ext4.tar else is system.rfs.tar and data.rfs.tar
And yes it show in /sys/fs/ext4/stl10 which mean /cache partition fyi i use my kernel that support ext4.
I want to change /cache from ext4 to rfs again but dont know how try with tick repartition in odin still no hope just stuck in download mode.
Code:
ui_print("Starting Operation...");
show_progress(0.1, 0);
unmount("/cache");
ui_print("Formarting cache with rfs...");
format("rfs", "EMMC", "/dev/block/stl10");
ui_print("Mount cache with rfs...");
mount("rfs", "EMMC", "/dev/block/stl10", "/cache");
show_progress(0.1, 100);
ui_print("Done");
ui_print("All praise is due to Allah");
its an updater script. you can give it a shot
Hi devs,
I would like to ask few more n00b questions:
1. Should I put EXT4 at 00EXT4_module or 00bacem-tweak and put ext4 at 01 inside init.d?
2. How do I set the default keyboard for a custom ROM
3. How do I get 14 Toggle Status Bar + Swipe to Clear Notification working on DXLE1? It works on lower firmware version but on DXLE1, it makes the status bar disappear.
PS. I don't want to start another thread so I am asking here. Thanks in advance!
Sorry Sir I can't help u bt advice to change heading so ppl vil cum to knoe wat ur askin by reading only heading
sent using repencis 3.5 wid a2sd
DELETED
Sent from my GT-S5360 using xda app-developers app
Sir....
I just can help no. 2 and 3
2. Choose ur keyboard in Settings>locale and text>choose ur keyboard..this step just make ur keyboard as default
3.u can use system-unsigned and framework.jar in http://forum.xda-developers.com/showthread.php?t=1691397 I use this and work perfectly
Sent from my GT-S5360 using xda app-developers app
shoutokuyaki said:
Sir....
I just can help no. 2 and 3
2. Choose ur keyboard in Settings>locale and text>choose ur keyboard..this step just make ur keyboard as default
3.u can use system-unsigned and framework.jar in http://forum.xda-developers.com/showthread.php?t=1691397 I use this and work perfectly
Sent from my GT-S5360 using xda app-developers app
Click to expand...
Click to collapse
I think he is askin how to make any 3rd party keyboard as a system/default keyboard while compiling rom
I might b wrong bt u tried to help him
sent using repencis 3.5 wid a2sd
press thnxxx
CarlDeanCatabay said:
Hi devs,
I would like to ask few more n00b questions:
1. Should I put EXT4 at 00EXT4_module or 00bacem-tweak and put ext4 at 01 inside init.d?
Click to expand...
Click to collapse
i don't get it. do you mean the script used to call the modules? if yes, it doesn't matter where you put it. you'll only need to make sure that it run before another script, especially a2sd script or similar method. you can easily arrange the sequence by the number and alphabet.
2. How do I set the default keyboard for a custom ROM
Click to expand...
Click to collapse
if you still have the default keyboard, our system will use that as default keyboard. you can remove it so your keyboard will work as default but make sure that your keyboard is working since not all 3rd party keyboard could work as system app.
3. How do I get 14 Toggle Status Bar + Swipe to Clear Notification working on DXLE1? It works on lower firmware version but on DXLE1, it makes the status bar disappear.
PS. I don't want to start another thread so I am asking here. Thanks in advance!
Click to expand...
Click to collapse
if there's no status bar FC issue the problem could come from improper method of compiling the apk. it sometimes happen when we use old apktool version. dxlc and dxle are using similar framework, you can try to use systemUI from another custom rom based on dxlc for an alternative if you can't solve that compiling issue.

Asking permission and Scripts

I have two very separate questions.
1. What would happen if you took a .sh script file, renamed it without the .sh, and stuck it in the init.d folder?
2. Would anyone let me use their rom as a base? The more stock the better. Preferably ICS. Full credit would be given. Tia!
Sent free-falling from space
1 depends on what script it is and what it does
2 do that in pm and pick a rom yourself then ask.
XDA Moderator
The script I was thinking of was yours and zepplinrox.
And thanks for your response.
Sent free-falling from space
Flashdot said:
The script I was thinking of was yours and zepplinrox.
And thanks for your response.
Sent free-falling from space
Click to expand...
Click to collapse
Both of our scripts must be run in script manager and they ask questions. Then create scripts that go in ur init.d folder. So the .sh scripts can't go like u ask, also zep and my scripts can't be run at same time. They conflict.
XDA Moderator

[Q] Trying to enable init.d tweaks = Fail.. Help me?

Me and a buddy are going to begin our development on an custom GB ROM and right now, we're stuck in the development process thanks to impossibility to enable init.d tweaks. I've followed the guideline on this one (first post, first page) but I can't understand how to make init.d tweaks work on Arc S..
So, someone that can help me with this problem ASAP?
Google "enable init.d".
Sent from myushi
XperienceD said:
Google "enable init.d".
Sent from myushi
Click to expand...
Click to collapse
Already done it. The guide is simple but confusing because I can't make it work.. /:
Sent from my GT-I9300 using xda app-developers app
Destroyedbeauty said:
Already done it. The guide is simple but confusing because I can't make it work.. /:
Sent from my GT-I9300 using xda app-developers app
Click to expand...
Click to collapse
There are two guides, what you've linked to is a collection, which of the two showing how to enable it isn't working?
Sent from myushi
XperienceD said:
There are two guides, what you've linked to is a collection, which of the two showing how to enable it isn't working?
Sent from myushi
Click to expand...
Click to collapse
This:
" Init.d
(needs ROM with init.d access and busybox, open empty file, insert header #!/system/bin/sh and put these there, save in /system/etc/init.d and name it something like 77tweaks) "
I'm trying to do it the same way as this guide are telling me but after entering the init.d folder - I am lost, totally. Create / open empty file? How? And what shall I type down in that file? Help me.. I am stuck atm.
Sent from my GT-I9300 using xda app-developers app
Destroyedbeauty said:
I'm trying to do it the same way as this guide are telling me but after entering the init.d folder - I am lost, totally. Create / open empty file? How? And what shall I type down in that file? Help me.. I am stuck atm.
Click to expand...
Click to collapse
Those instructions are just explaining how to create an init.d file, NOT how to enable init.d on your ROM. Your answer is here - how to enable init.d
XperienceD said:
Those instructions are just explaining how to create an init.d file, NOT how to enable init.d on your ROM. Your answer is here - how to enable init.d
Click to expand...
Click to collapse
Okay, after some further checking of the linked thread - I can't still get it in my mind how-to create an init.d file, neither how I should paste and make those init.d scripts come alive.. Here is the problem, and searching on Google isn't helpful at all.. /: help me, please, give me a quick guide on:
1. Create own init.d file
2. Make and enable init.d scripts.
Destroyedbeauty said:
Okay, after some further checking of the linked thread - I can't still get it in my mind how-to create an init.d file, neither how I should paste and make those init.d scripts come alive.. Here is the problem, and searching on Google isn't helpful at all.. /: help me, please, give me a quick guide on:
1. Create own init.d file
2. Make and enable init.d scripts.
Click to expand...
Click to collapse
More reading then as the way to enable it is at my second link and the way to create files is at what you've been reading already.
Sent from myushi

[MOD][5/10/13] Add init.d support to your ROOTED S4

First off, I did not come up with this idea but I adapted it from smokin1337 and his thread: [MOD] EZ InitD - init.d the EZ way !!
How to make it work...
Take file in the attached zip and use your favorite root explorer and paste it in /system/etc/ overwriting the file that is there.
Set permissions of the file to be rwx, rx, rx
Create an init.d folder inside of /system/etc and set permisions to rwx, rx, rx
Add init.d scripts and make sure they are also set to rwx, rx, rx.
Reboot and enjoy your init.d scripts!
All credits to smokin1337 for the mod, I just added the line to our postboot.sh.
I tested it and it works as it should :good:
Enjoy!
-Scott
EDIT: Changed the permissions of the scripts to 755 from 777 to guard against possible malware. Info courtesy of jcase.
Just a note, I use ES File Explorer to do this but any root level explorer should work. I just use ES because I am familiar with it.
Some init.d scripts can rely upon the use of BusyBox so install that from the market.
Sorry for the stupid question but what does this actually do.
What can I get out of it if I install it?
Sent from my SAMSUNG-SGH-I337 using xda app-developers app
azz72 said:
Sorry for the stupid question but what does this actually do.
What can I get out of it if I install it?
Sent from my SAMSUNG-SGH-I337 using xda app-developers app
Click to expand...
Click to collapse
Good question... If you have to ask it then this is not something for you. Haha, Just kidding... But seriously..
Basically init.d scripts are scripts that run when the phone boots up. You can make them do various things like setting system level tweaks, cleaning and purgin databases, and on and on and on...
In the ROMS I build I use an init.d script that remounts the file system more efficiently (in theory anyways) but there are other uses for init.d scripts.
A real popular one is called "V6 Supercharger" Its a collection of scripts that are designed to really tweak out the operating system for the supreme performance (once again, debatable).
There are other things that could be done... If your familiar with old school computing and you know autoexec.bat this is basically that for Android.
-Scott
Gotcha
Ive tried the super charger v6 for my htc inspire a long time ago couldnt tell if it worked or not so I kinda got what ur saying.
Thanks for clearing it up for me
azz72 said:
Gotcha
Ive tried the super charger v6 for my htc inspire a long time ago couldnt tell if it worked or not so I kinda got what ur saying.
Thanks for clearing it up for me
Click to expand...
Click to collapse
Yeah, no problem at all.
scrosler said:
Good question... If you have to ask it then this is not something for you. Haha, Just kidding... But seriously..
Basically init.d scripts are scripts that run when the phone boots up. You can make them do various things like setting system level tweaks, cleaning and purgin databases, and on and on and on...
In the ROMS I build I use an init.d script that remounts the file system more efficiently (in theory anyways) but there are other uses for init.d scripts.
A real popular one is called "V6 Supercharger" Its a collection of scripts that are designed to really tweak out the operating system for the supreme performance (once again, debatable).
There are other things that could be done... If your familiar with old school computing and you know autoexec.bat this is basically that for Android.
-Scott
Click to expand...
Click to collapse
Thanks for the explanation i really needed too before perform this mod thanks
elvin9 said:
Thanks for the explanation i really needed too before perform this mod thanks
Click to expand...
Click to collapse
Yeah, this mod is not your ordinary mod. Most people will never use this type of mod.... Or they do use it in the custom ROM they use and never even know about what it does.
Try using 755 instead of 777, otherwise you are opening yourself up to potential problems.
scrosler said:
First off, I did not come up with this idea but I adapted it from smokin1337 and his thread: [MOD] EZ InitD - init.d the EZ way !!
How to make it work...
Take file in the attached zip and use your favorite root explorer and paste it in /system/etc/ overwriting the file that is there.
Set permissions of the file to be rwx, r, r
Create an init.d folder inside of /system/etc and set permisions to rwx, rwx, rwx
Add init.d scripts and make sure they are also set to rwx, rwx, rwx.
Reboot and enjoy your init.d scripts!
All credits to smokin1337 for the mod, I just added the line to our postboot.sh.
I tested it and it works as it should :good:
Enjoy!
-Scott
Click to expand...
Click to collapse
jcase said:
Try using 755 instead of 777, otherwise you are opening yourself up to potential problems.
Click to expand...
Click to collapse
Responded in updater script thread.
So do we have to find make scripts I'm assuming this just set up the device to work with the scripts
Sent from my SAMSUNG-SGH-I337 using Tapatalk 2
DJsCrIBbLe said:
So do we have to find make scripts I'm assuming this just set up the device to work with the scripts
Sent from my SAMSUNG-SGH-I337 using Tapatalk 2
Click to expand...
Click to collapse
Right, exactly.
You can peruse the forums and find your favorite "battery saving" and "super charger" scripts.
Gotcha thanks .
Sent from my SAMSUNG-SGH-I337 using Tapatalk 2
I've discovered the same thing you achieve here before, when i was trying to create a swap internal SD for the external, but unfortunately it didn't work, i used your rom on my old Note 2, it was amazing hope to see CleanROM for this one. Thanks for publishing this.
juanyunis said:
I've discovered the same thing you achieve here before, when i was trying to create a swap internal SD for the external, but unfortunately it didn't work, i used your rom on my old Note 2, it was amazing hope to see CleanROM for this one. Thanks for publishing this.
Click to expand...
Click to collapse
Yeah, I am starting to grow frustrated. Hopefully soon!

Categories

Resources