After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 325602 - Add support for mass storage audio players
Add support for mass storage audio players
Status: RESOLVED FIXED
Product: rhythmbox
Classification: Other
Component: general
HEAD
Other Linux
: Normal normal
: ---
Assigned To: RhythmBox Maintainers
RhythmBox Maintainers
: 325601 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-01-03 10:27 UTC by James "Doc" Livingston
Modified: 2006-01-16 13:45 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (13.53 KB, patch)
2006-01-03 10:30 UTC, James "Doc" Livingston
none Details | Review
tarball (2.83 KB, application/x-bzip)
2006-01-03 10:30 UTC, James "Doc" Livingston
  Details
fixed patch (13.73 KB, patch)
2006-01-03 12:23 UTC, James "Doc" Livingston
none Details | Review
updated tarball (2.91 KB, application/x-bzip)
2006-01-04 01:07 UTC, James "Doc" Livingston
  Details
updated patch (8.86 KB, patch)
2006-01-05 10:21 UTC, James "Doc" Livingston
none Details | Review
updated tarball (3.01 KB, application/x-bzip)
2006-01-07 03:21 UTC, James "Doc" Livingston
  Details
updated patch (15.42 KB, patch)
2006-01-07 03:23 UTC, James "Doc" Livingston
none Details | Review
newer patch (16.08 KB, patch)
2006-01-08 05:04 UTC, James "Doc" Livingston
none Details | Review
updated patch (16.77 KB, patch)
2006-01-15 06:15 UTC, James "Doc" Livingston
committed Details | Review
updated tarball (3.04 KB, application/x-bzip)
2006-01-15 06:16 UTC, James "Doc" Livingston
  Details

Description James "Doc" Livingston 2006-01-03 10:27:41 UTC
It would be nice to support audio players other than iPods as well. Bug 149716 is for iRiver support, this one is for generic mass-storage players.
Comment 1 James "Doc" Livingston 2006-01-03 10:30:08 UTC
Created attachment 56702 [details] [review]
patch

Patch to add support for mass-storage players
Comment 2 James "Doc" Livingston 2006-01-03 10:30:18 UTC
*** Bug 325601 has been marked as a duplicate of this bug. ***
Comment 3 James "Doc" Livingston 2006-01-03 10:30:45 UTC
Created attachment 56704 [details]
tarball

New files
Comment 4 Johan Lund 2006-01-03 11:32:48 UTC
Compilation failure against a clean cvs co.
rb-audiocd-source.c: In function 'rb_audiocd_source_new':
rb-audiocd-source.c:164: warning: 'device_path' is used uninitialized in this function
Comment 5 James "Doc" Livingston 2006-01-03 12:23:33 UTC
Created attachment 56711 [details] [review]
fixed patch

Oops. I wonder why I didn't get that here.
Comment 6 Johan Lund 2006-01-03 21:37:50 UTC
Hi,

Tried with a small, quite cheap, MP3-player named INO 3(I). This player is not recognised by RB. It's a HAL issue beqause the device hasn't the capabilities of portable_audio_player, only storage and block.

