Page 1 of 3 123 LastLast
Results 1 to 10 of 29

Thread: Need to convert PDF to Audio MP3

  1. #1
    Join Date
    Jul 2005
    Location
    Remote Desert, USA
    Beans
    683

    Need to convert PDF to Audio MP3

    My wife wants me to come up with a Linux script or program that can convert a PDF file into an audio MP3 that she can study while in her car or while working out.

    Anyone got a Perl, Bash, or other script that can do this?
    SuperMike
    When in doubt, follow the penguins.
    Evil Kitty is watching you

  2. #2
    Join Date
    Jun 2006
    Location
    UnderTheSea
    Beans
    265

    Re: Need to convert PDF to Audio MP3

    festival or gspeaker
    So She Said Internet, And I Said Inter-Not



  3. #3
    Join Date
    Jan 2010
    Beans
    10

    Re: Need to convert PDF to Audio MP3

    hi, had the same problem, in the attachement is the file called pdf2mp3.py which does the conversion of a pdf or text/ascii file into a mp3 audio file.

    i wanted to hear work-related publications while making sport during lunch brake. as there's only lot's of stupid commercial stuff in the web, i just wrote my own python-script/program that converts a pdf-file (or ascii/text-file) into an mp3 file. it should be very easy to make it work on a running ubuntu distribution
    or other linux system, you just need to install the following packages:

    Code:
     sudo apt-get install python poppler-utils festival festvox-rablpc16k lame
    then you have to use the attached file called pdf2mp3.py and make it an executable via:

    Code:
    chmod +x pdf2mp3.py
    and to be able to run that little program 'system-wide':
    Code:
    sudo cp pdf2mp3.py /usr/bin/
    then you only have to call the script in your shell via:
    Code:
    pdf2mp3.py yourfilename.pdf
    or via:
    Code:
    pdf2mp3.py yourfilename.txt
    or via:
    Code:
    pdf2mp3.py yourfilename.dat
    and an mp3 is being created!

    PS: it is the english voice now. other voices can be downloaded here: http://cslu.cse.ogi.edu/tts/download/
    Attached Files Attached Files
    Last edited by rennau80; January 8th, 2010 at 03:21 PM.

  4. #4
    Join Date
    Dec 2008
    Beans
    5

    Re: Need to convert PDF to Audio MP3

    i am having a problem........


    it says.....


    chmod: cannot access `pdf2mp3.py': No such file or directory

    please advise..........

    on following commands terminal shows...............



    nahar@nahar-desktop:~$ sudo apt-get install python poppler-utils festival festvox-rablpc16k lame (command 1)
    [sudo] password for nahar:
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    python is already the newest version.
    poppler-utils is already the newest version.
    festival is already the newest version.
    festvox-rablpc16k is already the newest version.
    lame is already the newest version.
    The following packages were automatically installed and are no longer required:
    linux-headers-2.6.31-14 libnss3-dev libfltk1.1 libnspr4-dev
    linux-headers-2.6.31-14-generic
    Use 'apt-get autoremove' to remove them.
    0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
    nahar@nahar-desktop:~$ chmod +x pdf2mp3.py (command 2)problem starts here
    chmod: cannot access `pdf2mp3.py': No such file or directory
    nahar@nahar-desktop:~$
    Last edited by aiiaalla; January 9th, 2010 at 11:19 AM.

  5. #5
    Join Date
    Jan 2010
    Beans
    10

    Re: Need to convert PDF to Audio MP3

    seems that you downloaded the file pdf2mp3.py to a different folder. if you do a

    Code:
    ls pdf2mp3.py
    it should list the file (i think that for your case it is simply not in your path). otherwise you need to know to which directory you've downloaded the file and do the chmod-command there.

  6. #6
    Join Date
    Dec 2008
    Beans
    5

    Re: Need to convert PDF to Audio MP3

    nahar@nahar-desktop:~$ ls pdf2mp3.py
    ls: cannot access pdf2mp3.py: No such file or directory
    nahar@nahar-desktop:~$

    the file is on the desktop........

  7. #7
    Join Date
    Jan 2010
    Beans
    10

    Re: Need to convert PDF to Audio MP3

    then you have to go to the desktop first via:
    Code:
    cd Desktop
    should work. then do the chmod.

  8. #8
    Join Date
    Jun 2006
    Location
    Atlanta
    Beans
    356
    Distro
    Ubuntu

    Re: Need to convert PDF to Audio MP3

    The file needs to be executable, even if it is in your current directory.
    Intel Core i7-2600K | Corsair Hydro H80 Cooler | ASUS P8Z68-V board | Corsair Obsidian 650 case | CORSAIR Pro HX650 | CORSAIR Vengeance 8GB DDR3-1866 | GIGABYTE Radeon HD 6870 1GB | Intel 510 120GB SSD | WD Green 640GB | Dell Ultrasharp U2713HM LED

  9. #9
    Join Date
    Dec 2008
    Beans
    5

    Re: Need to convert PDF to Audio MP3

    Hey it worked.
    Thanks a lot
    how do I get a different voice?
    Last edited by aiiaalla; January 11th, 2010 at 02:43 PM.

  10. #10
    Join Date
    Dec 2008
    Beans
    5

    Re: Need to convert PDF to Audio MP3

    i downloaded 3 voice packages off the link supplied ....
    how do i install them?

Page 1 of 3 123 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •