Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Regular Contributor
Posts: 63
Registered: ‎08-30-2012
My Device: 9900
My Carrier: Various

ShoutCast internet Radio Streaming on BlackBerry

Hiii to Everyone,

                              i started my carrier with j2me(java) Nokia Mobile  and woking for last three months,i have developed two rss Applications using j2me(java),

 

Now i have a Requirement to play shoutcast Internet Radio stream on BlackBerry Java Mobile, Here My Input URL:http://38.101.195.5:9156/ need to play on BlackBerry

 

I have tried to stream and play the above URL using j2me(java) for Nokia mobile,but i failed to open the stream

here my Code for j2me(java):

connection = (HttpConnection) Connector.open(URL);

dataIn = connection.openDataInputStream();//here i am facing java.io.IOException: 11-Error in HTTP operation

 

Can any one Provide me the sample code  for Streaming and Playing the above URL Internet Radio using BlackBerry Java?your help will be appreciated

thanks

pavan

Developer
Posts: 16,786
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: ShoutCast internet Radio Streaming on BlackBerry

try this:
try {
Player p = Manager.createPlayer("http://abc.wav");
p.start();
} catch (MediaException pe) {
} catch (IOException ioe) {
}
from the api
http://www.blackberry.com/developers/docs/7.1.0api/javax/microedition/media/Player.html
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Regular Contributor
Posts: 63
Registered: ‎08-30-2012
My Device: 9900
My Carrier: Various

Re: ShoutCast internet Radio Streaming on BlackBerry

if,i try like that,i am getting the exception like invalidlocator

Developer
Posts: 16,786
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: ShoutCast internet Radio Streaming on BlackBerry

check your url, then.
when i use the one you posted in winamp it cannot connect.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Regular Contributor
Posts: 63
Registered: ‎08-30-2012
My Device: 9900
My Carrier: Various

Re: ShoutCast internet Radio Streaming on BlackBerry

URL is   perfect,IT is working onRealPlayerbut it is shoutcasting URL?

Regular Contributor
Posts: 63
Registered: ‎08-30-2012
My Device: 9900
My Carrier: Various

Re: ShoutCast internet Radio Streaming on BlackBerry

can you tell me ,how can i play the radio?