Wire bachground for Bluetooth Serial Port Communication

Hello

I want to make a request which should be as a background thread to run after that BB has been activated.

I tried something:

1. I used BluetoothSerialPortListener and as a normal application. After I chose the menuitem, it begins to listen to the bluetooth serial port. When the data are arrived through the port, it extracts the data and write a response to the sender. Then he out the value and display it on the screen, where I used an object of class screen. But, after posting a value, it cannot display the value came second. I tried, what the old screen pop fist, then puschup the new screen. But it does not work. How can do it, when the new value, they can be diaplayed on the screen?

2. then I did the BluetoothSerialPortListener in thread and used the autostart flag such as:

Public Shared Sub main (String [] args)
{
If (args! = null & args.length > 0)
{
if(args[0].) Equals ("autostartup"))
{
Starting the device we want to start the thread SycareBluetoothPortListener
             
sycare_synergy ss = new sycare_synergy();
}
}

This time around the Listner should take only data is arrived and then sends a response to the sender. But after downloading, BB has always shown that he was unable to generate a new object of the thread class and the thread could not be started.

Someone tell me, how can I fix it and make it possible, that after each new start of the BB, the bluetooth serial port can always in the background arrivals data receive and display automated according the data arrived?

Thank you in advanced and Merry chiristmas!

Monternet

1. update the user interface.

It is possible that you are trying to do.  In fact, you don't need to replace the screen, you should be able to simply update a field on the current display of data.  As an example of a background thread to update the user interface, please see the code of httpdemo.

2. Thread context

When you say things like:

"that he could not generate a new object of the thread class.

It would be much better if you can cite exactly what makes the Blackberry.  In this case, I assume that it has generated an Exception, so the Exception and the associated detailed message that Exception must be included when you report a problem like this.

In any case, it is possible to implement a background task in the way you need.  Search the Knowlegebase for articles that talk about background Applications and display updates to the user interface of the task in the background and auto-start applications.  There are a few pieces of confusion to this process, so there are a few to get your head around, but I think that everything is in the articles.

Tags: BlackBerry Developers

