[Galaxy S II Q&A, Help & Troubleshooting] Frugipon:
[EDIT] Please delete, problem solved: went through each line using Script Manager Editor and removed last character of each line adding a ";" at the end

Hi all,

I'm having trouble to get my first init.d to work.

Here it is:

#!/system/bin/sh
#-------------------------------------------------------------
#Governor & Scheduler screen ON (screen OFF handled by setCpu)
#-------------------------------------------------------------
echo "ondemand" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
echo "bfq" > /sys/block/mmcblk0/queue/scheduler
#-------------------------------------------------------------

#------------------------
#CPU Frequency & Voltages
#------------------------
#Set frequency steps according to the number of steps in your kernel.
echo "1600 1400 1200 1000 800 500 200 100" > /sys/devices/system/cpu/cpu0/cpufreq/freq_table

#Set voltages for frequency steps. Changes possible at +/-25mV steps
echo "1400 1300 1175 1100 1000 900 900 900" > /sys/devices/system/cpu/cpu0/cpufreq/UV_mV_table

#Sets global scaling min&max frequencies
echo "500000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
echo "1200000" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
#------------------------

#------------------------
#Ondemand specific tweaks
#------------------------
echo "70" > /sys/devices/system/cpu/cpufreq/ondemand/up_threshold
echo "50000" > /sys/devices/system/cpu/cpufreq/ondemand/sampling_rate
echo "1" > /sys/devices/system/cpu/cpufreq/ondemand/sampling_down_factor
echo "10" > /sys/devices/system/cpu/cpufreq/ondemand/down_differential
#------------------------

#------------------------------------------------------------------------------------
#Smooth scaling parameters (to control governor jumping to higher frequency directly)
#------------------------------------------------------------------------------------
echo "2" > /sys/devices/system/cpu/cpu0/cpufreq/smooth_target
echo "2" > /sys/devices/system/cpu/cpu0/cpufreq/smooth_offset
echo "2" > /sys/devices/system/cpu/cpu0/cpufreq/smooth_step
#------------------------------------------------------------------------------------

#---------------------------------------------------
# Hot Plug Thresholds, Sampling Interval & Frequency
#---------------------------------------------------
#Set second core kick-in threshold for screen-on state
echo "25" > /sys/module/pm_hotplug/parameters/loadl
echo "70" > /sys/module/pm_hotplug/parameters/loadh

#Set second core kick-in threshold for screen-off state
echo "80" > /sys/module/pm_hotplug/parameters/loadl_scroff
echo "100" > /sys/module/pm_hotplug/parameters/loadh_scroff

#Set hot plug sampling intervals for screen-on state
echo "100" > /sys/module/pm_hotplug/parameters/rate
echo "400" > /sys/module/pm_hotplug/parameters/rate_cpuon

#Set hot plug sampling intervals for screen-off state
echo "400" > /sys/module/pm_hotplug/parameters/rate_scroff

#Set frequency below which second core will not be turned on, regardless of thresholds.
echo "600000" > /sys/module/pm_hotplug/parameters/freq_cpu1on
#---------------------------------------------------

#-------------------------------------------
GPU Clock, Voltages, Thresholds & Staycounts
#-------------------------------------------
#Set GPU clocks ( valid values are 400/(x*0.5) where x is an integer >= 2. So valid values will be 400/1,400/1.5,etc. Examples: 40 80 89 100 114 133 160 200 267 400 )
echo "160 267" > /sys/class/misc/gpu_clock_control/gpu_control

#Set GPU voltages (changes possible at +/-50mV ie at 50000 steps)
echo "900000 950000" > /sys/class/misc/gpu_voltage_control/gpu_control

#Set GPU Up and Down thresholds
echo "85% 70% 85% 65%" > /sys/class/misc/gpu_clock_control/gpu_control
#--------------------------------------------

#--------------------------------
#Schedule Multi Core & Idle Modes
#--------------------------------
#disable sched_mc (doing justice to hotplugging)
echo "0" > /sys/devices/system/cpu/sched_mc_power_savings

#enable AFTR
echo "3" > /sys/module/cpuidle/parameters/enable_mask
#--------------------------------

#----------------
#Deepsleep Levels
#----------------
#Set deep sleep frequency & bus speed (L4=800 mhz and 0=400mhz bus speed)
echo "4" > /sys/devices/system/cpu/cpu0/cpufreq/deepsleep_cpulevel
echo "0" > /sys/devices/system/cpu/cpu0/cpufreq/deepsleep_buslevel
#----------------

#--------------
#Charge Current
#--------------
#set AC, Misc & USB charge current
echo "650 450 450" > /sys/devices/virtual/misc/charge_current/charge_current
#--------------

#----------------------------
#Touch Sensitivity Parameters
#----------------------------
#touch sensitivity
echo "50" > /sys/devices/virtual/sec/sec_touchscreen/tsp_threshold
#----------------------------

#-------------------------
#Brightness Curve Settings
#-------------------------
#brightness settings
echo "30" > /sys/class/misc/brightness_curve/min_bl
echo "1" > /sys/class/misc/brightness_curve/min_gamma
echo "24" > /sys/class/misc/brightness_curve/max_gamma
#-------------------------

When I try to execute it via script manager I get the following log:

