Announcement

Collapse
No announcement yet.

piCorePlayer --- switch $LANG to UTF8

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    piCorePlayer --- switch $LANG to UTF8

    Hi All,

    got my picoreplayer installed on Raspberry Pi3+, playing music from /mnt/music, which is a ext4 filesystem, and largely works.

    But:
    as soon as i import records with accents (`'^) in the filename, they turn up in the file system with ?? in the name instead of accents. Example: "Estampes II. La soirée dans Grenade.m4a" turns up as "Estampes II. La soir??e dans Grenade", "10 Children’s Corner II. Jimbo’s Lullaby.m4a" turns up as "Children???s Corner II. Jimbo???s Lullaby.m4a". Guess this will turn out true for danish, spanish, etc. titles, but haven't tried that yet. (Just seeing in the Preview that the board isn't happy with accents either. Sorry about that, but take my word, that the titles mentioned acually contain proper syntax ;-) )

    So, i tried extending cmdline.txt with either LANG=de.DE_UTF8, de._DE_UTF8/UTF8, en.EN_UTF8, en.EN_UTF8/UTF8, us.US_UTF8 and us.US_UTF8/UTF8, wich are all in /usr/local/share/getlocale/SUPPORTED.

    I tried employing getlocale.sh, which, run as "sudo getlocale.sh", doesn't seem to do anything, because the output is empty instead of "Now processing ... locale installed ...etc".

    I know that changing the locale does not work witch DOS filesystems, but should work with libux filesystems (did that before with my linuxes).

    Has anyone tried changing the locale before? How did you do that? Does anyone know how to get getlocale.sh to work? Are you playing "french titles" on piCore? How do you do that without the player complaining about broken paths?

    Looking forward to your answers, perhaps some help.

    Best Regards
    Matthias

    #2
    when you run getlocale.sh it creates an extension called mylocale.tcz

    You need to both specify LANG=xxxx on the command line and also make sure that mylocale.tcz is in onboot.lst.
    piCorePlayer a small player for the Raspberry Pi in RAM.
    Homepage: https://www.picoreplayer.org

    Please donate if you like the piCorePlayer

    Comment


      #3
      Hi Paul,

      thanks for your answer...

      Creation of mylocale.tcz was my expectation, but getlocale.sh doesn't do this for me. If you have done that to your picoreplayer: did you set $LANG before running "sudo getlocale.sh (as i did)? Did the script actually answer with "Now processing..." and ask for the desired locale? Where did you get getlocale.sh? Did you install the esxtension getlocale.tcz as i did, or did you download it from somewhere else?

      Regards
      Matthias

      Comment


        #4
        It will prompt you before it processes. I've done it a while ago, but only en.UTF8
        piCorePlayer a small player for the Raspberry Pi in RAM.
        Homepage: https://www.picoreplayer.org

        Please donate if you like the piCorePlayer

        Comment


          #5
          piCorePlayer --- switch $LANG to UTF8

          ...thanks Paul,

          so there is something wrong with getlocale.sh.

          Has anyone any idea, how to get past this?

          Thanks
          Matthias

          Comment


            #6
            I’ll take a look, but it should not matter for LMS.

            What is the file system type where your music is stored?
            piCorePlayer a small player for the Raspberry Pi in RAM.
            Homepage: https://www.picoreplayer.org

            Please donate if you like the piCorePlayer

            Comment


              #7
              getlocale.sh works just fine for me. Are you sure you didn't run out of disk space when trying to add extensions?
              piCorePlayer a small player for the Raspberry Pi in RAM.
              Homepage: https://www.picoreplayer.org

              Please donate if you like the piCorePlayer

              Comment


                #8
                ... thanks Paul!

                Apparently it DOES matter to LMS, since it doesn't find the file with the accents in it ;-)

                Anyway, i got it fixed...

                The problem is the command "dialog --file $temp2 2> $tempfile" in getlocale.sh, which throws an error "Error opening terminal: xterm-256color." into $tempfile.

                So,
                - i copied getlocale.sh into $HOME
                - inserted an "export TERM=xterm" after SFILE=...
                - did sudo ./getlocale.sh
                - chose my locales de_DE, en_GB and en_US
                - let getlocale.sh do it's work.
                - appended LANG=de_DE.UTF8 to cmdline.txt
                - inserted export LANG... into .profile and ..bashrc (i like bash better than sh ;-) )
                - saved changes via pcoreplayer's homepage
                - rebooted

                Problem solved! Do you know how to hand this onward to the picore people? I think it may come handy to them, saving other people some headache...

                Thanks for your help and have a god weekend!
                Stay happy, healthy and get rich!
                Regards
                Matthias

                Comment


                  #9
                  Can't find getlocale.tcz in repositories

                  I recently installed piCorePlayer v5.0.0 on a Raspberry Pi 3B+ and I have the same issue with accented characters in names.
                  But I can't find the getlocale.tcz extension in either the piCorePlayer repository or the Official piCore repository.
                  Is it available from another repository?
                  Thanks!

                  Comment


                    #10
                    Originally posted by bisto View Post
                    I recently installed piCorePlayer v5.0.0 on a Raspberry Pi 3B+ and I have the same issue with accented characters in names.
                    But I can't find the getlocale.tcz extension in either the piCorePlayer repository or the Official piCore repository.
                    Is it available from another repository?
                    Thanks!
                    I'll have to add it.
                    piCorePlayer a small player for the Raspberry Pi in RAM.
                    Homepage: https://www.picoreplayer.org

                    Please donate if you like the piCorePlayer

                    Comment


                      #11
                      There are some other incompatibilities with this script.....ncurses is just being a pain lately. I may change to whiptail

                      In any event, I have a little work to do before I can upload it.
                      piCorePlayer a small player for the Raspberry Pi in RAM.
                      Homepage: https://www.picoreplayer.org

                      Please donate if you like the piCorePlayer

                      Comment


                        #12
                        Alright, getlocale.tcz is up and should be working. also fixed an issue with glibc locales. Let me know.

                        If you already have downloaded getlocale, you can do an update by running

                        pcp-update getlocale.tcz

                        and then rebooting
                        piCorePlayer a small player for the Raspberry Pi in RAM.
                        Homepage: https://www.picoreplayer.org

                        Please donate if you like the piCorePlayer

                        Comment


                          #13
                          I updated my copy of getlocale.tcz as you indicated.
                          getlocale.sh works properly now and I was able to successfully set the locale to en_US.UTF-8.
                          Thank you very much!

                          Comment


                            #14
                            Hi,

                            I just installed getlocale.sh from extension page.
                            Launch it, install fr_FR.UTF-8/UTF8
                            Add fr_FR.UTF-8 in boot code page in LANG= field
                            Save and Reboot.

                            But i'm not able to rename file with accent like "é" or "ï" they are replaced by ?

                            How to deal with this please ?

                            EDIT : switching my HDD from fat32 to ext4 format solved the problem.
                            Last edited by a491765; 2020-02-20, 22:09.

                            Comment


                              #15
                              piCorePlayer 6 --- switch $LANG to UTF8

                              Hi All,

                              had to reinstall picoreplayer and switched to version 6.1.0. I'm trying to set $LANG to de_DE.UTF-8/UTF-8 using getlocale.sh and appending LANG=de_DE.UTF-8/UTF-8 to cmdline.txt, neither works.

                              Can anyone help, please?

                              Best Regards
                              Matti

                              Comment

                              Working...
                              X