Similar Questions

  • Part number for the serial port in option HP Z420

    I am looking for the serial port in option for the HP Workstation Z420, but in a datasheet, it is only mentioned as an optional serial port kit.

    What is the number on the right side of the product? The same for the workstation Z400 was PA716A, but it was not compatible with the new workstation model...

    I used the same part number, I used to model Z400 and it seems to work well.
    HP code is PA716A.

  • HP Compaq dc7700p: need driver for PC serial port

    "Hello, I have a desktop Tower" HP Compaq dc7700p Convertible Minitowers "running windows 7 Ultimate and need driver for PCI Serial port... here's hardware id:

    PCI\VEN_8086 & DEV_2997 & SUBSYS_2802103C & REV_02
    PCI\VEN_8086 & DEV_2997 & SUBSYS_2802103C
    PCI\VEN_8086 & DEV_2997 & CC_070002
    PCI\VEN_8086 & DEV_2997 & CC_0700

    Thank you

    Hello:

    You need this driver... You may need to install it manually.

    http://h20565.www2.HP.com/hpsc/SWD/public/detail?sp4ts.Oid=3232104 & swItemId = ir_46768_1 & swEnvOid = 2103 #.

  • Another question on serial port communication

    Hi all!

    I started working with tools of communication series LV (actually, I'm a newbie in LV at all).

    The question is - how I effectively detect y at - he new data arrived in the read buffer VISA?

    I mean, in the examples I found, there is always a fixed delay between writing series and the read operation - it makes the instrument depends on the speed of communication and (worse) on the response time of the required device. I want to implement is a vi that writes a (or different applications) via a serial port and then check periodically (with the relatively small period, say, 1ms) series read buffer for the response data until new data stops arriving. For this I need to know the number of bytes of data into the buffer, or a property (if any) detecting the arrival of new data.

    As I read on this forum (and figured out from my own experience)-using VISA bytes to the Serial Port is ' t a good idea also I have found a solution without delay set by the user between the writing and the read operation in the recent previous topics.

    Can you give me an opinion?

    Thnx in advance.

    Use VISARead with a number of bytes to read and a timeout.

    When your data is received it will play instantly. When no data comes in, you will get a time-out error, which you can manage!

  • Bluetooth Serial Port (SPP) on the XOOM profile

    Does anyone has experiences using devices to profile serial port with the XOOM?

    We try to get our through SPP Bluetooth barcode scanner and we had a few problems with the matching.

    We are able to pair our device with the XOOM did very well (using Bluetooth 2.1 Secure Simple pairing (SPP)), however, when we try to open a serial port (RFComm channel), the XOOM is trying to make an increased level of security and enforce Bluetooth man in the middle (MITM) protection.  The problem is that our device does not have ANY screen or buttons that would allow a user to enter the PIN code!

    Anyone tried the "non - ui" SPP BT 2.1 devices with the XOOM?  Such as barcode scanners or GPS units?

    We "got around" this by having our 'claim' device, the pin code has been entered correctly, but this is really just a hack.

    Thanks for any comments.

    Len

    We have solved this problem by using a new call API 2.3 and higher to specifically ask for a link "unauthenticated."

    Socket CHS Series software now fully supports Android 2.3 and features honeycomb (3.x).

    Kind regards

    Len Ott

    Socket Mobile

  • level of tension for the serial port sbRIO

    What are the levels of RS - 232 votage on sbRIO serial ports?  Signal levels might be: 3.3 V, ± 5 V, ± 10 V, ±12 V and ± 15 V?   ±12 v what I often see for a direct connection to the serial port of a PC.

    Hi Matthew,

    The signal levels to the sbRIO-9605/06/23/26/33/36 are ±5V. I took a quick screenshot of TX W.R.T. GND. Tensions in the data sheet the standard ±5.4V (typical) loading with 3 k and a minum of ±5.0V. The RS-232 standard can accept a pretty big swing however (-3V to-25V) and (+ 3V to + 25V) for two levels of logic. The screen was shot I took with a unloadeed line so the voltage levels appear to be higher than most.

    The transceiver set used is the MAX3243.

  • Cannot find driver for PCI serial port

    I just installed a serial PCI on my computer (XP Home SP3) card and can be seen in the Device Manager; but it comes as "PCI Serial Port" under "other devices". When I try to configure it, it tells me that there is no driver available. How to get and install a driver who won't work. I suspect that it is a generic driver (probably vserial.sys) who, for some reason any never was installed in my folder System32. When I try to use my original Windows disks, I said I can't because the files on my computer are newer than those on the disks. Can I not download and install the driver from somewhere on the MS site?

    Thank you, I only wish that the story had a happier ending for you.

  • Serial port communication

    Hello world

    I have a very disputed project.  What I have to do is to transfer a text file from a computer to my laptop with some constraints:

    1. The OS of the computer is just Windows XP Professional (not .NET, no programming language)
    2. It is not allowed to install software or this (working only on this computer) computer programming languages
    3. Some USB and RS-232 ports are available.
    4. No external storage device can be used (e.g. USB stick).

    So, I wonder if there is a way to do it.  For example, we succeed in VBScript or JScript that are available in WIndows XP?  We can transfer the file text on serial port or something (I don't know).

    I'd appreciate if someone could give me some suggestions.

    You can get help with the scripts here: http://social.technet.microsoft.com/Forums/en-US/ITCG/threads

  • NEITHER 9870 Serial Port Communication

    Hello

    I have the module 9870 serial rs232 on 9073 cRIO chassis. I have watched the series loopback example, added to my project, changed the entry node to point to the serial port on the right. It works fine when I use a closure connected the cable to the serial port.

    However, when I connect the port to the serial port on the back of my pc (using the cable series of woman to woman) and run the "Serial Loopback DMA Rd (host) .vi" I see no data being sent on my PC com port hyperterminal. Also if I type any character on hyper terminal I see their receipt by the LabView program.

    Why is this happening? that is, the example works well with a loopback adapter and not when it is connected to other serial port?

    Any help will be appreciated.

    concerning

    Bastien

    Hello

    You have all the details on the cable you are using? You may need a null modem cable.

    All in hyperterminal settings the cRIO? IE: Baud rate/parity/start and stop bits etc.

    Could you take a screenshot of the hyperterminal settings and the windows serial port settings? Could you attach your cRIO VI?

    Thank you very much

  • Close the Bluetooth Serial Port

    If anyone can offer advice regarding some serial Bluetooth using VISA ports near the fence.

    I establish a session series Bluetooth using the Bluetooth Radio software, then move to LabVIEW to control my device via Bluetooth - no problem.

    When I want to stop the connection, I use the command close the visa. When you use the WIDCOMM drivers, the Bluetooth connection is cut using this application.

    However, when I use a device that works the Bluesoleil drivers, the port is left open after the execution of the order closing the visa (and the command does not return an error).

    Everyone knows this?

    Thank you

    SSK

    Hi Ssk,

    I have looked into this for you and have been unable to find a prior occurrence of this behavior, many people have used this driver with LabVIEW without this problem.

    If all goes well a little more information can narrow down the cause.

    Can I ask:

    You use what version of LabVIEW.

    Have you tried several devices that use the Bluesoleil driver?  The behavior is repeatable with each of them?

    Have which devices you tested?

    What driver version are you using?  Have you tried to improve this?

    Thank you

    John

  • Bluetooth Serial Port issues

    Hello world

    Two questions:

    1. I'm accepting an incoming connection from the client BTSPP on my server BTSPP (ConnectionNotifier.acceptAndOpen ()) and then by calling RemoteDevice.getRemoteDevice (.) on the connection that results.  Curiously, although it is supposed to be a BTSPP link, I get IllegalArgumentException as a result of this call.  Clues?  The stack trace includes a code: 0xA030 after the other info.
    2. My Vista box creates two serial for this BTSPP one connection ports.  One is outgoing and one is inbound.  I use one out to talk to the BB from the PC.  Is it possible to turn to the right and use the one entering the BB to talk to the computer?  If so, is there a standard way to do it?

    Thank you

    Jimmy

    Your first point is a known problem when using a StreamConnection from a StreamConnectionNotifier on a connection to the server.  This has been resolved in the version of BlackBerry device software 4.6.0.96 and higher.

    The second point is possible.  There are several ways to do so.  You can use the Connector.open method to open a connection from the BlackBerry to your PC.  Please take a look at the class JavaDocs connector for more information.

  • Resource name unique for each serial port 8431/8?

    Hi all

    I develop test applications using the NI PXI-8431/8 serial interface card.  Because I do not have the hardware, I'm not sure how it will recognize in NOR-MAX, and given that (probably), it will use the generic functions of the series VISA, I can predict no special configuration option (no special driver).  Each of the 8 ports on the map series will appear in NOR-MAX as it is the name of the own resource of individual VISAS, or I have to find another way to tell the difference between channels/ports?  Please notify. Thank you.

    GSinMN

    They will appear as COM ports normal series.  Nothing special.

  • universal serial port communication, I have no idea

    Hi buddies! I'm trying to think about how I can configure VI writing a message on this subject and if possible send it via the USB port on the USB device.

    Please help me with ideas on how to get there as I'm new to LabVIEW

    Hi precious1,.

    What USB device you are trying to use?  What is your application?  How do you control the device?

    As a first step, take a look at the white paper OR to the following address: USB Instrument Control tutorial

    It should help you to configure your USB device for use in a LabVIEW VI.

  • Problem reading data via the Bluetooth Serial Port

    My request is meant to connect with a PC via Bluetooth.

    The PC runs a simple server that reads a string from the BlackBerry UTF and writes a UTF string in response.

    DataInputStream istream = connection.openDataInputStream();DataOutputStream ostream = connection.openDataOutputStream();
    
    System.out.print(istream.readUTF());
    
    ostream.writeUTF("Hello client");ostream.flush();
    
    ostream.close();istream.close();
    

    The sound written BlackBerry pin and reads the answer.

    DataInputStream istream = connection.openDataInputStream();        DataOutputStream ostream = connection.openDataOutputStream();ostream.writeUTF(Integer.toString(DeviceInfo.getDeviceId(), 16));ostream.flush();
    
    _rtf.insert(istream.readUTF());
    
    ostream.close();istream.close();
    

    The server reads and prints the PIN successfully, but the client raise EOFException at readUTF().

    What could be wrong?

    Solved. The server side must not empty its output stream.

  • Communication serial port IRP_MJ_READ

    Hello, I would ask you serial port communication. I am currently apply for communication with my engine not to not (Microcon), but it does not work. If I try to connect with the original software, my serial port monitor gives me values

    IRP_MJ_WRITE when I write some values and

    IRP_MJ_READ when I try to read from the serial port

    But when I'm using LabView, I can only send IRP_MJ_WRITE function by using the component to write VISA (if this one works well), but when I use VISA component read my serial port monitor gives me only IRP_DEVICE_CONTROL. Do you have any sugestion where can be a problem? I don't know how to get this function IRP_MJ_READ using LabView VISA component.

    You watch the using PortMon software? The only thing I see here is that the order that you send, there could be a space that you could have made while typing,

    or

    You're still motor control software running step by step when running the labview? In this case, there will be conflict.

    When you use software original stepper motor and when you send the command wirte down the hexadecimal value (see portmon or any other monitoring software) and try to send back the same hex values using labview. Sending a command, sending of hex are the same but just give it a try,.

    Use bytes depending on the port before VISA to read all available data.

    Search for Microcon network drivers driver Instrument in the Web site OR if you want a quick and simple solution.

Maybe you are looking for

  • How much does it cost to fix the screen Mac airbook?

    MY screen and the glass is cracked. And it's alll white. I was wondering how much it would cost to repair? I got it 3 years ago

  • How to reorganize the playlists on their record?

    How can I reorganize or get an alphabetical sort playlist in a specific folder in Itunes? I feel like it did automatically alphabetize, but lately It added the new playlist last in the folder... ideas? To be precise, I don't speak of reorganization o

  • Disks hard Mac Pro goes wrong in a Bay

    Hello everyone. I have a weird situation here. I have a mac pro with four hard drive bays. I have replaced three hard drives now in one day, two Bay. It cannot be bad three drives in a row. Does anyone have any recommendations why I could eat hard di

  • Save a XY Chart

    It's something I've not done before in LabVIEW, however it seems that it should be simple enough... I am not sure where to start. I'm used to save my data as text files using writing custom file express.vi as well as spreadsheet.vi writing, but now I

  • 488.2 NOR install any failure due to an incomplete uninstall

    I'm trying to uninstall OR 488.2 version 1.74 to replace it with version 3.0.2. After the uninstall is complete, but before I restarted, the computer crashed. Now 488.2 1.74 still appears in the Add/Remove Software dialog box NOR, but I can't remove