Old 10th April 2012, 10:10   #1
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
Getting SAM Broadcaster to work with sc_trans

Hi,

I have running a station with multiple DJs running SAM. I'm running the latest builds of sc_serv and sc_trans with mp3 enabled, using winamp as a "jukebox" when there are no DJs connected. That part works great!

However, I cannot get SAM to connect to sc_trans. It connects directly to the server instance fine. But no matter v1 or v2, it just will not connect to the transcoder.

The problem may be that SAM doesn't have a Username field for either v1 or v2 mode, only the password field. I can connect great with Winamp and the DSP plugin, just not SAM.

The error I get on sc_trans is: Connection denied to 'encoder'

Which makes me wonder if it sees the username as encoder, so I tried making that the username in sc_trans config , but no luck.

So, has anyone gotten SAM (version 4.9.0) to connect as a DJ source to sc_trans??

Thanks,
Steve
thewoose is offline   Reply With Quote
Old 10th April 2012, 11:36   #2
DrO
 
Join Date: Sep 2003
Posts: 27,873
most likely you will need to enter the password as <dj_name>:<dj_password> and set SAM to work in v1 mode. where dj_name is taken from djlogin and dj_password is taken from djpassword in the config file.

this keeps cropping up from people wanting to use SAM so you'd be best showing there is interest for the 'dj / user id' support and contact spacial to let them know.

