The Following 3 Users Say Thank You to pali For This Useful Post: | ||
|
2011-05-30
, 14:34
|
Posts: 3 |
Thanked: 0 times |
Joined on May 2011
|
#32
|
|
2011-05-30
, 16:49
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#33
|
Instead key_pressed, you can use program evkey (it is in bootmenu package). But also can tell you what key was pressed
evkey is opensource (part of bootmenu project), source here:
https://garage.maemo.org/plugins/scm...nu&view=markup
command read in shell read input from /dev/tty but evkey read it directly without terminal from /dev/input/event*
In future I will push kbd (from ubuntu/debian) and this my recovery-boot to extras repository. So it will be possible to install it in HAM
If somebody confirm that my recovery-boot has no problems, I can push it...
The Following User Says Thank You to Mentalist Traceur For This Useful Post: | ||
|
2011-07-02
, 06:08
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#35
|
Install power-kernel47 or the framebuffer-kernel (or some other kernel with framebuffer console available). I'm not sure what happens if you try to "modprobe fbcon" on a kernel that has fbcon statically compiled instead of as a module, so... yeah. SHOULD be okay, but I had the aforementioned kernel panic thing happen when I did something wrong insmod'ing the watchdog modules or whatever they are. I have also not yet (though it's on my list) tested this with u-boot+kernel kernel images.
modprobe fbcon printf "Press any key to get a shell.../n" for q in 4 3 2 1 0 do printf "$q" if (read -n 1 -t 1) then printf "\b\b" insmod $MODULE_PATH/led-class.ko insmod $MODULE_PATH/leds-lp5523.ko insmod $MODULE_PATH/omap_wdt.ko insmod $MODULE_PATH/twl4030_wdt.ko sleep 1 for p in /sys/bus/platform/devices/*_wdt/misc:*; do n=`basename $p | sed "s/.*://"` rm -f /dev/$n mknod /dev/$n c `cat $p/dev | sed "s/:/ /g"` done for i in 1 2 3 4 5 6; do echo 25 > /sys/class/leds/lp5523\:kb$i/brightness done watchdog -t 15 /dev/watchdog watchdog -t 15 /dev/twl4030_wdt loadkmap < /etc/nokia-n900.kmap sh killall watchdog break fi printf "\b" done
Take note that the white-space are spaces, not tabs... I'm not sure if this is necessary, but it's the norm used in /sbin/preinit, so I went with it. .... I can't think of any reason why it wouldn't support tabs just because it's early in the boot process (unless it's run by nolo vs. the kernel, and nolo parses white-space in a non-standard way), so brave souls may dare to use tabs instead of spaces, and report back what happens.
|
2011-07-03
, 06:58
|
Posts: 842 |
Thanked: 1,197 times |
Joined on May 2010
|
#36
|
name=`busybox uname -r` insmod /lib/modules/$name/font.ko insmod /lib/modules/$name/softcursor.ko insmod /lib/modules/$name/bitblit.ko insmod /lib/modules/$name/fbcon.ko busybox sh $T2S -s 2 -H center -y $y -T 0xF800 -t "line: $?"; y=$((y+20)) pressAnyKey
The Following User Says Thank You to RobbieThe1st For This Useful Post: | ||
|
2011-07-04
, 00:21
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#37
|
Ok, guys, I'm trying to add this to Backupmenu.
I've managed to get fbcon to load(requires bitblit, font and softcursor),
but despite it loading and seemingly giving me a console(I see the boot log in the background, like having a framebuffer kernel), I cannot get an interactive shell.
running 'sh' just ends immediately.
Note that I haven't grabbed 'loadkmap' yet, but I'd expect to *see* a console, even if I can't type much if at all.
Or am I wrong there?
Code:busybox sh $T2S -s 2 -H center -y $y -T 0xF800 -t "line: $?"; y=$((y+20)) pressAnyKey
|
2011-07-04
, 00:46
|
Posts: 842 |
Thanked: 1,197 times |
Joined on May 2010
|
#38
|
The Following 2 Users Say Thank You to RobbieThe1st For This Useful Post: | ||
|
2011-07-04
, 01:52
|
Posts: 2,225 |
Thanked: 3,822 times |
Joined on Jun 2010
@ Florida
|
#39
|
As far as modules go, I might be able to use modprobe... but I'd need to know each module needed so I can copy them into my chroot, else I can't access them.
Based on what you said, I suspect I'm missing some module - Could someone run "modprobe -l" right before "sh" in the recovery console script; give me a list of all loaded modules.
|
2011-07-04
, 02:42
|
|
Posts: 1,030 |
Thanked: 792 times |
Joined on Jun 2009
|
#40
|
The Following User Says Thank You to hawaii For This Useful Post: | ||
Tags |
console, console-mode, framebuffer, recovery, recovery-mode |
|
evkey is opensource (part of bootmenu project), source here:
https://garage.maemo.org/plugins/scm...nu&view=markup
command read in shell read input from /dev/tty but evkey read it directly without terminal from /dev/input/event*
====
In future I will push kbd (from ubuntu/debian) and this my recovery-boot to extras repository. So it will be possible to install it in HAM
If somebody confirm that my recovery-boot has no problems, I can push it...