Out:
exec sh '/mnt/sdcard/SiyahByFrug (2)'
# exec sh '/mnt/sdcard/SiyahByFrug (2)'
/mnt/sdcard/SiyahByFrug (2): line 5: can't create /sys/devices/system/cpu/cpu0/cpufreq/scaling_g: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 6: can't creat: nonexistent directoryeue/scheduler
: not found/SiyahByFrug (2): line 8:
/mnt/sdcard/SiyahByFrug (2): line 13: can't create /sys/devices/system/cpu/cpu0/cpufreq/freq_tab: nonexistent directory
: not found/SiyahByFrug (2): line 14:
/mnt/sdcard/SiyahByFrug (2): line 16: can't create /sys/devices/system/cpu/cpu0/cpufreq/UV_mV_ta: nonexistent directory
: not found/SiyahByFrug (2): line 17:
/mnt/sdcard/SiyahByFrug (2): line 19: can't create /sys/devices/system/cpu/cpu0/cpufreq/scaling_: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 20: can't create /sys/devices/system/cpu/cpu0/cpufreq/scaling_: nonexistent directory
: not found/SiyahByFrug (2): line 22:
/mnt/sdcard/SiyahByFrug (2): line 26: can't create /sys/devices/system/cpu/cpufreq/ondemand/up_t: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 27: can't create /sys/devices/system/cpu/cpufreq/ondemand/samp: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 28: can't create /sys/devices/system/cpu/cpufreq/ondemand/samp: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 29: can't create /sys/devices/system/cpu/cpufreq/ondemand/down: nonexistent directory
: not found/SiyahByFrug (2): line 31:
/mnt/sdcard/SiyahByFrug (2): line 35: can't create /sys/devices/system/cpu/cpu0/cpufreq/smooth_t: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 36: can't create /sys/devices/system/cpu/cpu0/cpufreq/smooth_o: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 37: can't create /sys/devices/system/cpu/cpu0/cpufreq/smooth_s: nonexistent directory
: not found/SiyahByFrug (2): line 39:
/mnt/sdcard/SiyahByFrug (2): line 44: can't crea: nonexistent directoryug/parameters/loadl
/mnt/sdcard/SiyahByFrug (2): line 45: can't crea: nonexistent directoryug/parameters/loadh
: not found/SiyahByFrug (2): line 46:
/mnt/sdcard/SiyahByFrug (2): line 48: can't create /sys/module/pm_hotplug/parameters/loadl_scrof: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 49: can't create /sys/module/pm_hotplug/parameters/loadh_scrof: nonexistent directory
: not found/SiyahByFrug (2): line 50:
/mnt/sdcard/SiyahByFrug (2): line 52: can't crea: nonexistent directoryug/parameters/rate
/mnt/sdcard/SiyahByFrug (2): line 53: can't crea: nonexistent directoryug/parameters/rate_cpuon
: not found/SiyahByFrug (2): line 54:
/mnt/sdcard/SiyahByFrug (2): line 56: can't crea: nonexistent directoryug/parameters/rate_scroff
: not found/SiyahByFrug (2): line 57:
/mnt/sdcard/SiyahByFrug (2): line 59: can't crea: nonexistent directoryug/parameters/freq_cpu1on
: not found/SiyahByFrug (2): line 61:
/mnt/sdcard/SiyahByFrug (2): line 63: GPU: not found
: not found/SiyahByFrug (2): line 63: Staycounts
/mnt/sdcard/SiyahByFrug (2): line 66: can't crea: nonexistent directoryclock_control/gpu_control
: not found/SiyahByFrug (2): line 67:
/mnt/sdcard/SiyahByFrug (2): line 69: can't create /sys/class/misc/gpu_voltage_control/gpu_contr: nonexistent directory
: not found/SiyahByFrug (2): line 70:
/mnt/sdcard/SiyahByFrug (2): line 72: can't crea: nonexistent directoryclock_control/gpu_control
: not found/SiyahByFrug (2): line 74:
/mnt/sdcard/SiyahByFrug (2): line 79: can't create /sys/devices/system/cpu/sched_mc_power_saving: nonexistent directory
: not found/SiyahByFrug (2): line 80:
/mnt/sdcard/SiyahByFrug (2): line 82: can't crea: nonexistent directoryparameters/enable_mask
: not found/SiyahByFrug (2): line 84:
/mnt/sdcard/SiyahByFrug (2): line 89: can't create /sys/devices/system/cpu/cpu0/cpufreq/deepslee: nonexistent directory
/mnt/sdcard/SiyahByFrug (2): line 90: can't create /sys/devices/system/cpu/cpu0/cpufreq/deepslee: nonexistent directory
: not found/SiyahByFrug (2): line 92:
/mnt/sdcard/SiyahByFrug (2): line 97: can't create /sys/devices/virtual/misc/charge_current/char: nonexistent directory
: not found/SiyahByFrug (2): line 99:
/mnt/sdcard/SiyahByFrug (2): line 104: can't create /sys/devices/virtual/sec/sec_touchscreen/tsp: nonexistent directory
: not found/SiyahByFrug (2): line 106:
/mnt/sdcard/SiyahByFrug (2): line 111: can't cre: nonexistent directoryghtness_curve/min_bl
/mnt/sdcard/SiyahByFrug (2): line 112: can't cre: nonexistent directoryghtness_curve/min_gamma
/mnt/sdcard/SiyahByFrug (2): line 113: can't cre: nonexistent directoryghtness_curve/max_gamma

I don't get, it :confused:

I triple checked using Notepad++ that everything was correct (obiously I overlooked something) and could not find a damn thing.

So here I am, at the point where any help is very much welcome.