How to connect j2me game to another j2me game via gprs

i create a simple game like tic tac toe, but i still confuse how can i play with my friend via gprs. need help in server configuration, and what connection should i use http connection or socket connection. if anyone know the script for my j2me and server please tell me.

If you're using MIDP 1, which is what you need if you plan on deploying the game on an available phone, then the only protocol that you can count on being supported is Http. So if you're looking for portability across a large number of devices then that's what you should use (HttpConnection specifically). Also, since there is no push architecture in MIDP 1, you'll need to use the technique called "polling", which means you're clients are going to have to send requests to the server every few seconds to check for updates in the game.
I actually did a little 2 player tic tac toe to teach myself MIDP, and the code is available at planet source code:
http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=3398&lngWId=2
(If the link doesn't work just make a search for MIDP under the Java section).
You have to add a line to the JAD file that has the URL of the servlet, or you can replace:
String url = getAppProperty("TicTacToe.URL");in sendMessage() with a hard-coded string.
The servlet is very very crude, since I have little experience using Java on the server side and I was more interested in doing the client, and it just links the first two available players and automatically starts a game. But I think it might serve as good starting point for you. And of course, if you are more comfortable with other server-side technologies then you should use them instead of a servlet.

Similar Messages

  • How to connect my iPhone 4 to MBA 11" via Bluetooth?

    how to connect my iPhone 4 to MBA 11" via Bluetooth?

    system preferences>bluetooth.  i don't own an iPhone, but that's how you access bluetooth and its settings.

  • How to connect one XI to another XI

    Hi all,
    I want to connect one XI system to another XI, the scenario is :
    systems:   R3_A,  XI_A,  R3_B, XI_B
    now, R3_A connect to XI_A; R3_B connect to XI_B;
    my client want to exchange data btw R3_A and R3_B, but they dont want to using direct connection using RFC or IDOC.
    they want to use those flow:  R3_A -> XI_A->XI_B--->R3_B;
    the data send from R3_A forward to two ways by XI_A, one is to an external system, another is to XI_B, so i want to use BPM to split the message.
    i dont know how to connect XI_A to XI_B.
    ple help me.
    Thanks.

    Did you searched SDN with the term "XI to XI"??
    Re: PI to PI integration?
    Re: Xi-to-Xi-scenario
    If you make a search you will find lot many threads....
    Regards,
    Abhishek.

  • How to connect one bean to another!

    Hi,
    Can someone please help me on this? I'm trying to connect one bean to another in an applet I'm creating in a panel. I haven't seen any documentation on connecting one bean to another(regardless of JDev's own bean or 3rd party bean).
    Thanks a bunch.
    M

    Did you searched SDN with the term "XI to XI"??
    Re: PI to PI integration?
    Re: Xi-to-Xi-scenario
    If you make a search you will find lot many threads....
    Regards,
    Abhishek.

  • How to connect one table to another in XL reporter

    Hi,
    I have to take Service Type ( warranty) Contract No. from OCTR table which is internally connected to OINS table then to ODLN table so how to connect ODLN to OINS & then to OCTR  table.
    Regards,
    Ruheena Tasneem.

    Hi,
    In service call module
    1)Customer Equipment Card
    2)Service Contract
    is there Customer Equipment Card (OINS )is internally connectd to Service Contract (OCTR) & Delivery
    (ODLN).
    i have to connect ODLN to OINS to OCTR , OCTR table contains service type (warranty) Contract No.& get the data .Through SQL query i solved but i want how to do in xl reporter.
    Thanks ,
    Ruheena Tasneem.

  • How to Connect a 9124 to another 9124

    Hey all,
    I'm hoping someone can help me with this. I have two 9124's Im trying to connect to each other. One is a 9124blade in a HP c7000 chassis and the other is a standalone 9124. I have 4 ports configured on each switch in a port channel with port mode "E" on the individual ports and on the port channel. Following Cisco documentation the trunk mode on the blades are set to trunk mode "trunk" and the standalone are set to trunk mode "auto" The port channel ID's are unique on each switch, and the speed it set to auto on both switches
    The standalone 9124 have our existing zone config and I need to keep that, the blade 9124's dont need any zoning I just want them to pass the wwid's of the HP blades to the standalone switches.
    The problem is when I admin up the ports they do not link I get link down on both switches on all ports. Can anyone help with any ideas?
    Thanks in advance

    Thanks for the reply Ken
    so far I have gotten the links to come up as TE ports, but what seems to be happening is that the existing 9124 that has all of the zoning info becomes unmanageable as soon as I bring up the link. I have to delete the new switch and the existing one from fabric manager and re-add them again.
    I simply want to connect the new "edge 9124" to the existing "core" 9124 and have the edge do nothing but pass wwid's to the core(existing) 9124 that has the zone config.
    Both switches have different domain ID's
    Both Domain ID are allowed the the domain Manager
    The core existing 9124 has a higher priority the the new switch
    the link(s) are configed as E ports and trunking is on (shows up as a TE port)
    all vsans are allowed across the link
    Thanks in advance

  • How to connect 10.9 Mac to USB printer via E2500 router?

    So I've established that Linksys Connect software is incompatible with a Mac running OS 10.9 Mavericks.
    Is Linksys Connect the only way to connect a Mac with a printer connected to the E2500 router? Or is there another way to make it work?

    New operating systems and older software always have compatibly issues. Recently firmware updates have been pushed out. Maybe one will come for the E2500.
    In a business environment you would normally share out the printer from a server or PC. Sharing from a router will be problematic.
    How about the reverse; sharing the printer from the MAC to the PC? Do you have an old computer lying around you can turn into a Printer server? I just had a thought, there are actual printer server devices made for this as well.
    Please remember to Kudo those that help you.
    Linksys
    Communities Technical Support

  • How to connect the iPhone 4 to macbook pro via wifi

    How can I connect my iphone 4 to my Macbook pro via wifi? Both devices are using the same wifi... I need your help.... Thanks a lot!

    you do NOT do this via Bluetooth.  If you have iOS 5, you can synch via WiFi.  If not, you sync via USB

  • How  to connect .... MYSQL database via JSP

    Hello,
    I am not able to connect mysql database via JSP... everytime i try to connect the database i get the following error .....
    "java.lang.NoClassDefFoundError: org/aspectj/lang/Signature" ..
    my jsp code is ....
    <%@ page import = "java.sql.*" %>
    <%
    Connection conn = null;
    Statement smt = null;
    ResultSet rs = null;
    %>
    <%
    Class.forName("com.mysql.jdbc.Driver").newInstance();
    conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/mydatabase","username" ,"password");
    smt = conn.createStatement();
    rs = smt.executeQuery("select * from table");
    out.println("output is "+ rs.getString("my field"));
    rs.close();
    %>
    I have installed ............
    jdk1.5.0_02
    MySQL Server 4.1
    there are two jar files .. i tried with both jar files ..
    mysql-connector-java-3.1.8-bin.jar
    mysql-connector-java-3.1.8-bin-g.jar
    tomcat server 5.5.9
    my path .... is
    C:\Program Files\Java\jdk1.5.0_02\bin;C:\jakarta-tomcat-5.5.9\bin;C:\program files\mysql\mysql server 4.1\bin;
    any help on this error ..at the earliest ..
    ... am worried ..bcoz my deadlines is getting closer .....
    .. step by step .. procedure .. could be helpful ..
    anil

    Find out the JAR which contains the class and add it
    to WEB-INF/classes directory for your web application.WEB-INF/classes directory ..means ..C:\jakarta-tomcat-5.5.9\common\classes .. is that the one i need to keep my jar files ....???????????
    well i have downloaded .. mysql database connector from the website "http://www.mysql.com/products/connector/j/ " .. and i have downloaded MySQL Connector/J 3.1..under which i have downloaded "Source and Binaries (zip)" ..
    anil

  • How to connect between th iphone 3 and ipad4 via Bluetooth ? (it does not work)

    This is done in order to use the 3G via the iphone.

    If your carrier doesn't support it then there probably isn't much that you can do about it (if you want to stay with your current carrier). You can get mifi devices (effectively a mobile 3G router) which you can use with iPads, laptops etc, and they also use a sim card so you could consider getting one of those - I haven't got or used one so I can't comment on how good they are, and I don't know whether you have to go for a subscription with them or whether they can be used on a 'pay as you go' basis if for example you wouldn't be using it that much.

  • How to connect database(MSAccess ) in j2me

    hi,
    i'm new to j2me. can anyone tell me how to connect MsAccess database with the j2me.and also whether it is possible to connect or else we have to use some other database such as Mysql or oracle.
    thanx a lot in advance
    regards
    laxmi

    Not directly. Please use the search, was already asked numerous times!

  • How  to  connect  to  database

    Hi Experts,
    i am using oracle 10g (10.2),linux4.6 .my databae server contain multiple databases how can connect one database to another database and how can i put this all environment variable in single parameter file

    tmadugula wrote:
    Hi Experts,
    i am using oracle 10g (10.2),linux4.6 .my databae server contain multiple databases how can connect one database to another database and how can i put this all environment variable in single parameter fileYou can see from the responses two very different sets of advice. To know what applies to your situation, you need to clarify what you need to do.
    If you are talking about choosing which database you connect to from sqlplus, follow the advice about changing the environment variable ORACLE_SID.
    If you are talking about having one database being able to access another (one db acts as the client to another) follow the advice about db links.

  • How to connect j2me to sip server

    Hi friends ...
    I am new to this topic and i just want to know how to connect a real sip server with the j2me application .
    I tried using the GoSIP demo given in wtk2.5 . its working fine with local SIP proxy and registrar given in that .
    But i want to connect to a real SIP Server. Even i have a registered sip number.
    Can any one please help me how to sort out this problem as i am very new to this topic. Is there any source given for this ??? If so please tell me ...
    Thanks in advance ......

    is it possible to make
    voice calls from the GoSIP example given in the
    wtk2.5 demo examples ?
    Probably not. Have you tried?
    I have a sip account and i just want to know how to
    register my sip account with the sip server using a
    j2me application .
    Change the SipHeader and / or SipAddress
    What are the changes to be made in the GoSIP example
    to connect to a real sip server and not to the sip
    proxy server
    See above
    and what are the syntax to be changed
    in it ????
    Syntax is a property of the programming language, not the application.
    And one question mark is enough to pose a question, 4 is overkill and perceived as rudeness.
    Please help me in solving out this problem ....
    What have you done to help yourself?
    Read the javadoc for jsr-180
    http://www.forum.nokia.com/document/Java_ME_Developers_Library_v2/GUID-2508C2ED-C0BE-4512-9302-6805AB7ACB0E/index.html
    Introduction to the SIP API for Java ME
    http://dev2dev.bea.com/lpt/a/565
    A presentation on the architecture and capabilites of SIP
    http://phoenix.labri.fr/documentation/sip/Documentation/Papers/Programming_SIP/Presentation/Jain/SIP_for_J2ME.pdf
    Thanks in advance ....
    If you're looking to solve a need by cut-n-paste programming sans understanding, you're unlikely to get it here.
    Increase your level of understanding, experiment with your codes and post back when you have a specific issue.
    Good luck, Darryl

  • HT4314 How to connect Game Center to another Facebook account?

    Hi,
    Please tell me how to connect my Game Center app to a new Facebook account. I tried to do it from the iPad Settings menu but there were no such option...

    If you're using MIDP 1, which is what you need if you plan on deploying the game on an available phone, then the only protocol that you can count on being supported is Http. So if you're looking for portability across a large number of devices then that's what you should use (HttpConnection specifically). Also, since there is no push architecture in MIDP 1, you'll need to use the technique called "polling", which means you're clients are going to have to send requests to the server every few seconds to check for updates in the game.
    I actually did a little 2 player tic tac toe to teach myself MIDP, and the code is available at planet source code:
    http://www.planetsourcecode.com/vb/scripts/ShowCode.asp?txtCodeId=3398&lngWId=2
    (If the link doesn't work just make a search for MIDP under the Java section).
    You have to add a line to the JAD file that has the URL of the servlet, or you can replace:
    String url = getAppProperty("TicTacToe.URL");in sendMessage() with a hard-coded string.
    The servlet is very very crude, since I have little experience using Java on the server side and I was more interested in doing the client, and it just links the first two available players and automatically starts a game. But I think it might serve as good starting point for you. And of course, if you are more comfortable with other server-side technologies then you should use them instead of a servlet.

  • Where can I find a good tutorial for mobile game developement with J2ME ?

    Hi All,
    I'm completely new to J2ME programming. But I have past experience on J2SE developement. Now I would like to know that where can I find a good tutorial for mobile game developement with J2ME ?
    I'll be very greatful if I can find a useful step-by-step tutorial (eg. "The Java Tutorial" for J2SE)
    Please point me ot the direction.
    Thanks
    ZuriJAckshoT

    ibook-widgets.com    have a free tutorial book in the iBooks store.  Search for "Create your first interactive book using iBooks Author"   they also  sell widgets.
    I  dont have any connection - I  found their eBook in the store long ago  and used it to learn more about iBA.
    The best advice though, is be patient,  go back over the process step by step, I cannot  access the Help files for some reason.. but i am sure its in their.

Maybe you are looking for

  • Apps open and then shut down right away

    Most of my apps will open but then they shut down right away....any thoughts? I did reboot

  • Xfce4 xorg 1.6 font troubles

    Hi, im trying to setup (im newbie in archlinux) my xfce4, all is fine..but my fonts not sure http://img9.imageshack.us/img9/6668/clipboard01my6.png if you see my destkop, the font im using with anti-aliasing but i still find is a bit difused... i wan

  • HINCREMP/Claims Disbursement report

    Hi Experts, I am running this report for disbursement of unclaimed medical allowances; it updates infotype 267 for an offcycle payment. but i want it to update IT 15 for a regular payroll run. Can please some one tell how i can achive this. its very

  • Preparing to Upgrade to LiveCycle ES from 7.x document error: page 85

    Preparing to Upgrade to LiveCycle® ES from 7.x document error: page 85, when configuring the JMS with Microsoft SQL Server 2005 for JBoss 4.0.3 SP1. Step 5: Modifiy <local-tx datasource> element .....   <connection-url> jdbc:microsoft.sqlserver .....

  • Iplanet messaging and OID

    I have been trying to setup iplanet messaging to use Oracle LDAP Server (OID), rather than using iplanet's directory server. I have run into many schema incompatibility issues. Has anyone ever created this environment and can point me in the right di