HydrogenAudio

Hosted Forums => foobar2000 => foobar2000 mobile => Topic started by: tinpanalley on 2019-04-07 18:02:32

Title: Foobar app (Android) accessing SMB shares?
Post by: tinpanalley on 2019-04-07 18:02:32
I have several folders for video and audio on SMB share from Windows and use that to access the music from my laptop right now. But I'd like to re-purpose an old Android tablet that isn't getting any use as a touch screen GUI music player instead by my stereo. Does Foobar on Android give the ability to access SMB shares or should I use another app?
Thanks!
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: kode54 on 2019-04-08 01:03:31
Try this (https://play.google.com/store/apps/details?id=com.google.android.sambadocumentsprovider)?
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: tinpanalley on 2019-04-08 01:40:19
Try this (https://play.google.com/store/apps/details?id=com.google.android.sambadocumentsprovider)?
For some reason that link doesn't work for me. What's the app called?
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: kode54 on 2019-04-09 01:13:56
com.google.android.sambadocumentsprovider

Google Android Samba Client
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-04-29 09:55:32
com.google.android.sambadocumentsprovider

Google Android Samba Client
I was looking into this due to a showstopper issue using FTP (https://hydrogenaud.io/index.php?topic=122423.0).
The Samba package can still be found on F-Droid (https://f-droid.org/de/packages/com.google.android.sambadocumentsprovider/) and it still works on Android 12, however while other apps can make use of it, foobar2000 complains that it's not a regular folder it can work with.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: Peter on 2022-04-29 10:54:47
FTP throttling is problematic to implement, sorry.

I'll investigate why Google Android Samba Client doesn't work, thanks for reporting.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-04-29 11:01:38
FTP throttling is problematic to implement, sorry.
No need to throttle the bandwidth, you'd just need to limit the max. concurrent FTP connections.
Not sure what you're using to connect, but if it's rclone it can be easily configured (see the link in my previous post).

Edit: Further investigation revealed similar reports for this problem on foobar-users.de (https://foobar-users.de/index.php?topic=5138.0).
The router hardware I'm using has a 50% market share in Germany, so chances are high that a few users more have or will run into this issue, since they all run the same FTP/DDoS config.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: kode54 on 2022-04-30 00:27:41
It's not rclone. It's a 100% novel implementation.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-04-30 08:18:09
It's not rclone. It's a 100% novel implementation.
Ah, OK - I was under the impression that rclone is used, since the beta changelog (https://www.foobar2000.org/changelog-android) mentions "Media Library can now index folders shared with rclone over HTTP.".

I'll investigate why Google Android Samba Client doesn't work, thanks for reporting.
There's also CIFS Documents Provider (https://f-droid.org/de/packages/com.wa2c.android.cifsdocumentsprovider/), which still seems to be actively maintained.
It also comes with a MIT license which might allow integration at some point (I'm no licensing expert).

Yesterday I was so desperate to get the indexing done via FTP, that I tried the following:
- downgrading my WiFi to the slowest possible
- saturating the bandwidth by running a large download on a second device
- started scanning process in foobar2000

I managed to double the indexation that way, but I'm still left with about 80% unindexed music.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: kode54 on 2022-04-30 10:03:14
Maybe I was wrong. I don't know. I don't keep track of this any more.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: Peter on 2022-05-06 09:48:27
I did some research and interop with above linked SMB & CIFS services isn't easy enough to add either. The SMB one partially worked but refused to seek (files were opened as nonseekable pipes).

I personally recommend using UPnP for sharing music on local network, it solves the problem of music indexing & hammering the server (tags indexed by the server itself).

I'll have a closer look at FTP behaviors before the next update, what you describe is obviously unacceptable.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-05-06 10:34:16
I personally recommend using UPnP for sharing music on local network, it solves the problem of music indexing & hammering the server (tags indexed by the server itself).
Unfortunately I'd loose album cover indexing that way, since in my case they're stored as separate JPG files.
Your FTP scanning method finds them.

I'll have a closer look at FTP behaviors before the next update, what you describe is obviously unacceptable.
Thank you very much for your efforts, would be great if this could be solved by a user defineable connection limit .
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-05-12 23:04:08
Some testing on the NAS function of my router revealed a limit of 20 FTP connections.

Just to be sure: the app does close or re-use the FTP connections?

Edit: I just came across this code (https://github.com/honwhy/commons-pool-ftp/blob/ftpcp/src/main/java/com/honey/ftp/AbstractDownloadDirectoryCallback.java) utilizing java.util.concurrent to pool the FTP connections.
Maybe some food for thought. ;-)
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: kode54 on 2022-05-12 23:59:32
That would only be helpful for the Android version, not the iOS version. Also, most of the app is native code compiled as a large object, the Java portion is mostly only glue code to make it work.
Title: Re: Foobar app (Android) accessing SMB shares?
Post by: pyr452 on 2022-06-15 08:08:33
I'll have a closer look at FTP behaviors before the next update, what you describe is obviously unacceptable.
Not sure if you took notice of this thread (https://hydrogenaud.io/index.php/topic,122427.0.html) as well.
It's not exactly related but when you find the time to dive into this FTP issue the other one might just be an easy fix along the way.