-daz
DrO is offline   Reply With Quote
Old 10th April 2012, 14:14   #3
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
Still problems ... :(

Hi Daz,

Thanks for your quick response. I have tried every combination imaginable to get SAM connected to sc_trans ... tried using v1 and userw as password but no luck. Changing sc_trans config to v1 or v2 for the DJ port doesn't help either ... I suspect that earlier versions of SAM that only supported v1 might work, but I have a bunch of DJ's with various versions.

The frustrating thing is that sc_trans requires a username at all ... as the server (sc_serv) does not and SAM works fine direct to the server. But not to sc_trans as a DJ, which is what I really hope to do! Should I try an older build, or has anyone gotten this to work?

Regards,
Steve
thewoose is offline   Reply With Quote
Old 10th April 2012, 14:33   #4
DrO
 
Join Date: Sep 2003
Posts: 27,873
the username is needed by sc_trans to be able to cope with multiple DJ logins and coping with the different priorities which can be set for DJ access. i can see why it's annoying but it's the best way to ensure that things will work correctly and cannot really be equated to how the DNAS works.

as you have access to sc_trans, what errors specifically is it reporting in its logs as that should give a better idea of what is actually going on. as there shouldn't be a reason for it not to work when setting SAM into v1 mode and doing the <dj_name>:<dj_password> method.

-daz
DrO is offline   Reply With Quote
Old 12th April 2012, 18:42   #5
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
Logs ....

Hi Daz,

Yes I know, it should work in v1 mode with userass as the password field in SAM ... but SAM just says connecting for a second or two, and then "Disconnected (10061)".

I put sc_trans in debug mode and here is what it says"

Quote:
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=834 left=3824 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=3824 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=392 out wait cycles=0
2012-04-12 19:29:58 D msg:[UVOX2] 7326 delta=14801 raw_credit=236816 credit=161756 BPS=16000
2012-04-12 19:29:58 D msg:[UVOX2] 7326 readavail=834 writespace=261310
2012-04-12 19:29:58 D msg:[CALENDARMGR] calendarMgr::timeSlice
2012-04-12 19:29:58 D msg:[CALENDARMGR] id=1 is active. running deactivation check
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=3312 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=3312 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=648 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=2800 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=2800 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=904 out wait cycles=0
2012-04-12 19:29:58 E msg:[UVOX2] 7326 [UVOX2] 7326 socket send error.
2012-04-12 19:29:58 E msg:[UVOX2] 7326 Waiting 30 seconds
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=2288 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=2288 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=1160 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=1776 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=1776 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=1416 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=1264 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=1264 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=1672 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=0 left=752 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=752 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=1928 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=240 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=240 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=2184 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=0 left=0 srfnf=136 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=3824 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=3824 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=392 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=1 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=3312 srfnf=2304 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=0 entry bytes=3312 bytes_loaded_from_link=0 bytes generated=0 left=0 srfnf=648 out wait cycles=0
2012-04-12 19:29:58 D msg:[MP3ENC] 11976/44100/2/128000 wait cycles=2 entry bytes=0 bytes_loaded_from_link=4096 bytes generated=417 left=2800 srfnf=2304 out wait cycles=0
Not much to go on, but I have no problem using Winamp so I know it works ...

Thanks,
Steve
thewoose is offline   Reply With Quote
Old 12th April 2012, 18:50   #6
thinktink
Forum King
 
thinktink's Avatar
 
Join Date: May 2009
Location: On the streets of Kings County, CA.
Posts: 3,009
Send a message via Skype™ to thinktink
None of the log you've posted shows any detected activity with DJ connections.

Did you actually setup a v1 DJ port on the Transcoder?

It might be better to attach your Transcoder config file with your passwords/code obfuscated with your next post.
thinktink is offline   Reply With Quote
Old 13th April 2012, 00:43   #7
thinktink
Forum King
 
thinktink's Avatar
 
Join Date: May 2009
Location: On the streets of Kings County, CA.
Posts: 3,009
Send a message via Skype™ to thinktink
I downloaded MySQL and SAM Broadcaster (the trial version.)

I have tested the possible connection combinations and have come to a working theory of why things are the way they are with the current version of SAM Broadcaster; It was not designed for DJ connections to the Transcoder because it is itself capable of automatic DJ stuff. Of course this statement is based on the assumption that there is no difference between the Transcoder DJ ports (v1 and v2) and the DNAS source connection protocols except the extra username parameter (which is hacked into the v1 with a colon separator in the password field.)

In short, it is currently impossible to use SAM Broadcaster encoders in v2 mode to a Transcoder DJ port. You can only use v1 (aka Legacy) ports for SAM Broadcaster in its current incarnation.
thinktink is offline   Reply With Quote
Old 13th April 2012, 02:24   #8
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
True ...

Hi thinktink,

Thanks for testing ... however I'm not even trying to connect SAM using v2, only v1, and yes I do have a v1 port configured. Even with the userassword password field hack in SAM, I still get nothing .... however, I have also tried the same setup on FreeBSD instead of Windows and it works there, so this is just one of those weird-ass voodoo problems. I'm thinking of using FreeBSD for the main server, since it actually works!

Regards,
Steve
thewoose is offline   Reply With Quote
Old 13th April 2012, 02:58   #9
thinktink
Forum King
 
thinktink's Avatar
 
Join Date: May 2009
Location: On the streets of Kings County, CA.
Posts: 3,009
Send a message via Skype™ to thinktink
I ran my tests on Windows XP SP3. SAM, DNAS, Transcoder, MySQL, and Abyss webserver with PHP support all on the same machine. I was able to listen through Project Thundersnow flash player with full metadata display support using the latest published versions of the SHOUTcast tools (and my SPS server to support the flash object.)

So it's kinda odd it didn't work for you on Windows to me.

Maybe it has something to do with your firewall not allowing incoming connections to the DJ ports as well (just a stab-in-the-dark thought) since your last log doesn't show any DJ activity in it.
thinktink is offline   Reply With Quote
Old 13th April 2012, 14:39   #10
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
Hi Thinktink,

Thanks for you advice. I'm unable to run the server on the Windows puter cause it's not local and I can't get a posix OS on it ... however, I have checked the router and all the other ports are open fine. I've tried many different ones just for kicks.

However, on my FreeBSD machine, with the exact same setup, everything works perfectly, including SAM. So what I've done is to use my BSD machine as the transcoder and then the Windows machine as a relay. That's working great, so I'm happy and I think I'll stick with this setup.

Still don't know why the Windows sc_trans isn't accepting the connections from DJs using v1, because Winamp using v2 works fine with it. But having the DJ access is the whole point of using the transcoder for me, so I need it to be reliable. Probably some weird quirk in the OS and/or who knows. One of those 'voodoo' things I guess!

Regards,
Steve
thewoose is offline   Reply With Quote
Old 13th April 2012, 20:19   #11
MADxHAWK
Senior Member
 
Join Date: Jan 2010
Posts: 181
Normaly it shouldnt be a problem to run sc_trans on a windows server. But by default Windows block the Ports sc_trans need for external Dj Connections so you have to open them manualy in the firewall.

-MAD
MADxHAWK is offline   Reply With Quote
Old 13th April 2012, 21:22   #12
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
Yeah it shouldn't be a problem ... however the firewall is off (win xp) ... and I have tried other random ports also. All my other incoming stuff to that server works fine, so I am really baffled as to why sc_trans won't let SAM connect to it. But, it works just fine on posix/BSD so I'm happy =)

-Steve
thewoose is offline   Reply With Quote
Old 13th April 2012, 23:47   #13
DrO
 
Join Date: Sep 2003
Posts: 27,873
sounds like i need to re-install SAM and see what might be going on and that does sound very strange that the BSD version is working ok - is usually the other way round i tend to find.

though just going back over the thread, SAM 4.9.0 is mentioned though isn't there newer versions of it out now - 4.9.4 or something like that? i.e. trying to work out what i really should be trying to get to test with.

-daz
DrO is offline   Reply With Quote
Old 14th April 2012, 00:33   #14
thinktink
Forum King
 
thinktink's Avatar
 
Join Date: May 2009
Location: On the streets of Kings County, CA.
Posts: 3,009
Send a message via Skype™ to thinktink
I tested with the trial version of SAM 4.9.4
thinktink is offline   Reply With Quote
Old 14th April 2012, 11:37   #15
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
SAM stuff

Hi,

Thanks Daz and Thinktink for your research into this. The issue with SAM is that most of the DJs have older (like 4.2.2 or below) versions of SAM, so I have to be able to accommodate them. In my tests I tried 4.2.2, 4.9.0, and an older one (forgot which exactly.) None worked with the windows sc_trans, but on FreeBSD it's all fine. As other people have apparently had no problem using SAM with sc_trans on windows, it must be something specific to this particular machine. It's running WinXP SP3 with the firewall turned off. I have complete access to it, but not physical access, or I would blow up windows and put a "real" server OS on it!

The server is physically located in Denmark if that makes any difference, while me and my FreeBSD server (working perfectly) are in the US. If I had physical access to the computer in Denmark I might find something that could cause the connection problem, however that's not going to happen so I have to work with what I've got.

Thanks again to all who are testing this ... I don't think sc_trans or SAM are at fault here, just some odd combination of "tech voodoo."

Regards,
Steve
thewoose is offline   Reply With Quote
Old 19th April 2012, 07:55   #16
thewoose
Junior Member
 
Join Date: Mar 2011
Posts: 19
All Fixed!

Thanks for everyone's help ... I was finally able to get sc_trans on windows working with sc_serv running on the same machine. Simple config file errors: The default stream id in sc-Trans_basic.conf is streamid_2=2 or something like that, which for my setup was wrong. Changing it to id1=1 allowed sc_trans to connect to sc_serv and work. Then, I was able to connect a Shoutcast v2 source as a DJ, but not a v1 using SAM Broadcaster which has been discussed here. It turns out that the sc_trans_dj.conf file uses the default ports:
code:
djport-8500
djport2djport2=8505


I tried different ports and did port scans and realized that the legacy ports I selected were Closed, while the v2 port was open. At last I looked at the virgin config file, and realized I had added a 1 to djport ... as in
code:
djport1=7997
which does NOT work. When I lost the 1 and had
code:
djport=7997
it worked perfectly. So basically a couple of sytax errors caused these problems. SAM is able to connect in legacy mode quite well, and the DJ calendar and playlist playback work perfectly too. Thanks to all who gave advice about these problems, I'm sorry that it was just a couple of syntax errors which caused the trouble.

One question about sc_trans ... does anyone know of a script for a web page that would allow requests and 'voting' for songs that the automated system plays, as in showing a list of available tracks and then allowing users to vote on what they wish to hear, and then play that track in sc_trans? Kind of a specialized setup, but if anyone has or would share such an example of adding request capability to the "jukebox" I would be most grateful!

Regards,
Steve
thewoose is offline   Reply With Quote
Old 19th April 2012, 11:21   #17
DrO
 
Join Date: Sep 2003
Posts: 27,873
rightio, am surprised there weren't config errors noted at the start of the sc_trans log output when there was things like 'djport1' in place. but is good that you've got SAM working ok in legacy mode on the machine now

as for the other question, i'm not aware of anything out there which does that though pretty much most of sc_trans's behaviour can be 'web' controlled as needed so it could be possible to implement something to do it i would have thought.

-daz
DrO is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Shoutcast > Shoutcast Technical Support

Tags
sam, sc_trans

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump