1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Project C3PO - My Linux jukebox

Discussion in 'Project Logs' started by papeniglio, 8 Apr 2004.

  1. Colonel Sanders

    Colonel Sanders Minimodder

    Joined:
    25 Jun 2002
    Posts:
    1,210
    Likes Received:
    4
    Very cool project. :) I'm finally starting some work on a freevo PC, got a 600MHz P3, I think 128MB RAM and an 80GB WD HDD. :) Just finished installing core linux on it tonight. I want to update the kernel to 2.6.5, I already have the source code and it's even on a CD to transfer it to my soon-to-be freevo PC, but it's a *.bz2 file, and being a linux n00b I don't know how to unzip the bz2 file. Any suggestions?

    TIA, L J
     
  2. PsychoI3oy

    PsychoI3oy Minimodder

    Joined:
    13 Apr 2004
    Posts:
    275
    Likes Received:
    0
    cd /usr/src
    bunzip2 <name of file>
    tar xvf <name of resulting file>
    ls -l

    (check to see if linux is a link to another dir or the actual kernel dir itself by looking for the -> after linux on the right)

    if it's a link, do
    rm linux

    if it's not a link do
    mv linux linux.old

    then do:
    ln -s <name of dir for new kernel> linux
    cd linux
    make menuconfig

    the rest is/should be covered in the linux section of the forum, i believe we've hijacked this thread enough as it is :)
     
  3. Colonel Sanders

    Colonel Sanders Minimodder

    Joined:
    25 Jun 2002
    Posts:
    1,210
    Likes Received:
    4
    Oh theres a Linux section of the forums? *feels like super n00b...* Probably should end the hijacking now. Thanks!

    </end hijacking>
    Very nice LCD too. :)

    L J
     
  4. DjFuzz

    DjFuzz What's a Dremel?

    Joined:
    9 Apr 2004
    Posts:
    45
    Likes Received:
    0
    This command line doesn't work for me: get some kind of 'bash' error. He doesn't understand the command setserial. Did i do something wrong here? i did install serial support in the kernel and also the drivers. I have kernel version 2.4.18. (Still have to update it, but i haven't got very much time to play with linux at the moment :()
    Code:
    setserial /dev/ttySx uart none
    Thanks in advance!
     
  5. PsychoI3oy

    PsychoI3oy Minimodder

    Joined:
    13 Apr 2004
    Posts:
    275
    Likes Received:
    0
    i've never messed with serial in linux really but i think you're supposed to change the x to some number (0 for what would be com1 in windows, 1 for com2, etc.)
    so it should be:
    Code:
    setserial /dev/ttyS0 uart none
    or something like that

    again, sorry for the hijack, the linux forum is over there somewhere -->
     
  6. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    No thread hijacking at all! I've always considered the software part a very important one in my project, so all the discussions about linux are welcome (obviously if they are referred to some software related to the player project!).

    As for the setserial, PsychoI3oy answered the question: I wrote it in my previous post, so I must use again that wonderful smiley:

    :read: carefully!!! :naughty: :naughty:

    Just joking.....
     
  7. DjFuzz

    DjFuzz What's a Dremel?

    Joined:
    9 Apr 2004
    Posts:
    45
    Likes Received:
    0
    :D yes im a noob i know! :D

    But that was the little part i did understand and papeniglio explained it really :thumb: but this command doesn't work for me: -bash setserial : command not found.
    and yes i've typed the whole line: setserial /dev/ttyS0 uart none. And i've installed lirc again and again. Anyone sugestions? :idea:
     
  8. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    Sorry, was very busy with my sons these days, so little posting...

    Dj, probably I was under the effect of some strange substance when I gave you that hint ( :blush: ), anyway here is the correct method:

    when you configure the kernel, you must compile the Standard/generic (8250/16650 and compatible UARTs) serial support as a module; then you load the lirc_serial module before the kernel serial module is loaded (or you can avoid to load the kernel serial module like I made)...

    Just to let you see what I've done, here is a portion of my rc.si script where I load the modules:

    Code:
    # setup modules
    depmod -a
    modprobe soundcore
    modprobe snd-maestro3
    modprobe snd-pcm-oss
    modprobe snd-mixer-oss
    modprobe snd-seq-oss
    modprobe lirc_serial


    I've finished the installation and configuration of Cajun: it's very nice! This night I'll take some pics of the LCD....
     
  9. DjFuzz

    DjFuzz What's a Dremel?

    Joined:
    9 Apr 2004
    Posts:
    45
    Likes Received:
    0
    Thanks :D Very happy with the help i'm getting!
    I shall try it as soon as i get home :D. Unfortunatly my SHARP IR device doesn't work for me :sigh: BUT i've orderd some other IR devices from conrad (see guide) so now i can build three of them:rock:.
    I'm very curious about the result of your LCD:Dwould like 2 get a lcd myself but theyre very expensive:sigh: where did you bought yours? and what did it cost? (srry if i missed that part).
    Keep us posted m8! :thumb: :thumb: :thumb: :thumb:
     
  10. Johnnyonetime

    Johnnyonetime What's a Dremel?

    Joined:
    10 Jan 2004
    Posts:
    32
    Likes Received:
    1
    papeniglio, I have one question for you. I can't find a way to get the sql file for cajun to fill my database with data. I set my root password for mysql and everytime I run the script (setup-database) I always get: "Cannot connect to .... root@localhost using password:NO). :duh: I compiled everything in slackware 9.1 and I'm very familiar with it, it's just mysql I'm not so great at. You have any idea on what command I could use to run that script? I checked the cajun mailing list and had no leads, hope you can help! Thanks.
     
  11. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    The setup-database script performs some basic operations on the mysql database before creating the cajun database; the detailed sequence is the following:

    - it forces the deleting of any existing cajun database

    - it creates an empty cajun database

    - it opens the mysql database and adds the cajunacct to the user table (this is the buggy line; se below)

    - it reloads the grant tables in order to enable the new user accoount

    - it opens the cajun database as cajunacct and invokes the setup-database.mysql script to set up the tables

    Unfortunately, the creation of the cajunacct user is faulty, resulting in the error you've reported. I've spent almost an afternoon trying to fix it, but the only way to make it work was to create manually the new user.

    Here is what I have done:

    enter the mysql shell by typing

    Code:
    mysql --user=root mysql
    Now create the new account

    Code:
    mysql> GRANT ALL PRIVILEGES ON *.* TO 'cajunacct'@'localhost'
        ->     IDENTIFIED BY 'cajunacct' WITH GRANT OPTION;
    this creates the cajunacct user with password cajunacct which has the root privileges.

    Now you can rerun the setup-database to set up the database.

    Edit: I'm using the stable release of MySQL (4.0)... Just for information.
     
  12. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    Sorry for the size of the picture, but I just want to post one picture of the web-Cajun in action:

    [​IMG]

    I'm configuring my Cajun from my work office through the web interface.... Very simple and fast...
     
  13. Johnnyonetime

    Johnnyonetime What's a Dremel?

    Joined:
    10 Jan 2004
    Posts:
    32
    Likes Received:
    1
    papeniglio, thanks for the heads up!

    I got it in mysql eventually. I ended cutting up the install script and doing it in a few pieces to get it completely installed.

    I'm working on the Perl modules now. If I can get everything working smoothly I might post a Slackware 9.1 Cajun HOW-TO to make it a little easier on the next guy.

    Gotta get the Apache configured and my Matrix Orbital LCD going... :worried:
     
  14. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    I've bought it from Modwarehouse for less than 30 Euros, but it seems they are having some troubles in these days... Anyway, there are other EU sites where you can buy LCDs from...
     
  15. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    Update Time!

    TIME FOR AN UPDATE

    Yes, after a long and painful night spent in making Cajun decode correctly my remote keystrokes, I've decided to draw back to IRMP3... :wallbash: :wallbash:

    The problem is that Cajun needs a lot of tweaking in order to get the remote keys decoded correctly, and after a couple of hours spent in the configuration I ended with some keys working and other not.... Moreover, it's very tricky to setup the right process sequence at boot time, the LCD output is not so nice, so I turned back on my steps...

    Fired up IRMP3 again and decided to let it be my jukebox app for now..

    I've taken some shots of the player in action, but it's very difficult because I use no flash and the letters on the LCD are scrolling...

    Here is the standby screen:

    [​IMG]


    Here is mpg321 running:

    [​IMG]


    Finally the volume control:

    [​IMG]


    I've assigned a function to all the remote keys and I'm able to mount/play/eject any CD/DVD.... Nice! :thumb:


    Up to now, I'm satisfied by the end result and I'll put this project on hold; I want to write a custom jukebox application mixing the positive aspects of Cajun and IRMP3, but now I have no more time....

    I must switch to my other modding project: ObiWan....

    [​IMG]

    Just a preview.... :naughty: :naughty: Will start a project log when I have more work done....

    Johnnyonetime let me know how you're going with your Cajun job..
     
  16. El_Angelo

    El_Angelo What's a Dremel?

    Joined:
    29 Oct 2003
    Posts:
    14
    Likes Received:
    0
    another nice european shops for lcd's is www.htvision.com
    one problem with it is that for the moment it is only available in dutch
    :idea:
     
  17. _ferry_

    _ferry_ What's a Dremel?

    Joined:
    22 Apr 2004
    Posts:
    333
    Likes Received:
    3
    Realy cool project :D I'm doing something witch is a bit similair, i received an p3 667mhz, yesterday installed linux, the next week i'm going to configure that and mount als an IR receiver and LCD to it. Don't know what i'm going to do whit the PC. Maybe giving it an casemod and yust use it for fun/learning linux. :hehe:

    My epia mobo was previous installed in a cd player:
    with IR receiver, and a LCD on the place where normally the time/track is shown.
    http://www.plokk.com/files/IMG_2242.jpg
     
  18. DjFuzz

    DjFuzz What's a Dremel?

    Joined:
    9 Apr 2004
    Posts:
    45
    Likes Received:
    0
    :eeek: I like that thing soow much! Wanne build something like that 2 when i've the money:D.
    papeniglio i'm sorry for all the questions, but here's another one: i've tried the stuff you've posted and it didn't work for me. I've re-compiled my kernel with support for uart etc. and compiled it as an module.
    Here are my settings

    Code:
    Rc.su:
    #!/bin/sh
    echo "-- /etc/rc.d/rc.su --"
    
    Code:
    Rc.si:
    #!/bin/sh
    
    echo "-- /etc/rc.d/rc.si --"
    
    # check and mount filesystems
    fsck -AaCs
    mount -nvwo remount /
    rm /etc/mtab
    mount -av
    
    # enable swap
    swapon -a
    
    # setup modules
    depmod -a
    # modprobe foo
    
    # setup hardware
    
    # setup network [internet connections go in rc.mu]
    hostname -CoReBoXz-
    ifconfig lo 127.0.0.1
    route add -net 127.0.0.0 netmask 255.0.0.0 lo
    
    # maintenance
    rm -r /tmp
    mkdir -m 1777 /tmp
    
    echo -n > /var/log/syslog
    echo -n > /var/log/wtmp
    echo -n > /var/run/utmp
    
    ldconfig
    
    Code:
    Rc.mu:
    #!/bin/sh
    
    echo "-- /etc/rc.d/rc.mu --"
    
    # start loggers
    syslogd -m 0
    sleep 1
    klogd
    
    # settings
    setterm -blank 5
    
    # setup network
    # ifconfig eth0 1.1.1.1 netmask 255.255.255.0
    # route add default gw 1.1.1.1
    
    # start daemons
    
    # Notes
    echo ""
    echo "********************************************" 
    echo "** Welcome! Please login 2 CoReBoXz below **"
    echo "********************************************"
    
    Code:
    Rc.ha:
    #!/bin/sh
    
    echo "-- /etc/rc.d/rc.ha $1 --"
    
    # kill everything
    killall5 -15
    sleep 1
    killall5 -9
    sleep 1
    
    # disable swap
    swapoff -a
    
    # unmount filesystems
    sync
    umount -av
    
    # halt/reboot
    $1 -f
    
    Code:
    modules.conf:
    alias char-major-61 lirc_driver
    options lirc_serial /dev/ttys0 uart none
    
    I'm sorry for the long post! Could you help me out with winlirc please?
    I get the following error: modprobe: can't locate module lirc_serial
    Thanks for the link El_Angelo! Think i'm going 2 buy my lcd overthere:D
    Thanks in advance!
     
  19. [t0rc]

    [t0rc] What's a Dremel?

    Joined:
    28 Nov 2003
    Posts:
    235
    Likes Received:
    0
    I like the progression of this project so far. keep it up. should have an interesting end. and good linux posting people. We need a tux smilie. . .
     
  20. papeniglio

    papeniglio Minimodder

    Joined:
    5 Dec 2002
    Posts:
    420
    Likes Received:
    0
    There are a couple of errors in your config files.....

    First of all, your rc.si file doesn't load any module, so that's why you get that error message! You should add a modprobe lirc_serial line after the depmod -a one. Thake a look at my rc.si script:

    Code:
    # setup modules
    depmod -a
    modprobe soundcore
    modprobe snd-maestro3
    modprobe snd-pcm-oss
    modprobe snd-mixer-oss
    modprobe snd-seq-oss
    modprobe lirc_serial
    Secondly, remove those lines from modules.conf.... They are useless.

    Hope it helps....
     

Share This Page