Tiny Core Linux

General TC => General TC Talk => Topic started by: Medox on May 19, 2009, 05:40:47 PM

Title: TinyZSNES ! ...and some questions...
Post by: Medox on May 19, 2009, 05:40:47 PM
Hello again,

After Jason W filled my request (http://forum.tinycorelinux.net/index.php?topic=1543.0), I worked on TinyZSNES... a LiveCD just for (z)snes fans, like me :)

It contains zsnes (of course) and ALSA. (ok, nano too but that's not important)
It starts in text mode and loads zsnes automatically with the rom path already set.
Put your roms in the "snesroms" folder (in the iso) so that you find them in zsnes (game -> load)

(http://i79.photobucket.com/albums/j142/Medox2006/Screens/th_TinyZSNESv10RC1-1.jpg) (http://i79.photobucket.com/albums/j142/Medox2006/Screens/TinyZSNESv10RC1-1.jpg) (http://i79.photobucket.com/albums/j142/Medox2006/Screens/th_TinyZSNESv10RC1-2.jpg) (http://i79.photobucket.com/albums/j142/Medox2006/Screens/TinyZSNESv10RC1-2.jpg) (http://i79.photobucket.com/albums/j142/Medox2006/Screens/th_TinyZSNESv10RC1-3.jpg) (http://i79.photobucket.com/albums/j142/Medox2006/Screens/TinyZSNESv10RC1-3.jpg)

I'll put new versions (or just the last ones) in this forder:

http://www.box.net/shared/p02j5j78m1

This is my first public LiveCD so it's still far from what I want or what I could learn from now on... so please test it and tell me it something goes wrong.

Some questions for the next releases:


p.s. I didn't remove the gui... so it still has 3-4 MB's too much but I'll wait for the microcore version... (I don't really know how to strip it down correctly). Then it would be really the smallest zsnes livecd, ever 8)
Title: Re: TinyZSNES ! ...and some questions...
Post by: curaga on May 20, 2009, 08:15:44 AM
The pic is compiled in in the kernel. You can prevent it from showing with the bootcode "logo.nologo".

To shut down after running zsnes, the script would do something like:
Quote
zsnes
poweroff
Title: Re: TinyZSNES ! ...and some questions...
Post by: Medox on May 27, 2009, 11:30:26 AM
@curaga
thanks

Another question/problem...

I made a script that lets me choose if I want to reboot or shut down. Something like this:

echo ...
echo "R - reboot"
echo "Q - turn off"

read -n 1 -s -p option

case $option in

"R" | "r" )
...

* )
echo "Wrong key..."
...

and so on, the script works great with "./options" or something that I run myself but not if I place it after zsnes, in bootlocal.sh. It chooses "* )" automatically and I get "wrong key" instead of letting me press R or whatever.

How do I get the script to really pause & read my pressed key?
Title: Re: TinyZSNES ! ...and some questions...
Post by: curaga on May 27, 2009, 11:56:11 AM
read -n 1 -s -p option

should be

read -n 1 -s -p option option

aka there was no variable to store the result to, and so $option is empty
Title: Re: TinyZSNES ! ...and some questions...
Post by: Medox on May 27, 2009, 12:20:00 PM
thanks but it still jumps right to the * ) case... :-[
Title: Re: TinyZSNES ! ...and some questions...
Post by: curaga on May 27, 2009, 12:30:41 PM
Is zsnes exited with a keypress? maybe that key is taken then
Title: Re: TinyZSNES ! ...and some questions...
Post by: Medox on May 27, 2009, 12:50:48 PM
well, zsnes exits by selecting Game -> Exit (and pressing enter, of course) but that's not the problem, I guess, because even without zsnes, the problem remains and nothing in bootlocal.sh (or scripts that run from here) can pause this script(s) to read a pressed key.

Weird...

I'm trying to solve this for some days now, still nothing :-\
Title: Re: TinyZSNES ! ...and some questions...
Post by: curaga on May 27, 2009, 01:05:54 PM
Ah, bootlocal.sh is backgrounded as not to slow down boot. Since you're running everything from there, you should remove the "&" from the line calling bootlocal.sh in /etc/init.d/tc-config.
Title: Re: TinyZSNES ! ...and some questions...
Post by: Medox on May 27, 2009, 01:17:56 PM
works great! :D

thanks!