Skip to main content
Participant
March 17, 2008
Question

streaming audio with rtmp error

  • March 17, 2008
  • 2 replies
  • 357 views
Hi all, I'm trying to build a radio stream player for my site and I'm having some issues, here's my actionscript and the error. Any help please?

rtmp://fcs_server_name/app_name/instance_name
So I'm getting a connection, but then I'm getting a weird error:
///////////////// OUTPUT ////////////////////////
> nc status > NetConnection.Connect.Success
The connection code is: NetConnection.Connect.Success
> ns status > NetStream.Play.Failed
>> Invalid tincan object name (stream ID: 1).
///////////////////////////////////////////////////////
Code:

nc = new NetConnection();
nc.onStatus = function(oInfo:Object):Void {
trace("> nc status > " + oInfo.code);
trace("The connection code is: " + oInfo.code);
};
nc.connect("rtmp://fcs_server_name/app_name/instance_name");

// create a stream with which the MP3 files
ns = new NetStream(nc);
ns.onStatus = function(oInfo:Object):Void {
trace("> ns status > " + oInfo.code);
trace(">> " + oInfo.description);
};
ns.setBufferTime(1)
//ns.play("index.flv", 0, -1, true);
ns.play("rtmp://fcs_server_name/app_name/instance_name",0,-1,true);
    This topic is closed to new replies. Start a new post to keep the conversation going.

    2 replies

    June 5, 2008
    first argument of ns.play() should be the stream name.

    ns.play("myStream",0,-1,true);

    for playing file myMusic.mp3 stream name will be mp3:mymusic

    ns.play("mp3:myMusic");
    Known Participant
    June 5, 2008
    hi, did u get any solution for this, im also getting same problem, but when im giving http URL, stream plays..its only when i try to connect to FMS..this error occurs.