How to receive RTP data by JMF

Hello!!
I have a ipaq3870 installed Jeode.
I can run JMStudio to play media on PDA and receive RTP data from PC's JMStudio.
But I can't receive RTP data by AVReceive2.
I compressed AVreceive2 into custom.jar.
Can anyone teach me how to do?
Did my steps correct?
Thank you!!
Shih-Wei Chen

Hi,
hope we could talk a little more about this because I am also trying to do some applications with the JMF and Personal Java / Jeode.
So far I haven�t worked with the JMstudio but with the AVReceive and the AVTransmit classes. My Transmit-PC is a Desktop PC running Windows XP and my Receive Handheld is Sharp Zaurus with - as I said - Personal Java / Jeode running.
Both classes run but the Transmitter only says "Transmitting ..." and the Receiver says "Waiting for data to arrive" and nothing happens.
Perhaps you know what I am doing wrong ? Can it be the Windows XP - Linux ? But the JMF ist platform independent, isn�t it ?
Do you think the JMStudio is better than the AVReceive ?
How did you manage to run jmstudio under Jeode ?
Of course he didn�t find the "java" exec because it is called evm but how can I change this ?
Thanks for your help
Poldi

Similar Messages

  • How to receive the datas?

    Look:
    the first I create socket sk:
    sk=socket(AF_INET, SOCK_RAW, IPPROTO_RAW);
    and I fill data into Ip Head and Icmp Head,
    then I sendto the packet,but I don't receive
    any datas:
    lenrecv=recvfrom(sk,buf,100,0,(struct sockaddr*)&addr,&rlen);
    my codes run at the function recvfrom,but it
    couldn't return variable lenrecv,and it look like down,
    I want to know why?how to receive the data?
    (I couldn't creat socket like this:
    sk=socket(AF_INET, SOCK_RAW, IPPROTO_ICMP);
    I want to know when I creat socket like this
    sk=socket(AF_INET, SOCK_RAW, IPPROTO_RAW);
    How to receive datas?)

    Last edited by joseperezc (2012-08-14 18:58:22)

  • Receiving RTP data

    I want to receive RTP data and access it directly. Is there a way to somehow store the incoming data stream into a byte array or something like that?
    I have been looking at the AVReceive3.java code, and it automatically sends the datasource to the player. I need to read the data in and pass it to another program. Thanks for any help!

    I don't know if your diagnosis is correct, for shure I have a lot of jitter between two PC using the same java app and playing a RTP broadcast audio.
    But I could not relate it with the speed of the computer, sometimes A plays before B, sometimes after. Problably it is the time to create objects that varies.
    Still looking for a solution....

  • How to combine rtp data containing video and audio?

    Hi
    I have a problem. I was examining with AVTransmit3.java and AVReceive3.java. I found that AVTransmit3 sending video and audio with different ports. It's okey as it is done as JMStudio. but my question is how can I receive this packets as raw bytes and combines them into one media file to play at a time in a player. May be very fundamental question but tough for me as i m novis as jmf programmer.
    waitin for repply...................

    Look in the JMF Guide regarding multiplexors and demultiplexors. It give the whole breakdown of how this works (and I think examples).

  • How to receive OTF data out of spool request?

    Hi Guys,
    I want to write a program which reads out the OTF data of a spool request and then I want to send it either as eMail or as FAX to some receivers.
    The function modules I found so far (CONVERT_OTF, CONVERT_OTF_AND_FAX etc.) assume that the OTF table is already filled. But what I have in the beginning is only the spool ID. Even the function RSPO_DISPLAY_SPOOLJOB doesn't pass back the OTF data. What I saw in this function is that the OTF data is read directly via C-CAll => Call 'C_RSTS_OPEN' and Call 'C_RSTS_READ'.
    Does anyone of you have an idea how to solve my problem or could give me a hint?
    Thanks,
    Thomas

    Hi Thomas,
    As you said, the OTF is stored as is in the spool file, and you can read it using the C calls, or use RSPO_RETURN_SPOOLJOB function module for example.
    Note that using SP01, you can send a spool via a menu entry, which corresponds to function module RSPO_SPOOLJOB_TO_OFFICE.
    Best regards
    Sandra

  • JMF How to stream rtp from udp packet

    I implemented an rtsp client and use the client to setup two rtp session(audio, vedio). But when I use the example pramgram "AVReceive3" to stream the udp packet, it doesn't work.
    When the AVReceive3 receive the udp packet from the rtp port, it will call the update(ReceiveStreamEvent evt) function, and the event type is StreamMappedEvent, and the call to evt.getReceiveStream().getDataSource() return null.
    I thought the first event should be NewReceiveStreamEvent. Please help to solve the problem.
    What's rtp packet will cause the event StreamMappedEvent.
    Following is the code of AVReceive3.java:
    * AVReceive3.java
    * Created on 2007年10月30日, 下午4:11
    * To change this template, choose Tools | Template Manager
    * and open the template in the editor.
    package PlayerTest;
    import java.io.*;
    import java.awt.*;
    import java.net.*;
    import java.awt.event.*;
    import java.util.Vector;
    import javax.media.*;
    import javax.media.rtp.*;
    import javax.media.rtp.event.*;
    import javax.media.rtp.rtcp.*;
    import javax.media.protocol.*;
    import javax.media.protocol.DataSource;
    import javax.media.format.AudioFormat;
    import javax.media.format.VideoFormat;
    import javax.media.Format;
    import javax.media.format.FormatChangeEvent;
    import javax.media.control.BufferControl;
    * AVReceive3 to receive RTP transmission using the RTPConnector.
    public class AVReceive3 extends Thread implements ReceiveStreamListener, SessionListener,
    ControllerListener
    String sessions[] = null;
    RTPManager mgrs[] = null;
    Vector playerWindows = null;
    boolean dataReceived = false;
    Object dataSync = new Object();
    public AVReceive3(String sessions[])
    this.sessions = sessions;
    public void run()
    initialize();
    public boolean initialize() {
    try {
    mgrs = new RTPManager[sessions.length];
    playerWindows = new Vector();
    SessionLabel session;
    // Open the RTP sessions.
    for (int i = 0; i < sessions.length; i++) {
    // Parse the session addresses.
    try {
    session = new SessionLabel(sessions);
    } catch (IllegalArgumentException e) {
    System.err.println("Failed to parse the session address given: " + sessions[i]);
    return false;
    System.err.println(" - Open RTP session for: addr: " + session.addr + " port: " + session.port + " ttl: " + session.ttl);
    mgrs[i] = (RTPManager) RTPManager.newInstance();
    mgrs[i].addSessionListener(this);
    mgrs[i].addReceiveStreamListener(this);
    // Initialize the RTPManager with the RTPSocketAdapter
    mgrs[i].initialize(new RTPSocketAdapter(
    InetAddress.getByName(session.addr),
    session.port, session.ttl));
    // You can try out some other buffer size to see
    // if you can get better smoothness.
    BufferControl bc = (BufferControl)mgrs[i].getControl("javax.media.control.BufferControl");
    if (bc != null)
    bc.setBufferLength(350);
    } catch (Exception e){
    System.err.println("Cannot create the RTP Session: " + e.getMessage());
    return false;
    // Wait for data to arrive before moving on.
    long then = System.currentTimeMillis();
    long waitingPeriod = 30000; // wait for a maximum of 30 secs.
    try{
    synchronized (dataSync) {
    while (!dataReceived &&
    System.currentTimeMillis() - then < waitingPeriod) {
    if (!dataReceived)
    System.err.println(" - Waiting for RTP data to arrive");
    dataSync.wait(1000);
    } catch (Exception e) {}
    if (!dataReceived) {
    System.err.println("No RTP data was received.");
    close();
    return false;
    return true;
    public boolean isDone() {
    return playerWindows.size() == 0;
    * Close the players and the session managers.
    protected void close() {
    for (int i = 0; i < playerWindows.size(); i++) {
    try {
    ((PlayerWindow)playerWindows.elementAt(i)).close();
    } catch (Exception e) {}
    playerWindows.removeAllElements();
    // close the RTP session.
    for (int i = 0; i < mgrs.length; i++) {
    if (mgrs[i] != null) {
    mgrs[i].removeTargets( "Closing session from AVReceive3");
    mgrs[i].dispose();
    mgrs[i] = null;
    PlayerWindow find(Player p) {
    for (int i = 0; i < playerWindows.size(); i++) {
    PlayerWindow pw = (PlayerWindow)playerWindows.elementAt(i);
    if (pw.player == p)
    return pw;
    return null;
    PlayerWindow find(ReceiveStream strm) {
    for (int i = 0; i < playerWindows.size(); i++) {
    PlayerWindow pw = (PlayerWindow)playerWindows.elementAt(i);
    if (pw.stream == strm)
    return pw;
    return null;
    * SessionListener.
    public synchronized void update(SessionEvent evt) {
    if (evt instanceof NewParticipantEvent) {
    Participant p = ((NewParticipantEvent)evt).getParticipant();
    System.err.println(" - A new participant had just joined: " + p.getCNAME());
    * ReceiveStreamListener
    public synchronized void update( ReceiveStreamEvent evt) {
    System.out.println("\nReceive an receiveStreamEvent:"+evt.toString());
    RTPManager mgr = (RTPManager)evt.getSource();
    Participant participant = evt.getParticipant(); // could be null.
    ReceiveStream stream = evt.getReceiveStream(); // could be null.
    System.out.println("The RTPManager is:");
    if (evt instanceof RemotePayloadChangeEvent) {
    System.err.println(" - Received an RTP PayloadChangeEvent.");
    System.err.println("Sorry, cannot handle payload change.");
    System.exit(0);
    else if (evt instanceof NewReceiveStreamEvent) {
    try {
    stream = ((NewReceiveStreamEvent)evt).getReceiveStream();
    DataSource ds = stream.getDataSource();
    // Find out the formats.
    RTPControl ctl = (RTPControl)ds.getControl("javax.media.rtp.RTPControl");
    if (ctl != null){
    System.err.println(" - Recevied new RTP stream: " + ctl.getFormat());
    } else
    System.err.println(" - Recevied new RTP stream");
    if (participant == null)
    System.err.println(" The sender of this stream had yet to be identified.");
    else {
    System.err.println(" The stream comes from: " + participant.getCNAME());
    // create a player by passing datasource to the Media Manager
    Player p = javax.media.Manager.createPlayer(ds);
    if (p == null)
    return;
    p.addControllerListener(this);
    p.realize();
    PlayerWindow pw = new PlayerWindow(p, stream);
    playerWindows.addElement(pw);
    pw.setVisible(true);
    // Notify intialize() that a new stream had arrived.
    synchronized (dataSync) {
    dataReceived = true;
    dataSync.notifyAll();
    } catch (Exception e) {
    System.err.println("NewReceiveStreamEvent exception " + e.getMessage());
    return;
    else if (evt instanceof StreamMappedEvent) {
    if (stream != null)
    if(stream.getDataSource()!=null)
    DataSource ds = stream.getDataSource();
    // Find out the formats.
    RTPControl ctl = (RTPControl)ds.getControl("javax.media.rtp.RTPControl");
    System.err.println(" - The previously unidentified stream ");
    if (ctl != null)
    System.err.println(" " + ctl.getFormat());
    System.err.println(" had now been identified as sent by: " + participant.getCNAME());
    else if (evt instanceof ByeEvent) {
    System.err.println(" - Got \"bye\" from: " + participant.getCNAME());
    PlayerWindow pw = find(stream);
    if (pw != null) {
    pw.close();
    playerWindows.removeElement(pw);
    * ControllerListener for the Players.
    public synchronized void controllerUpdate(ControllerEvent ce) {
    Player p = (Player)ce.getSourceController();
    if (p == null)
    return;
    // Get this when the internal players are realized.
    if (ce instanceof RealizeCompleteEvent) {
    PlayerWindow pw = find(p);
    if (pw == null) {
    // Some strange happened.
    System.err.println("Internal error!");
    System.exit(-1);
    pw.initialize();
    pw.setVisible(true);
    p.start();
    if (ce instanceof ControllerErrorEvent) {
    p.removeControllerListener(this);
    PlayerWindow pw = find(p);
    if (pw != null) {
    pw.close();
    playerWindows.removeElement(pw);
    System.err.println("AVReceive3 internal error: " + ce);
    * A utility class to parse the session addresses.
    class SessionLabel {
    public String addr = null;
    public int port;
    public int ttl = 1;
    SessionLabel(String session) throws IllegalArgumentException {
    int off;
    String portStr = null, ttlStr = null;
    if (session != null && session.length() > 0) {
    while (session.length() > 1 && session.charAt(0) == '/')
    session = session.substring(1);
    // Now see if there's a addr specified.
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    addr = session;
    } else {
    addr = session.substring(0, off);
    session = session.substring(off + 1);
    // Now see if there's a port specified
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    portStr = session;
    } else {
    portStr = session.substring(0, off);
    session = session.substring(off + 1);
    // Now see if there's a ttl specified
    off = session.indexOf('/');
    if (off == -1) {
    if (!session.equals(""))
    ttlStr = session;
    } else {
    ttlStr = session.substring(0, off);
    if (addr == null)
    throw new IllegalArgumentException();
    if (portStr != null) {
    try {
    Integer integer = Integer.valueOf(portStr);
    if (integer != null)
    port = integer.intValue();
    } catch (Throwable t) {
    throw new IllegalArgumentException();
    } else
    throw new IllegalArgumentException();
    if (ttlStr != null) {
    try {
    Integer integer = Integer.valueOf(ttlStr);
    if (integer != null)
    ttl = integer.intValue();
    } catch (Throwable t) {
    throw new IllegalArgumentException();
    * GUI classes for the Player.
    class PlayerWindow extends Frame {
    Player player;
    ReceiveStream stream;
    PlayerWindow(Player p, ReceiveStream strm) {
    player = p;
    stream = strm;
    public void initialize() {
    add(new PlayerPanel(player));
    public void close() {
    player.close();
    setVisible(false);
    dispose();
    public void addNotify() {
    super.addNotify();
    pack();
    * GUI classes for the Player.
    class PlayerPanel extends Panel {
    Component vc, cc;
    PlayerPanel(Player p) {
    setLayout(new BorderLayout());
    if ((vc = p.getVisualComponent()) != null)
    add("Center", vc);
    if ((cc = p.getControlPanelComponent()) != null)
    add("South", cc);
    public Dimension getPreferredSize() {
    int w = 0, h = 0;
    if (vc != null) {
    Dimension size = vc.getPreferredSize();
    w = size.width;
    h = size.height;
    if (cc != null) {
    Dimension size = cc.getPreferredSize();
    if (w == 0)
    w = size.width;
    h += size.height;
    if (w < 160)
    w = 160;
    return new Dimension(w, h);
    public static void main(String argv[]) {
    //if (argv.length == 0)
    // prUsage();
    String sessions[]= new String[] {"127.0.0.1/6670","127.0.0.1/6672"};
    AVReceive3 avReceive = new AVReceive3(sessions);
    if (!avReceive.initialize()) {
    System.err.println("Failed to initialize the sessions.");
    System.exit(-1);
    // Check to see if AVReceive3 is done.
    try {
    while (!avReceive.isDone())
    Thread.sleep(1000);
    } catch (Exception e) {}
    System.err.println("Exiting AVReceive3");
    static void prUsage() {
    System.err.println("Usage: AVReceive3 <session> <session> ");
    System.err.println(" <session>: <address>/<port>/<ttl>");
    System.exit(0);
    }// end of AVReceive3
    Following is the code of RTPSocketAdapter.java:
    * RTPSocketAdapter.java
    * Created on 2007&#24180;10&#26376;30&#26085;, &#19979;&#21320;4:13
    * To change this template, choose Tools | Template Manager
    * and open the template in the editor.
    package PlayerTest;
    import java.io.IOException;
    import java.net.InetAddress;
    import java.net.DatagramSocket;
    import java.net.MulticastSocket;
    import java.net.DatagramPacket;
    import java.net.SocketException;
    import javax.media.protocol.DataSource;
    import javax.media.protocol.PushSourceStream;
    import javax.media.protocol.ContentDescriptor;
    import javax.media.protocol.SourceTransferHandler;
    import javax.media.rtp.RTPConnector;
    import javax.media.rtp.OutputDataStream;
    * An implementation of RTPConnector based on UDP sockets.
    public class RTPSocketAdapter implements RTPConnector {
    DatagramSocket dataSock;
    DatagramSocket ctrlSock;
    InetAddress addr;
    int port;
    SockInputStream dataInStrm = null;
    SockInputStream ctrlInStrm = null;
    SockOutputStream dataOutStrm = null;
    SockOutputStream ctrlOutStrm = null;
    public RTPSocketAdapter(InetAddress addr, int port) throws IOException {
    this(addr, port, 1);
    public RTPSocketAdapter(InetAddress addr, int port, int ttl) throws IOException {
    try {
    if (addr.isMulticastAddress()) {
    dataSock = new MulticastSocket(port);
    ctrlSock = new MulticastSocket(port+1);
    ((MulticastSocket)dataSock).joinGroup(addr);
    ((MulticastSocket)dataSock).setTimeToLive(ttl);
    ((MulticastSocket)ctrlSock).joinGroup(addr);
    ((MulticastSocket)ctrlSock).setTimeToLive(ttl);
    } else {
    dataSock = new DatagramSocket(port, InetAddress.getLocalHost());
    ctrlSock = new DatagramSocket(port+1, InetAddress.getLocalHost());
    } catch (SocketException e) {
    throw new IOException(e.getMessage());
    this.addr = addr;
    this.port = port;
    * Returns an input stream to receive the RTP data.
    public PushSourceStream getDataInputStream() throws IOException {
    if (dataInStrm == null) {
    dataInStrm = new SockInputStream(dataSock, addr, port);
    dataInStrm.start();
    return dataInStrm;
    * Returns an output stream to send the RTP data.
    public OutputDataStream getDataOutputStream() throws IOException {
    if (dataOutStrm == null)
    dataOutStrm = new SockOutputStream(dataSock, addr, port);
    return dataOutStrm;
    * Returns an input stream to receive the RTCP data.
    public PushSourceStream getControlInputStream() throws IOException {
    if (ctrlInStrm == null) {
    ctrlInStrm = new SockInputStream(ctrlSock, addr, port+1);
    ctrlInStrm.start();
    return ctrlInStrm;
    * Returns an output stream to send the RTCP data.
    public OutputDataStream getControlOutputStream() throws IOException {
    if (ctrlOutStrm == null)
    ctrlOutStrm = new SockOutputStream(ctrlSock, addr, port+1);
    return ctrlOutStrm;
    * Close all the RTP, RTCP streams.
    public void close() {
    if (dataInStrm != null)
    dataInStrm.kill();
    if (ctrlInStrm != null)
    ctrlInStrm.kill();
    dataSock.close();
    ctrlSock.close();
    * Set the receive buffer size of the RTP data channel.
    * This is only a hint to the implementation. The actual implementation
    * may not be able to do anything to this.
    public void setReceiveBufferSize( int size) throws IOException {
    dataSock.setReceiveBufferSize(size);
    * Get the receive buffer size set on the RTP data channel.
    * Return -1 if the receive buffer size is not applicable for
    * the implementation.
    public int getReceiveBufferSize() {
    try {
    return dataSock.getReceiveBufferSize();
    } catch (Exception e) {
    return -1;
    * Set the send buffer size of the RTP data channel.
    * This is only a hint to the implementation. The actual implementation
    * may not be able to do anything to this.
    public void setSendBufferSize( int size) throws IOException {
    dataSock.setSendBufferSize(size);
    * Get the send buffer size set on the RTP data channel.
    * Return -1 if the send buffer size is not applicable for
    * the implementation.
    public int getSendBufferSize() {
    try {
    return dataSock.getSendBufferSize();
    } catch (Exception e) {
    return -1;
    * Return the RTCP bandwidth fraction. This value is used to
    * initialize the RTPManager. Check RTPManager for more detauls.
    * Return -1 to use the default values.
    public double getRTCPBandwidthFraction() {
    return -1;
    * Return the RTCP sender bandwidth fraction. This value is used to
    * initialize the RTPManager. Check RTPManager for more detauls.
    * Return -1 to use the default values.
    public double getRTCPSenderBandwidthFraction() {
    return -1;
    * An inner class to implement an OutputDataStream based on UDP sockets.
    class SockOutputStream implements OutputDataStream {
    DatagramSocket sock;
    InetAddress addr;
    int port;
    public SockOutputStream(DatagramSocket sock, InetAddress addr, int port) {
    this.sock = sock;
    this.addr = addr;
    this.port = port;
    public int write(byte data[], int offset, int len) {
    try {
    sock.send(new DatagramPacket(data, offset, len, addr, port));
    } catch (Exception e) {
    return -1;
    return len;
    * An inner class to implement an PushSourceStream based on UDP sockets.
    class SockInputStream extends Thread implements PushSourceStream {
    DatagramSocket sock;
    InetAddress addr;
    int port;
    boolean done = false;
    boolean dataRead = false;
    SourceTransferHandler sth = null;
    public SockInputStream(DatagramSocket sock, InetAddress addr, int port) {
    this.sock = sock;
    this.addr = addr;
    this.port = port;
    public int read(byte buffer[], int offset, int length) {
    DatagramPacket p = new DatagramPacket(buffer, offset, length, addr, port);
    try {
    sock.receive(p);
    } catch (IOException e) {
    return -1;
    synchronized (this) {
    dataRead = true;
    notify();
    System.out.println("RTPSocketAdapter receive RTP packet from port:"+port);
    System.out.println("The received RTP packet:"+new String(buffer));
    return p.getLength();
    public synchronized void start() {
    super.start();
    if (sth != null) {
    dataRead = true;
    notify();
    public synchronized void kill() {
    done = true;
    notify();
    public int getMinimumTransferSize() {
    return 2 * 1024; // twice the MTU size, just to be safe.
    public synchronized void setTransferHandler(SourceTransferHandler sth) {
    this.sth = sth;
    dataRead = true;
    notify();
    // Not applicable.
    public ContentDescriptor getContentDescriptor() {
    return null;
    // Not applicable.
    public long getContentLength() {
    return LENGTH_UNKNOWN;
    // Not applicable.
    public boolean endOfStream() {
    return false;
    // Not applicable.
    public Object[] getControls() {
    return new Object[0];
    // Not applicable.
    public Object getControl(String type) {
    return null;
    * Loop and notify the transfer handler of new data.
    public void run() {
    while (!done) {
    synchronized (this) {
    while (!dataRead && !done) {
    try {
    wait();
    } catch (InterruptedException e) { }
    dataRead = false;
    if (sth != null && !done) {
    sth.transferData(this);
    Thanks.

    The error of No format has been registered for RTP Payload type 96
    is caused by the dynamic payload mapping, when I add the dynamic mapping between dynamic payload and format. The Player cann't work yet. I think it because JMF doesn't support the format of my clips. For example:
    video: a=rtpmap:96 H263-2000/90000
    audio:a=rtpmap:97 MP4A-LATM/12000/1
    Is there some available plugin to support these format?
    Thanks

  • I am receiving the data through the rs232 in labview and i have to store the data in to the word file only if there is a change in the data and we have to scan the data continuasly how can i do that.

    i am receiving the data through the rs232 in labview and i have to store the data in to the word or text file only if there is a change in the data. I have to scan the data continuasly. how can i do that. I was able to store the data into the text or word file but could not be able to do it.  I am gettting the data from rs232 interms of 0 or 1.  and i have to print it only if thereis a change in data from 0 to 1. if i use if-loop , each as much time there is 0 or 1 is there that much time the data gets printed. i dont know how to do this program please help me if anybody knows the answer

    I have attatched the vi.  Here in this it receives the data from rs232 as string and converted into binery. and indicated in led also normally if the data 1 comes then the led's will be off.  suppose if 0 comes the corresponding data status is wrtten into the text file.  But here the problem is the same data will be printed many number of times.  so i have to make it like if there is a transition from 1 to o then only print it once.  how to do it.  I am doing this from few weeks please reply if you know the answer immediatly
    thanking you 
    Attachments:
    MOTORTESTJIG.vi ‏729 KB

  • How to receive the images / binary data t ype

    How to receive the images / binary data type in webdynpro....
    i have a website that let's the user send email, the email attachment and message are stored in both in images data type....
    q1) can i stored the message into binary data type...but the message is very long.....
    q2) if i have a textbox ...i surely will need to display the message  in string ,right ?
    [......... msg here ........]
    what is the codes to receive the images / binary data type in webdynpro....

    As in your previous post if you are storing them as BLOB object.. am sure you are able to get a byte stream or byte array(bytes[]) out of it.
    There should be some way to identify if its a image or a message BLOB. If its a image , convert into bytes and use 
       WDWebResource.getWebResource(bytes,resource type).getAbsoluteURL()
    to obtain the url.. assign this image UI element..
    In case its the message , use bytes.toString to get the message ..
    Regards
    Bharathwaj

  • How to transfer multimedia file using JMF/RTP through Bluetooth

    Hi,
    I am trying to stream a multimedia file via bluetooth but I don't know how to wrap RTP into bluetooth connection.
    I also tried to cut the multimedia file in small pieces but they can't be read by the player.
    How can I stream a multimedia file via Bluetooth using JMF ??
    Regards,
    Danix

    -danix- wrote:
    Hi,
    I am trying to stream a multimedia file via bluetooth but I don't know how to wrap RTP into bluetooth connection.I know absolutely nothing about Bluetooth networking, but I assume you don't wrap protocols into connections with it...
    How can I stream a multimedia file via Bluetooth using JMF ??You'd need to write a custom RTPConnector that would transmit the RTP packets over a Bluetooth connection rather than the standard UDP socket...
    [http://java.sun.com/javase/technologies/desktop/media/jmf/2.1.1/solutions/RTPConnector.html]
    There's some code to get you started. You'll need to update the SockOutputStream & SockOutputStream classes of the RTPConnector to read/write to a Bluetooth connection rather than a UDP socket.
    Good luck.

  • How will u receive the data into XI when HTTP as sender?

    How will u receive the data into XI when HTTP as sender?

    Hi,
    There is no need to a Sender HTTP adapter, the URL that you are using from the source system to send data to XI will directly post into the integration server.
    http://help.sap.com/saphelp_nw04/helpdata/en/43/64db4daf9f30b4e10000000a11466f/content.htm
    Regards,
    Prakash

  • How to receive date type of oracle in webdynpro?

    Hi
    Experts
       I am trying to receive a date from a table.
       but getting error.
    <b><i>java.sql.SQLException: ORA-00904: "TODATE": invalid identifier </i></b>
      code is given below.
    try
         Statement stmt=wdContext.currentContextElement().getStmt();
         ResultSet rs=stmt.executeQuery("select boss_comment,emp_comment,city,empname,designation,fromdate,todate,no_of_persons from grequest r,g_temp e where status='n' and r.empid=e.empid "); // select statment
         wdComponentAPI.getMessageManager().reportException("After Rs execution",false);
         while(rs.next())
              IPrivateRequestTable.IRequestElement req=wdContext.createRequestElement();
              req.setBossComment(rs.getString("boss_comment"));
              req.setEmpComment(rs.getString("emp_comment"));
              req.setCity(rs.getString("city"));
              req.setEmployee(rs.getString("empname"));
              req.setDesignation(rs.getString("Designation"));
              req.setFromDate(rs.getDate("FromDate"));
              req.setToDate(rs.getDate("ToDate"));
              req.setNoOfPersons(rs.getInt("no_of_persons"));
              wdContext.nodeRequest().addElement(req);
         catch(Exception ex)
         wdComponentAPI.getMessageManager().reportException(ex.toString(),false);
         System.out.println("Error");
    Please Reply.....

    Hi,
    TODATE is a keyword in Oracle. Pl try to avoid the usage of any keywords as column names.
    Regards
    Ayyapparaj

  • How i can receive & send data through port? urgent

    port=9999
    data receive in 4 column
    name, price, high, low
    i want to receive this data & display this data in from & automatic refresh
    do u have any idea ?
    plz urgent reply

    IDS (Internet Developer Suite) is a RAD tool to create database application however that totally depend upon your requirement but if u feels limitation while working on Form IDS , u can switch to Jdeveloper an open source environment but still u have option create bean in Jdeveloper as per your need and bundled it with your Forms.
    I still suggest to discuss the problems which you are facing while invoking the bean in your form so that we can guide u better.
    Finally, neither move to latest version or change your development platform just for seek of fashion
    Hope it clears now!

  • Decode raw RTP packets using JMF

    Hi!
    I have a stream of raw RTP packets comming from another program.
    How can I use JMF to decode all raw RTP packets and get the media stream using JMF?
    /Tec

    Hello,
    Have you resolved your problem?
    I've tried with Jmf, but finaly i receive each stream and save raw data in a file.
    Then i convert it to an audio file format. (tritonus : RawAudioConverter.java)
    If you have resolved with jmf i'm interested by your solution.
    try{
    rtpRcvSock.receive(rcvPkt);
    data = rcvPkt.getData();
              boolean extensionHeader = ( (data[0] & 0x08) == 0x08) ? true : false;
         int payloadType = data[1] & 0x7F;
         int cc = data[0] & 0x0F;
         int sequenceNumber = ( (data[2] & 0xFF) << 8) | (data[3] & 0xFF);
         int mediaStart = 3 * 4 + cc * 4;
         int extLength = 0;
              System.out.println("PayLoad = "+payloadType);
              System.out.println("Seqnum = "+sequenceNumber);
              System.out.println("Data Length = "+ (data.length - mediaStart));
         if (extensionHeader) {
         extLength = (data[mediaStart + 3] & 0xFF)
         | ( (data[mediaStart + 2] & 0xFF) << 8);
         mediaStart += extLength;
         byte[] mediaData = new byte[data.length - mediaStart];
         System.arraycopy(data, mediaStart, mediaData, 0, mediaData.length);
              ByteArrayInputStream bb = new ByteArrayInputStream(mediaData);
                   AudioInputStream aiStream = new AudioInputStream(bb,format,mediaData.length);
                   //AudioSystem.write(aiStream,AudioFileFormat.Type.WAVE,file);
                   file.write(mediaData);
    Then as i told i use RawAudioDataConverter.java
    Sam

  • How to edit RTP Packets

    Hi,
    I want to add some information in RTP Packet, (in Extensions Header). How can I do that in JMF ?
    Thanks in Advance,
    Karthikeyan R

    OK, thank you. So specifically -- if I want to prioritize all of the RTP traffic flowing out through the router, can I do it ALL with just COS and not set any QoS, profile binding etc?
    So far I have enabled the COS Queue, left the default settings (where COS Priorities 6 and 7 are set to highest), then on the COS to DSCP page I have entered the value 46 into the Priority 6 and 7 boxes. All the rest I left at 0.
    Unfortunately this didn't seem to solve the issue. The way I have been testing is to call our PBX from an outside line, then put myself on hold so I can hear the hold music (effectively an audio stream from the PBX server). Then I listen carefully while I run a bandwidth test from speedtest.net.
    During the download test the audio (music on hold) is pretty smooth. But during the upload test (lots of data flowing outbound) the audio gets very choppy. The COS settings I've tried don't seem to improve or even change that
    I assume I'm doing something wrong and/or need to involve QoS somehow?
    - Keith

  • Problem transmitting RTP data

    Hi all, I have made a little headway with the JMF thing on the front of streaming audio data, but am currently encountering a tough problem. So I got this little application that supposedly allows two parties to converse between two RTP streaming devices (PC's and otherwise). Basically the JMF enabled app takes care of voice processing and streaming, while call control (for locating peers) is handled by a third party. I got the application to the point where the app can receive RTP voice data and render it on my speaker but I just can't seem to make any progress on the transmitting part. Below is some of the details.
    - Data transmission (both send and receive) to be handled by the same RTP session (RTPManager), i.e. using the same UDP port.
    - Voice capture via microphone, into Processor.
    - DataSource from Processor hooked up to SendStream created by RTPManager.
    Pretty straight forward? The logic and problem are described below:
    - Created Processor from MediaLocator acquired from CaptureDeviceInfo
    - Configure Processor
    - Set up the data format of the tracks
    - Realize the Processor
    - Start the Processor
    - Using the same RTPManager, as the receive side, add the target
    - Using the RTPManager, create a new SendStream using the DataSource from the Processor
    - Start the send stream
    - Using a packet sniffer to see if there are UDP RTP packets being sent but see nothing, I can see incoming RTP packets from the far end (which is a different application all together), but nothing streaming out from my end.
    - When inquiring the getSourceTransmissionStats JMF reported thousands of packets sent!
    So the Send Stream seemed to think it sent out lots of RTP data, but the sniffer (and the far end speaker) said otherwise. No error or exception were reported.
    Any suggestion? I'd give anything to get access to some diagnostic facility inside the streaming logic to see where the problem could lie.

    I've faced a similar problem, what I did was to use TWO session managers, one for transmitter and the other for receiver. I then used this objects in a container.
    Both peer use the same port, and know each other's address.
    For receiving data from the peer I do:
    RTPManager mymgr = RTPManager.newInstance();
    // add as listener to create players for each incoming stream
    mymgr.addReceiveStreamListener(this);
    SessionAddress localaddr =new SessionAddress( InetAddress.getLocalHost(), port);
    SessionAddress sessaddr = new SessionAddress( peerAddress, port);
    mymgr.initialize(localaddr);
    mymgr.addTarget( sessaddr);For transmitting data to the peer I do:
    RTPManager mymgr = RTPManager.newInstance();
    // add as listener to create players for each incoming stream
    mymgr.addReceiveStreamListener(this);
    SessionAddress localaddr =new SessionAddress( InetAddress.getLocalHost(), SessionAddress.ANY_PORT);
    SessionAddress sessaddr = new SessionAddress( peerAddress, port);
    mymgr.initialize(localaddr);
    mymgr.addTarget( sessaddr);
    // the processor is capturing audio from the mic
    processor.start();
    SendStream sendStream = mymgr.createSendStream(processor.getDataOutput(), i);
    sendStream.start();I probably forgot something when doing copy paste from my code... but I think this might help you
    Good luck
    Marco

Maybe you are looking for