![]() |
#91 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 96
Karma: 100000
Join Date: Dec 2018
Location: London
Device: Kobo Libra H2O
|
|
![]() |
![]() |
![]() |
#92 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
The "stop parsing whatever comes next as getopt flags" marker (--), while good practice (especially after a "read from stdin" one), is unneeded here, as there isn't anything passed after it.
What did fix it is running it directly, preventing the pipe from being quoted, which effectively broke the pipeline, since there was no longer a pipeline ^^. |
![]() |
![]() |
![]() |
#93 | |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 96
Karma: 100000
Join Date: Dec 2018
Location: London
Device: Kobo Libra H2O
|
Quote:
Code:
echo "Try as per NiLuJe:" echo "" /mnt/us/extensions/sox/sox $1 -t raw - | /usr/bin/gst-launch -v filesrc location=/dev/stdin ! $caps ! queue ! mixersink Code:
(gst-launch-0.10:17914): GStreamer-CRITICAL **: gst_element_make_from_uri: assertion `gst_uri_is_valid (uri)' failed WARNING: erroneous pipeline: no element "audio" |
|
![]() |
![]() |
![]() |
#94 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
Thank you both for your assistance. Starting with your working script I made a few other minor tweaks and it appears to be working properly. I dropped the "-v" from gst-launch as I only wanted that to assist diagnosing where something failed and I added a trailing "&" to detach the pipeline and allow the script to exit. I also confirmed that I can use killall to stop it playing.
I am starting to work on a script to play an internet stream derived from this one. It requires use of curl to get a few seconds sample of the stream to derive the parameters for playback and the arguments to the script must identify the type of the stream as soxi won't guess it. Dave |
![]() |
![]() |
![]() |
#95 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@trcm:
$caps was still a multi-word quoted mess in that example ![]() (i.e., it's unrelated to the sox getopt stop, which was the only point I was trying to make ![]() |
![]() |
![]() |
![]() |
#96 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
I want to thank you both for your assistance with this project. I have reached the point where I have put together an initial KUAL menu, but I am having some issues with it that I don't understand. Perhaps you can assist me.
The menu is at present a top level menu and an internet radio sub-menu. The top level has an entry to play all music on the device, an entry to stop playback and an entry to the internet radio menu. These entries work, but the first two exit KUAL to the home directory for some reason. The internet radio sub-menu has some stations I play on occasion. These work and remain in the sub-menu in KUAL. Obviously I would prefer the top level menu choices to remain there and not exit KUAL to the home directory. I would also like to have the internet sub-radio menu entries return to the top level menu after use, as you need to be there to stop playback. Any suggestions appreciated. It would also be nice to know if this works on a USB audio Kindle. Dave |
![]() |
![]() |
![]() |
#97 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@dhdurgee: There's a typo in the toplevel exitmenu keys, you have an extra colon in there
![]() |
![]() |
![]() |
![]() |
#98 | |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
Quote:
If you have the time I would appreciate a look over the code to see if I have violated best practices in this environment. One thing I would like to add at some point would be a menu entry to open a file selection dialog to allow the user to browse and select a file to play. I have no idea how to do so in this environment. Another possibility would be an input box to accept either a filename or a URL that could be copied from elsewhere, assuming there is a way to copy such for later pasting. Dave |
|
![]() |
![]() |
![]() |
#99 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
Is there an option in the KUAL menu to return from a sub-menu to the main menu after an option is selected? I would like to do so for the internet radio choices, as the stop playing media is in the top menu.
Dave |
![]() |
![]() |
![]() |
#100 | |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Quote:
![]() That would be a no, too. |
|
![]() |
![]() |
![]() |
#101 | |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
Quote:
Oh well, guess I will add another "Stop playing media" to the sub-menu instead. Thanks again for your assistance. Do you think this is ready for a wider audience, or is there more I should do first? Dave |
|
![]() |
![]() |
![]() |
#102 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
|
![]() |
![]() |
![]() |
#103 |
Guru
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 914
Karma: 3000002
Join Date: Jun 2010
Device: K3W, PW4
|
|
![]() |
![]() |
![]() |
#104 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
KUAL was not really made to be extensible on the Java side, but, on FW 5.x (and only there), it technically has access to the standard Java UI kit, IIRC. You'd have to come up with the Java frontend *and* how to make that interact with the awk backend, though. That'd be extremely non-trivial.
The only somewhat usable toolkit available on stock devices is gtk2, c.f., kterm & co. Otherwise, you can do it all by hand with a custom input loop and custom drawing primitives and FBInk ;D. That still won't solve the lack of integration/interaction with KUAL, though. TL;DR: No. The best you can do is building "dynamic" menus (c.f., the K5 Fonts hack and its font override extension). Last edited by NiLuJe; 05-02-2020 at 05:17 PM. |
![]() |
![]() |
![]() |
#105 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,814
Karma: 103362673
Join Date: Apr 2011
Device: pb360
|
Quote:
If you had uploaded the sox directory and all its contents, made a commit, and tagged that commit as something like v0.1 github would consider that commit a release. (github uses some heuristic to decide whether a tag name is a release.) Interested people can download any release as a zip or tar.gz at their choice without having to clone the repository. If you make a change to playfile.sh in the git working tree on your computer and have tested it and are ready to release, it can be as simple as: Code:
git commit -a git tag v0.2 git push git push --tags Boom. You just made a new release and didn't have to zip anything up, clean up your working tree, only uploaded changes to a file, and didn't have to muck around in a web browser getting the file to the correct place. And collaborators can do a git pull and only sox/playfile.sh and their repository clone change on their systems, and they can easily see what the changes were. To reiterate, github automatically packages up up releases and releases are published by simply appropriately tagging a commit. |
|
![]() |
![]() |
![]() |
Tags |
audiobook, bluetooth, jailbreak, m4b, mp3 |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Issue with finding audiobook metadata on Amazon | angelyne | Calibre | 6 | 10-21-2018 08:52 AM |
Listen Audiobook Player question | Hrafn | Audiobook Hardware & Software | 0 | 06-16-2018 02:36 AM |
Listen Up - We've got a brand new audiobook forum | Alexander Turcic | Announcements | 11 | 09-10-2014 06:18 PM |
Amazon Ebooks and downloaded Audiobook | ErikaGC | Kindle Fire | 1 | 06-10-2013 12:13 PM |
Sony & Amazon, etc. - Why No Wifi or Bluetooth? | poohbear_nc | News | 8 | 08-26-2009 04:29 PM |