
iriverh10.amarokscript
Source (link to git-repo or to original if based on someone elses unmodified work):
About
iriverh10 is an amarokscript to manage the iRiver H-series digital audio player in USB mass storage mode (UMS mode as opposed to MTP-mode) from within amaroK.
The script is build around easyh10 and easypmp. These are commandline utilities to generate the media database and playlist for the iRiver H-series digital audio player.
All actions on the device, that changes the content, make reconstructing the database necessary. This is done with easyh10 or easypmp. The media database is reconstructed from the music files and the playlist files converted into PLP/PLA playlist files, which are recognized by the H10 player.
Transferring MP3/WMA/WAV files into the music directory and creating M3U/M3U8/PLS playlist files under the playlist directory must be done manually in advance. This is where amaroK comes in place.
Dependencies
amaroK 1.3 or better.
EasyH10 [CUI]
or
EasyPMP [POSIX] (pmplib)
Thanks to
Credits should go to Mike Diehl and Kevin R. Bulgrien, who wrote the amarokscripts transfer_to_media_device and usb_device respectively. They gave me the idea for this script. But not after that I came across the program I really was looking for: easyh10. Without this program the writing of this script would be of no use. easyh10 and easypmp are programs by Nyaochi. Visit http://easyh10.sourceforge.net or http://pmplib.sourceforge.net for more information.
0.9.6 2007-02-11
- A rewrite of the Delete function. It is working now on a file by file basis, handling the delete from the device and the removal from the playlist at the same time. The process is better controlled right now. Also changed the progressbar to indicate the whole of the process instead of only the syncing.
- Added a progressbar to the Reconstruct function.
- Added a progressbar and partly rewrote the Synchronize function.
0.9.5 2007-01-05
- Made Size available without a connected device and rendered a change in the way it reports.
- Bugfix in updating the playlist after a delete.
- Reconstruct the amaroK-based playlist from the device's contents.
- Synchronize files from the playlist to the device, as an alternative for Transfer.
0.9.4 2007-01-03
- The statusreport as given with the option Size is now displayed as a popup message for various relevant options.
- After deleting tracks from the device the playlist was cleared. This was annoying and therefore removed.
- After deleting tracks from the device the corresponding entries in the playlist are removed as well. This solves an earlier problem in the To Do's.
0.9.3 2006-09-05
-Some rearranging of the code.
-Improving dialogs.
-After purging the device the statusinformation wasn't updated. Corrected.
-Updating the media-databases on the device after a Transfer, Delete and Purge has been made dependent on a configuration-setting.
-To be able to handle the H10jr. easypmp is introduced. See Dependencies above.
-Corrected PlsCreate... to not only make use of the devices tracklist, but essentially every playlist in the playlistwindow.
0.9.2 2006-03-25
-Create playlist PlsCreate and delete playlist PlsDelete. Instead of using the M3U-playlistfunction of amaroK, wich proved to be rather difficult, I choose creating a pls-file in the device's playlistdrectory.
-In case of Transfer and PlsCreate, check if the selected tracks in the active playlist have the right origin: the collection or the device respectively.
-Devicetrapping was still a bit buggy.
0.9.1 2006-03-12
-Introduction of progressbars for Transfer and Delete
-Rewrite of the devicetrapping routine.
0.9.0 2006-03-05
Initial release
Ratings & Comments
9 Comments
Great script! Now I have another reason to get rid of Windoze :) I was wondering if it would be possible for you to modify the script a teensy bit? I couldn't figure out which bit I needed to alter - I would like to learn how to write scripts properly, but sadly it'll be a while before I have time to do that... I'm constantly tweaking my playlists, but the update option doesn't cover this, so would you be able to add something? The command I generally use is: easyh10 -U -on -Pf /media/H10/
Open the script with a texteditor (kate or kwrite) and find the line: ${Whicheasy} --update ${order} \ --playlist --reconvert --skip-missing ${H10dir} 2>/dev/null & It will be at or around linenumber 1226/1227. Change --reconvert --skip-missing in --find-missing Save the script, and you are ready to run. Hope this helps. Caspar.
Thanks for replying, but it doesn't seem to have made a difference - .m3u playlists still aren't converting to .pla. Also, under the 'devices' tab, the playlist folder expands but doesn't show the files within, and other main folders which have been deleted are still visible. I don't know if this is affecting the conversion, or even whether this is a bug with the script or amarok.
Try this line on the commandline: easyh10 --update --order=tracknumber --playlist --find-missing /media/H10/ If the output is to your satisfaction then I really don't know what is going on. Because this is exactly what the script does after the changes I advised you to make. If the output is not what you would expect, then I cannot help you either. In that case I suspect something is going on with your playlist setup. I don't use playlists myself, so I really don't know which is the best strategy to adopt. Caspar.
Is this a script for the new media player sync feature in Amarok 1.4beta2+? If it is please provide a script for the iAudio X5(L). Or give me a link to a tutorial on where to create one. I can give you any information you need to create one.
> CptnObvious999 has posted a new comment for the > content 'iriverh10.amarokscript' on KDE-Apps.org > > -- > iAudio X5 > Is this a script for the new media player sync I started the script when using 1.3.8 myself. In the meantime it is upgraded to 1.4-beta1. > feature in Amarok 1.4beta2+? If it is please So no, not specifically written for the new 1.4-feature. I suppose you mean the upgrade from the iPod-browser to a more general approach. I don't see through that option myself yet. First experiments didn't bring me any further than I already was with Konqueror. So no reason for me to leave my efforts yet. > provide a script for the iAudio X5(L). Or give me > a link to a tutorial on where to create one. I can > give you any information you need to create one. I don't know the X5. But dig in the script. I tried my best to document it. Furthermore have a look at these links: http://amarok.kde.org/amarokwiki/index.php/Script-Writing_HowTo http://developer.kde.org/documentation/tutorials/kdialog/t1.html http://www.volny.cz/bwian/dcop.html -- Caspar
Ok thanks for the info. I will see what I can do.
Ok nevermind the iAudio X5L is supported as a UMS device I was just getting weird errors, its fixed now.
Good to hear that things are working for you. -- Caspar.