Hello, this is a restructuring of a previous post to make clearer my problem(the following exercise in fact). If you have some idea of how can I resolve this with an efficient way(saving bluetooth addresses as quickly as possible), please tell me,
thanks for all, IRobot.

Let S = {M1, M2, ..., Mn} a set of n mobiles with Bluetooth support, located inside a diameter of 10 meters, Mx, My ε S (xy). Develop a MIDlet who will run simultaneously on each mobile during 10 seconds, and its goal is to save the bluetooth address of the major part possible of the S complement respect the mobile the current MIDlet is running over, the main condition is that Mx save the bluetooth address of My if and only if My save the bluetooth address of Mx.

---------

[original exercise]
Sea S = {M1, M2, ..., Mn} un conjunto de n móviles con tecnología Bluetooth, ubicados todos en un diámetro menor a 10 metros, Mx, My ε S (xy). Implementar un MIDlet que se ejecutará simultáneamente en cada uno de los móviles durante un período de 10 segundos, cuyo objetivo final será guardar la dirección bluetooth de la mayor parte posible del complemento de S respecto al móvil donde se ejecuta dicho MIDlet, con la condición de que Mx guarda la dirección de My si y sólo si My guarda la dirección de Mx.

2. Not sure whether I got it, however, this 10 seconds limitation makes the amount of Bluetooth devices rather small.

3. Re: An Exercise about Bluetooth...

I think the time is not the main factor,
the problem is how each pair of mobiles interchange their bluetooth addresses with the assurance of bidirectional interchange.
best regards, IRobot.

4. Making this sure, is quite easy. Just (two phase) commit it. There are zillions of solutions out there in computer science. And yes, the time matters. You will learn or can be learned from literature about Bluetooth inquiry papers.

5. Re: An Exercise about Bluetooth...

Hello Traud, can you tell me one way you think could be the most efficiently please?
I think one solution could be running a server and client(different threads) on each mobile of the set and...

client:
the client starts an inquiry and for each server he found(with blutooth address not saved previously) he connects to a predefined service(made for this purpose), and if the connection is successful, he save the server bluetooth address.

server:
the server save the bluetooth address of each client who connects to him.

I think here I'm assuring the double implication of the exercise.

please if you know a better way, tell me.
thanks for all, IRobot.

(sorry my english)

Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•