/J
Comment 7 James "Doc" Livingston 2006-01-04 01:04:50 UTC
I know Aaron Bock (Banshee's maintainer) was getting people to send in the data on players, so that the FDI files could be updated.

If you wanted you could probably add your own entry to the file (which is /usr/share/hal/fdi/information/10freedesktop/10-usb-music-players.fdi on my machine). Most "generic" players will have the entry inside the <match key="@storage.physical_device:info.bus" string="usb"> section; you could probably copy one of the existing ones and change the vendor and product ids (which you can get from hal-device-manager)
Comment 8 James "Doc" Livingston 2006-01-04 01:07:22 UTC
Created attachment 56748 [details]
updated tarball

A few minor fixes. It now walks up the device tree looking for something with the portable_audio_player capability, which will work if the mass-storage volume is nto a direct child of the player.
Comment 9 James "Doc" Livingston 2006-01-05 10:21:19 UTC
Created attachment 56807 [details] [review]
updated patch

Fixes a compilation issue, and allows the disabling of HAL usage. The generic player source is added without HAL support, but won't actually do anything as RB can't detect players; this is because we may want to add other methods for detection.

Having some method of manually marking a device/volume as "interesting" would be handy, to support players that HAL doesn't (yet) know about or volumes that aren't actually players (e.g. flash cards). Jonathan suggested on IRC that the presence of a hidden file in the root of the volume would be a possible method to mark this.
Comment 10 James "Doc" Livingston 2006-01-07 03:21:48 UTC
Created attachment 56901 [details]
updated tarball

This fixes a few issues, and also add support for using devices not recognised by HAL. You can make Rhythmbox treat any volume as a "generic audio player" but putting a file called ".is_audio_player" in the root directory of the volume.
Comment 11 James "Doc" Livingston 2006-01-07 03:23:51 UTC
Created attachment 56902 [details] [review]
updated patch
Comment 12 Jonathan Matthew 2006-01-07 05:18:28 UTC
The latest patch works for me (using the tag file and my generic flash card device), but I get the following message twice when I plug it in:

20720: arguments to dbus_move_error() were incorrect, assertion "(dest) == NULL || !dbus_error_is_set ((dest))" failed in file dbus-errors.c line 243.
This is normally a bug in some application using the D-BUS library.

and this when I right-click on it in the source list:

(rhythmbox:20720): Gtk-CRITICAL **: gtk_menu_popup: assertion `GTK_IS_MENU (menu)' failed
Comment 13 James "Doc" Livingston 2006-01-08 05:04:04 UTC
Created attachment 56952 [details] [review]
newer patch

This fixes the menu issue. It currently segfaults if the player is removed while we are loading tracks:

  • #0 _gtk_container_queue_resize
    at gtkcontainer.c line 1085
  • #1 real_queue_resize
    at gtksizegroup.c line 143
  • #2 queue_resize_on_widget
    at gtksizegroup.c line 187
  • #3 IA__gtk_widget_queue_resize
    at gtkwidget.c line 2608
  • #4 gtk_tree_view_row_inserted
    at gtktreeview.c line 7358
  • #5 _gtk_marshal_VOID__BOXED_BOXED
    at gtkmarshalers.c line 1146
  • #6 IA__g_closure_invoke
    at gclosure.c line 490
  • #7 signal_emit_unlocked_R
    at gsignal.c line 2438
  • #8 IA__g_signal_emit_valist
    at gsignal.c line 2197
  • #9 IA__g_signal_emit
    at gsignal.c line 2241
  • #10 IA__gtk_tree_model_row_inserted
    at gtktreemodel.c line 1431
  • #11 rhythmdb_query_model_do_insert
    at rhythmdb-query-model.c line 1007
  • #12 rhythmdb_query_model_entry_added_cb
    at rhythmdb-query-model.c line 578
  • #13 IA__g_cclosure_marshal_VOID__POINTER
    at gmarshal.c line 601
  • #14 IA__g_closure_invoke
    at gclosure.c line 490
  • #15 signal_emit_unlocked_R
    at gsignal.c line 2438
  • #16 IA__g_signal_emit_valist
    at gsignal.c line 2197
  • #17 IA__g_signal_emit
    at gsignal.c line 2241
  • #18 rhythmdb_emit_entry_added
    at rhythmdb.c line 3453
  • #19 rhythmdb_commit_internal
    at rhythmdb.c line 840
  • #20 rhythmdb_process_metadata_load
    at rhythmdb.c line 1570
  • #21 rhythmdb_process_events
    at rhythmdb.c line 1651
  • #22 rhythmdb_idle_poll_events
    at rhythmdb.c line 1718
  • #23 g_timeout_dispatch
    at gmain.c line 3292
  • #24 IA__g_main_context_dispatch
    at gmain.c line 1916
  • #25 g_main_context_iterate
    at gmain.c line 2547
  • #26 IA__g_main_loop_run
    at gmain.c line 2751
  • #27 bonobo_main
    from /usr/lib/libbonobo-2.so.0
  • #28 main
    at main.c line 398

Comment 14 James "Doc" Livingston 2006-01-15 06:15:51 UTC
Created attachment 57386 [details] [review]
updated patch

This version fixes the dbus issue from comment 12. The problem I mentioned in comment 13 seems to have disappeared too.
Comment 15 James "Doc" Livingston 2006-01-15 06:16:35 UTC
Created attachment 57387 [details]
updated tarball
Comment 16 Jonathan Matthew 2006-01-16 10:57:38 UTC
Also works with my shiny new iriver t30 (usb mass storage version) after I added a few rules to a .fdi file for it.
Comment 17 James "Doc" Livingston 2006-01-16 13:45:58 UTC
Committed to cvs.