View Single Post
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#926
Originally Posted by batman View Post
No thats not working either.. I actualy created a new file called 'originalkernel.txt' and wrote the commands as NoNoYes suggested:

if [ "$QBW_EXEC_REASON" == "QBW_STARTUP_UPDATE" ]; then
# add here switch on instructions
/usr/sbin/kernel-load /home/user/MyDocs/kernel.txt | sudo gainroot
echo "ON";
exit 1;
fi;
if [ "$QBW_CURRENT_RESULTS_TEXT" == "ON" ]; then
# add here switch off instructions
/usr/sbin/kernel-unload /home/user/MyDocs/originalkernel.txt | sudo gainroot
echo "OFF";
exit 0;
else
# add here switch on instructions
/usr/sbin/kernel-load /home/user/MyDocs/kernel.txt | sudo gainroot
echo "ON";
exit 1;
fi;

unfortunately it only loads on Start up (if start up is enabled on the widget) it doesn't want to toggle between on and off states though once activated. I haven't figured out how to create an 'off' state yet

any suggestions or pointers as to what I am doing wrong will be greatly appreciated
try and make sure the kernel-load and unload command do not echo anything. maybe you'd like to stick some
Code:
 >/dev/null
to the sudo gainroot part
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 

The Following User Says Thank You to No!No!No!Yes! For This Useful Post: