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
New Developer
hobby_johals
Posts: 120
Registered: ‎05-20-2011
My Device: Touch 9800
My Carrier: Vodafone

Unable to stream radio over GPRS and BIS Plan in Blackberry

I am building an application that stream radio channels from different URL's. The streaming works pretty fine over the WIFI network mode. But when we try to stream the radio using GPRS/BIS data plans the player does not work. I am seeking help from the sample code provided on BB forums i.e. http://supportforums.blackberry.com/t5/Java-Development/Streaming-media-Start-to-finish/ta-p/488255

Does anybody have idea what technique to follow to stream via GPRS mode.

Amar
Please use plain text.
New Developer
hobby_johals
Posts: 120
Registered: ‎05-20-2011
My Device: Touch 9800
My Carrier: Vodafone

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

can anybody tell me the solution for the same

 

Amar
Please use plain text.
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

From talking to other people who do this, the solution appears to be in these lines from the referenced article:

"... transport methods that are used by wireless service providers, such as Wireless Application Protocol (WAP/WAP2) or Transmission Control Protocol (TCP)"

 

So I think you need to use WAP or Direct TCP, by specifying the appropriate suffix:

http://supportforums.blackberry.com/t5/Java-Development/Different-ways-to-make-an-HTTP-or-socket-con...

 

For TCP/IP the APN specification is an issue because, unless you know the APN settings based on the network, then you are going to have to get your users to enter the correct value in the TCP Options, or in configuration options for your app. 

 

Does this help?

Please use plain text.
New Developer
hobby_johals
Posts: 120
Registered: ‎05-20-2011
My Device: Touch 9800
My Carrier: Vodafone

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

Thanks for your feedback Peter.

According to your suggestion i have already appended the appropiate suffix . Even set the APN settings.

I have used this method to append the suffix .

 

private static String getConnectionString(){
            String connectionString="";
            if(WLANInfo.getWLANState()==WLANInfo.WLAN_STATE_CONNECTED){
                connectionString="?;interface=wifi";
            }

            else if((CoverageInfo.getCoverageStatus() & CoverageInfo.COVERAGE_MDS) == CoverageInfo.COVERAGE_MDS){
                 connectionString = "?;&deviceside=false";
            }
            else if((CoverageInfo.getCoverageStatus() & CoverageInfo.COVERAGE_DIRECT)==CoverageInfo.COVERAGE_DIRECT){
                String carrierUid=getCarrierBIBSUid();
                if(carrierUid == null) {
                    connectionString = "?;deviceside=true";
                }
                else{
                    connectionString = "?;deviceside=false?;connectionUID="+carrierUid + "?;ConnectionType";
                }               
            }
            else if(CoverageInfo.getCoverageStatus() == CoverageInfo.COVERAGE_NONE) {          
                    }
                return connectionString;
            }

 

 

But still no luck on GPRS or BIS plan.Can you provide me any other altenative??

Amar
Please use plain text.
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

Your code looks fine but I note there is a "?" in your connectionString that I would not expect to be there:

="?;interface=wifi";

would be

=";interface=wifi";. 

 

Can you test the connection logic on the device by just using ti to get a single page via an http connection?

Please use plain text.
New Developer
hobby_johals
Posts: 120
Registered: ‎05-20-2011
My Device: Touch 9800
My Carrier: Vodafone

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

yes "?" is there but it does not create any problem . I try removing"?" but still no luck.

 

Peter this means that streaming will not work on BIS/GPRS plan?

 

You have any idea?

Amar
Please use plain text.
Developer
peter_strange
Posts: 19,599
Registered: ‎07-14-2008
My Device: Not Specified

Re: Unable to stream radio over GPRS and BIS Plan in Blackberry

The short answer is I don't know.  But it would surprise me if it did not work. 

 

From what you have told us so far, I don't know if there is a general problem or a bug in your code.

 

As a test, you could try downloading something like Nobex and test that.  I know that this app has been around a long time and they have talked about streaming over various connections, so that would be a good test. 

Please use plain text.