RFCOMM application Quick question = (2 easy Duke Dollars up for grabs!!!)

Hi all,
Can you use RFCOMM for transfering 'live' data entering at your phone antenna, out through Bluetooth and into another Bluetooth enabled device?
Is L2CAP better?
Thank you
All replies appreciated!
Zino

u dont have bluetooth APIs to compile the code .........i must admit that i am a newbie in bluetooth doing some R&D on bluetooth for the last two days (i sucessfullly downloaded and compiled code on my emulator )and may need your help in developing a bluetooth application for PC :) .
here is the link (it is quite good)
http://benhui.net/bluetooth/tutorial_wtk2_nokiaS60.html
just download the jar files and replace replace both
midpapi10.jar and midpapi20.jar with the jar files u will download.
and you will be happy ....
manik

Similar Messages

  • Load image pixels in 2D array - Duke Dollars up for grabs :)

    Hi everyone!
    I am writting a program that will work from a 2 dimensional array to get the location of any pixel (x and y) coordinates and it's color in an int format. I must apologise for my request but I do not have the slightest clue about images and all I know is how to load one and then display it. Can somebody provide the source code for representing an 50x50pixel .gif image in a 2D array with the index of the array being (x coordinates and y coordinates) and holding the color in int format and I will be eternally greatefull.:)
    Your humble servant,

    Thanks for the code but the functionality i need is
    setting the array to contain all the pixels of my
    image.
    Can you please tell me how I can do that?!
    Image imge;
    imge=getToolkit().getImage("icon.gif");The way i will do:
    Create a buffered Image 50*50
    get the graphics for this image
    draw your image into the buffered Image
    use getRGB(x,y) to get the pixel
    Image imge;
    BufferedImage bi;
    Graphics      gi;
    Color[]       col = new Color[2500];
    imge=getToolkit().getImage("icon.gif"); 
    bi = new BufferedImage(50,50,BufferedImage.TYPE_3BYTE_BGR);
    gi = bi.getGraphics();
    gi.drawImage(imge,0,0,null);
    for (int x = 0; x < 50; x++)
         for (int y = 0; y < 50; y++)
              col[x*50+y] = bi.getRGB(x,y));  
    [/code                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Display mysql table data in a jsf page? (10 duke dollars up for grabs)

    hi,
    im having some trouble on how to display data from a mysql table in a JSF page under the JSF architecture. i need some help on the best and correct way of doing this?
    if you could provide code on how this is done, would be much appreciated.
    many thanks.

    I'm going to assume that you have had experience with doing this in jsp. Watch for my comments by the **** asterisks *****. My skill level is best described as intermediate, so you'll probably want to heed replies from the more accomplished members of the community to improve upon this advice.
    The jsp page:
    <%@ page language="java" %>
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
    <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
    <%@ taglib uri="http://myfaces.apache.org/extensions" prefix="x" %>
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    ***** All of your jsf content must be between the f:view tags ******
    <f:view>
    <html lang="en-US" xml:lang="en-US">
    <head>
    <title>Page Title</title>
    </head>
    <body>
    ***** Here is the h:form tag which constructs the appropriate html form tag.
    ***** You don't need to worry about get/post and all that.
    <h:form>
    ***** The h:panelGrid constructs a table that I'm using purely for layout purposes *****
    <h:panelGrid width="800" columnClasses="textColumns">
    ***** the h:dataTable is doing the heavy lifting here. the var attribute is the name you
                   want to give to the data you're returning. The value
                   attribute it bound to a managed bean named MemberList in my faces-config and all refers
                   to a method named getAll (in bean style) that returns a java.sql.Result.
              ***** You can see below how the columns are laid out with the h:column tags and how the header for
                             the columns are named.
              ***** The dataTable iterates over each value in the outputText tags contained in the column tags.
                             It's bound by the var_name.query_field_name. The field name is the one bundled in your result
              ***** Scroll down to see the MemberList bean code.
    <h:dataTable var="foo" value="#{MemberList.all}">
    <h:column>
    <f:facet name="header">
    <h:outputText value="Name"/>
    </f:facet>
    <h:outputText value="#{foo.name}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="bar Number"/>
    </f:facet>
    <h:outputText value="#{foo.ANET_NUM}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Group"/>
    </f:facet>
    <h:outputText value="#{foo.CUST_GROUP}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Classification"/>
    </f:facet>
    <h:outputText value="#{foo.CLASSIFICATION}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Sector"/>
    </f:facet>
    <h:outputText value="#{foo.SECTOR}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Address"/>
    </f:facet>
    <h:outputText value="#{foo.ADDRESS1}"/><f:verbatim><br></f:verbatim>
    <h:outputText escape="false" value="#{MemberList.ADDRESS2} <br>"
    rendered="#{MemberList.ADDRESS2 != null}"/>
    <h:outputText value="#{foo.CITY}"/><f:verbatim>, </f:verbatim>
    <h:outputText value="#{foo.STATE}"/><f:verbatim>, </f:verbatim>
    <h:outputText value="#{foo.ZIP}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Purchasing Contact"/>
    </f:facet>
    <h:outputText value="#{foo.CONTACT}"/>
    </h:column>
    <h:column>
    <f:facet name="header">
    <h:outputText value="Purchasing Phone"/>
    </f:facet>
    <h:outputText value="#{foo.WORK}"/>
    </h:column>
    </h:dataTable>
    </h:panelGrid>
    </h:form>
    </body>
    </html>
    </f:view>
    *** MemberList bean code:
    package bar.vendor;
    import bar.dbConnectionInfo;
    import javax.faces.context.ExternalContext;
    import javax.faces.context.FacesContext;
    import javax.naming.NamingException;
    import javax.servlet.http.HttpSession;
    import javax.servlet.jsp.jstl.sql.Result;
    import javax.servlet.jsp.jstl.sql.ResultSupport;
    import java.sql.*;
    public class MemberList extends dbConnectionInfo {
    private Connection conn;
    public void open() throws SQLException, NamingException {
    ******* Here is where I set up my connection info. I store it in a separate class.
    ******* You'll set yours up according to your MySQL settings.
    conn = DriverManager.getConnection(getUrl(), getUsername(), getPassword());
              ******* The rest of this is pretty standard. The only exceptions is where I use the FacesContext
              ******* to get the session and getting a parameter map (see below)
    public Result getAll() throws SQLException, NamingException {
    FacesContext facesContext = FacesContext.getCurrentInstance();
    ExternalContext extContext = facesContext.getExternalContext();
    HttpSession session = (HttpSession) extContext.getSession(true);
    ResultSet rs = null;
    String schema = getOracleOwner();
    String sql = "select distinct c.name, c. ANet_Num, ug.cust_group, ug.classification, c.sector, " +
    " a.address1, a.address2, a.city, a.state, a.zip," +
    " trim(cc.fname) || ' ' || trim(cc.lname) as Purchasing_Contact, cc.work " +
    " from "+schema+".cust c, "+schema+".vw_unique_cust_address u, "+schema+".cust_address a, " +
    " "+schema+".cust_group cg, "+schema+".vw_purchasing_contact pc, "+schema+".cust_contact cc, " +
    " "+schema+".baruser nu, "+schema+".dist_contact dc, "+schema+".contract con, " +
    " "+schema+".contract_access ca, "+schema+".vw_unique_cust_groups ug " +
    " where nu.id = ? " +
    " and c.SECTOR = ? " +
    " and nu.fk_dist_contact_id = dc.id " +
    " and dc.fk_dist_id = con.fk_dist_id " +
    " and con.id = ca.fk_contract_id " +
    " and ca.fk_group_type_id = cg.fk_group_type_id " +
    " and cg.fk_cust_id = c.id " +
    " and c.id = u.id " +
    " and to_number(substr(u.desc_type,2)) = a.id(+) " +
    " and c.id = pc.id(+) " +
    " and pc.cc_id = cc.id(+) " +
    " and c.status = 'Active' " +
    " and c.id = ug.id " +
    " order by ug.cust_group, c.name";
    try {
    open();
    PreparedStatement ps = conn.prepareStatement(sql);
    ps.setString(1, (String) session.getAttribute("baruserID"));
    **** This is cool. Look at the f:param tag as it pertains to commandButtons and commandLinks *****
    ps.setString(2,(String) FacesContext.getCurrentInstance().getExternalContext().getRequestParameterMap().get("sector"));
    rs = ps.executeQuery();
    } catch (SQLException sqle) {
    System.out.println(sqle.getMessage());
    } catch (Exception e){
    System.out.println(e.getMessage());
    //close();
    return ResultSupport.toResult(rs);
    public void close() throws SQLException {
    if (conn == null) return;
    conn.close();
    conn = null;
    }

  • I BOUGHT an application from my iphone Application icon and paid 2.99 dollars too, for phone tracker , downloaded sucessfully and its working too but not tracking the phones as mentioned in the description can any one support me??? better from apple

    I BOUGHT an application from my iphone Application icon and paid 2.99 dollars too, for phone tracker , downloaded sucessfully and its working too but not tracking the phones as mentioned in the description can any one support me??? better from apple!!

    Is this the app you're referring to?
    http://itunes.apple.com/us/app/phone-tracker/id348537489?mt=8
    As you'll note it's made by Presselite and that page has a link to their support.
    Also, you'll find it best not to post questions about iPhone apps in the AppleWorks forum. Best to contact the makers of the app.
    Regards
    TD

  • Search Jtree Problem (Easy Duke dollars)

    Hi all,
    I know that in order to find a node is a tree I can use getNextMatch method given by JTree. However, the problem here is that I want to serach for a child node and I don't know how to... for example...
    Root
    - Child 1
    - Child 2
    - Child 3
    If I search for the root node I would simply do
    getNextMatch("R",0,Position.Bias.Forward);But what if I want to search for Child 1 or Child 3? What would be in my search string?

    Hi,
    To search for a node in a JTree, you may use the breadthFirstEnumeration() method of the DefaultMutableTreeNode and then iterate through that enumeration until the desired node is found or the node is not found.
    You need to have a reference to the Root of the tree as a DefaultMutableTreeNode where the seacrh will begin.
    Let's say that the desired node's data = desiredElement
    DefaultMutableTreeNode root = new DefaultMutableTreeNode(.....);
    java.util.Enumeration enum = root.breadthFirstEnumeration();
    while(enum.hasMoreElements())
    DefaultMutableTreeNode node = (DefaultMutableTreeNode) enum.nextElement();
    if(node.getUserObject().equals(desiredElement))
    //you have found the node in the tree
    //you can get the parent using the getParent on this node as well
    //if you want the search path as well
    //if you reach here, the desired node is not in the tree
    mail me in case of problem : [email protected]

  • 10 duke dollars available for this smple doozy!

    I have just started using Java, and already I need to create a simple game, but I am having problems already.
    The game is designed for 2 player with the one human player and the computer. Players alternatively take sticks from a pile, the player taking the last stick loses.
    The game needs to include:
    1. A random integer between 10-80 to generate the pile of sticks.
    2. Implement a smart mode, which means that if the computer starts the game it cannot lose.
    3. Have the facility to play the game reapeatedly without restarting the game.
    It should look like this:
    The starting size of the pile is xxx sticks
    The 1st player is: yyy
    The 2nd player is: computer
    Playing in the MMM mode
    The ppp starts the game:
    turn:yyy --->> removes QQQ sticks
    turn: computer --->> removes QQQ sticks
    The winner is: computer!
    Another game? (yes/no)
    Any Ideas?
    Many Thanks...
    Dr. K

    I don't understand your game as described but it sounds a lot like nim or one of it's many variants. Do a google search on "nim" for plenty of info. Here is a start:
    http://www.csm.astate.edu/Nim.html
    http://www.chlond.demon.co.uk/Nim.html
    Note that traditionally nim is played with multiple piles.
    The game needs to include:
    1. A random integer between 10-80 to generate the pile
    of sticks.Look at the Random class.
    2. Implement a smart mode, which means that if the
    computer starts the game it cannot lose.Here you have to devise and code a winning strategy. That could be quite challenging depending on the rules of the game.
    3. Have the facility to play the game reapeatedly
    without restarting the game.This is pretty simple. I don't want to sound discouraging but if you can't figure this out then step 2 is out of the question.

  • Quick ? - How do I Assign IRQ For VGA (865PE)

    Quick Question - How do I Assign IRQ For VGA (865PE)
    Kim :D
    IANG

    You can't as all taken care by WinXP ACPI.

  • Duke Dollars Question

    Hi,
    I have posted couple of questions with DUke Dollars. I did not reward them because nobody answered my question. Now i can i use those dollars in my New Posts.
    thanks.

    You can also un-assign them (get them back) assuming Sun hasn't changed the web site lately, but I don't remember exactly the URL you have to hit. Search the forums for "reward.jsp" and see if you can find another post about doing that.

  • Duke Dollars give away

    Hi
    I have some duke dollars which i have assigned to a post, but no one seems to answer me the question properly, So i am asking people to quickly push some valid answers for this and claim their worthy duke dollars.
    To claim the duke dollars kindly go to this thread and answer it
    9 duke dollars are available
    http://forums.java.sun.com/thread.jsp?forum=45&thread=133596
    Thanks
    Swaraj

    The duke dollars are over.
    Thanks
    Swaraj

  • A quick question about WebDynpro SLD and R/3 with concurrent users

    Hello ,
    I have a very quick question about Webdynpros and SLD connecting to an R/3 system, when you configure a webdynpro to connect to an R/3 system using SLD, you configure a user name and password from the R/3  for the SLD to use. What I would like to know is when I have concurrent users of my webdynpro, how can I know what one user did in R/3 and what another user did? Is there a way for the users of the web dynpro to use their R/3 credentials so SLD can access the R/3? Like dynamically configuring the SLD for each user?
    - I would like to avoid leaving their their passwords open in the code ( configuring two variable to get the users username and password and use these variables as JCO username and password )
    Thanks Ubergeeks,
    Guy

    Hi Guy
    You will have to use Single Sign On to achieve this. In the destination you have defined to connect to R/3 , there is an option to 'useSSO' instead of userid and password. This will ensure that calls to R/3 will be with the userid that has logged into WAS. You wont need to pass any passwords because  a login ticket is generated from WAS and passed on to R/3. The userid is derived from this ticket.
    For this to happen you will have to maintain a trust relation ship between R/3 and your WAS ,there is detailed documentation of this in help files. Configuration is very straight forward and is easy to perform
    Regards
    Pran

  • QUICK QUESTION ABOUT PORTS

    Hi, I have a quick question about port forwarding/mapping. My question, lets say I am running MSN messenger, who's ports are 6880-6900. But lets say I am running a torrent application or something else that requires those ports. If both applications were running at the same time, would this cause interference with them on the same ports or now. Thanks
    Nathan

    Normally, only one application can listen to a specific port number at a time. If MSN is grabbing those 21 ports then your torrent app won't be able to run.
    However, most apps don't work that way - even if they use multiple ports, they don't use them all at the same time, so MSN might use 6880 when it starts up, leaving the others open for other applications to use if needed.
    Only experimentation will answer that one.

  • 2 Quick Question

    Hello - I'm pretty new to Motion and have 2 quick questions:
    1) If you've got a bunch of keyframes on a timeline and want to make the entire sequence longer - is there a way to just pull the last frame out and have it automatically interpolate the keyframes in between so that it keeps the same timing and everything... it just makes the whole sequence take longer?
    2) On the same timeline with a bunch of keyframes, can you apply one long Interpolation (ala "Ease Out") to the entire thing from A-Z so that the whole sequence eases out rather than just keyframe to keyframe?
    Thanks!!
    Jason

    Heya,
    1. If you're asking if you have something like the "roving" keyframes in AE...well, kinda. Keyframes on footage, shapes, generators, particles, replicators—objects that create an image—don't seem to scale. But keyframes on secondary objects like behaviors and filters do scale.
    2. Very easy: go into the Keyframe Editor and click on the animation state icon/menu for the parameter you want to change. The icon/menu is the last column after the parameter's value in the left-hand side of the Keyframe Editor. If you pick an interpolation type in that menu, it applies it to all keyframes in that particular curve. It's also the same place where you can set the before/after extrapolation, like ping-pong, progressive, etc.

  • Quick Question: When to use ( ) and when to use [ ] and why the ( *)

    Hi all,
    A quick question that i'm sure is very simple but is slightly confusing me. I've just started trying to learn Objective-C and am a little confused by ( ) and [ ].
    I get that you use the [ ] brackets when you want something specific from an object, i.e.
    [ textField textColor ]
    and that you use ( ) brackets for things like:
    if ( x == y) {
    But I get confused when I see things like:
    NSLog(@"some text here");
    Why does that get ( ) brackets and why is it not [ ].
    Also another point of confusion, creating methods... Why are some methods done like:
    - (void)awakeFromNib
    And others done like (with the additional "*" added):
    - (NSString *)stringvalue
    As I said, I'm sure this is very simple and obvious, but it is confusing me slightly.
    Thanks in advance!

    Adam:
    As you already know, square brackets are used to send a message to an object, so if a object like myObject implements the method -doSomething, you can call it with:
    \[myObject doSomething\];
    The other use square for brackets have is to index C-style arrays, such as:
    aValue = anArray\[10\]; // Get the 10-element of an array
    However, because C-style arrays are rarely used in Cocoa applications (use NSArray instead) you will not see this situation often.
    Parenthesis in expressions are used to group and prioritize, such as:
    x = 10 * (3 + 5); // x = 80
    If () statements use it to delimit the test expression. Same with while (). for () uses it to enclose the limits and increment statements, etc.
    The other important use of parenthesis is in calling a C function:
    result = foo(3);
    means that you are calling the function named foo with the argument 3, and storing the the return value in the variable 'result'. This is different from a message because a C function is not a method of an object. They exist independently of any objects. NSLog() is a function defined within Cocoa but it is not a method. So, you call it with the traditional C function call syntax. Cocoa defines other functions like NSStringFromRect(), which takes an NSRect as argument and returns a pointer to an NSString.
    And that leads me to your last question. Some methods return simple types, like int, float, or void (i.e. returns no value). These methods will have prototypes like:
    \- \(void\)returnNothing;
    \- (int)returnInteger;
    Other methods return pointers to types, like:
    \- (int \*)returnPointerToInteger;
    \- (void \*)returnPointerToAnything; // In obj-C one typically uses id instead of void*
    Returning whole objects from methods has problems and it is better to just return a pointer (the address in memory) instead:
    \- (NSString *)makeAString;
    The method above returns a pointer to an NSString rather than the entire object.
    Good luck with your learning,
    Juan-Pablo
    Message was edited by: Juan Pablo Claude

  • Assigning duke dollars

    How do I award Duke dollars to the best respondent to my question?

    After you post a question, there will be a hyperlink like "assign duke dollar" in the page of your post. Follow it to assign the duke dollar to your question. To reward the duke dollar to the response, you have to log in first, open your post, then you can see a icon in front of every repsponse, you can click the one you want to reward.

  • I wanna assign you ALL my Duke Dollars....

    ...for a new question i have BUT b4 I can do that I need to retrive back the duke dollars from my earlier messages that haven't been answered and have my dollars gathering dust...how on earth do i do that?

    Silkm I have no issues with assigning you all my dukes from all those earlier questions...just go there, type anything and I will assign them to you if u can solve my query...
    It's gotta do with setting the classpath...and yes, i have already been thru google and forums here...
    This is what i do:
    - Start>Control Panel>System>Advanced>Environment Variables
    - Click on Path in the System Variables section
    - Click Edit and add C:\Program Files\Java\j2re1.4.1_01\bin AFTER %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;c:\Program Files\Common Files\Adaptec Shared\System;
    - Next I go to DOS and get my C prompt to C:\Program Files\Java\j2re1.4.1_01\bin
    - I type javac helloworld.java and ENTER
    - I get "javac is not recognised as an internal or external command, operable program or batch file"
    So then I go back to Start>Control Panel>System>Advanced>Environment Variables
    - This time I click on New in the "User Variables for Gaurav" section(that's me) - after all i am logged in as Gaurav on my XP machine!
    - I type Path in Variable Name and C:\Program Files\Java\j2re1.4.1_01\bin in Variable Value
    - Save
    - goto DOS
    - type helloworld.java and get "javac is not recognised as an internal or external command, operable program or batch file"
    BTW i have installed j2re-1_4_1_01-windows-i586 on a XP machine
    HELP!

Maybe you are looking for

  • ITunes Sharing Mac/Windows

    Is there a simple way to share my iTunes library from my Mac partition with my Windows 7 partition without having to copy the same music on both sides? I looked up an older thread, but the best option (required Command Prompt) said I did not have suf

  • Problem removing sunlight in photo.

    In this photo, i want to remove the sunlight so as to make it more appropriate. I googled up and tried several methods but none worked out for me. Im using Photoshop CS5. It would be very kind of anyone who get me out of this problem.

  • Characteristic as block characteristic

    Hello, what is the indicator (in the planning modeler) that a characteristic is relevant for building blocks ? My problem is, that i have to run an own developed planning function over all records available for a year and version, and now our system

  • Is complex type request supported by web service data set?

    I just installed OBIEE 11g and tried to create data models with web services. It works fine for web services that takes simple data types and returns complex data types. But if the request to the web service is a complex type, it doesn't work. On the

  • Time dependent HR master data question

    Hello, I want to compare the two records ( Current record with the  most recent delimited record) for pay rate for an employee. 0EMPLOYEE does not have DATETO or DATEFROM in its attribute list. Furthermore, I can not add DATETO as an attribute since