This application is based upon and claims the benefit of priority from Japanese Patent Application No. 2003-372992, filed Oct. 31, 2003, the entire contents of which are incorporated herein by reference.
1. Field
This invention relates to an electronic device with a wireless communication module for communicating with another electronic device.
2. Description of the Related Art
Recently, it is common for personal computers and personal digital assistants to support wireless communications with other devices without any required cable connections. One type of communication protocol of the wireless communication function is BLUETOOTH®, which is a well-known, short range radio link.
Devices complying with BLUETOOTH® wireless communication may execute so-called pairing in which addresses and encryption keys are registered between devices often connected to each other. As a result, the devices can exchange data only therebetween, even if multiple pairs of electronic devices are in wireless communications in the same area.
When executing the pairing, first, one electronic device executes a processing called remote device detection. The “remote device detection” involved detecting what responses are generated by dispatching an inquiry electronic wave. The electronic device after executing the remote device detection displays a list of responding devices complying with BLUETOOTH®. If this list is displayed, a user may select a desired communication device to be wirelessly connected from the list and executes a predetermined connecting operation. At this time, if that communication device is provided with security, an input of a personal identification number (hereinafter “PIN”) code is requested.
Recently, the wireless communication function based on the BLUETOOTH® standard has begun to be implemented on a mobile device as small as a display for displaying the list of the devices or a pointing device for selecting a desired communicating party is difficult to implement.
For this reason, Japanese Patent Application Publication (KOKAI) No. 2002-73565 discloses an electronic device provided with a transmitting portion and a receiving portion for transmitting and receiving an infrared light signal so as to exchange a PIN code through the infrared light signal. According to this electronic device, by such a simple operation as pressing switches with the transmitting portion and receiving portion of electronic devices desired to be paired in an opposed state, the pairing processing can be completed.
However, although the method disclosed in the reference does not require any display, pointing device or the like, a necessity of providing an infrared light signal transmitting/receiving portion is generated. Therefore, an electronic device which is demanded to be reduced in size, weight, and price such as a head set is very difficult to adopt such a component.
The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate embodiments of the invention, and together with the detailed description of the embodiments given below, serve to explain the principles of the invention.
Various embodiments according to the present invention will be described hereinafter with reference to the accompanying drawings. In general, according to one embodiment of the invention, an electronic device comprises a speaker, a microphone, and a processor. The processor executes a pairing process with another electronic device and outputs a pairing signal during the pairing process. The electronic device further comprises a converter coupled to the speaker, the microphone, and the processor. The converter converts the pairing signal to an audio signal when the speaker outputs audio signal to another electronic device, and converts an audio signal to a pairing signal when the microphone receives the audio signal. Also, the electronic device includes a wireless communication module coupled to the processor, and it performs wireless communication with another electronic device after the pairing process.
An embodiment of the present invention will be described with reference to the accompanying drawings.
The head set device 1 has two speaker units 11, 12 for the right ear and left ear respectively. The two speaker units 11, 12 are provided on both ends of a head band 13. An end of a microphone arm 14 is attached to the left ear speaker unit 12 and a microphone 15 is provided on the other end of the microphone arm 14. Further, the right ear speaker unit 11 has a power switch 16, while the left ear speaker unit 12 has a green light emitting diode (hereinafter “LED”) 17 and a CALL key 18.
The power switch 16 is a switch for turning ON/OFF the power of the head set device 1. The CALL key 18 is a key for instructing start/end of voice communications with another wireless communication device. In this head set device 1, interpretations about the power switch 16 and CALL key 18 are distinguished depending on whether the power switch 16 and CALL key 18 are pressed longer than a predetermined time (long-time pressing) or shorter than the time (short-time pressing). Although it is permissible to allocate a proper function to any of the long-time pressing and the short-time pressing, here, it is assumed that when both the power switch 16 and the CALL key 18 are pressed in a short time, their proper functions activate. The operation in case of the long-time pressing will be described later.
The head set device 1 comprises the right ear speaker unit 11, left ear speaker unit 12, microphone 15, power switch 16, green LED 17 and CALL key 18 shown in
The BT communication module 101 is a wireless communication module complying with the BLUETOOTH® standard, and executes wireless voice communications based on the aforementioned HSP standard. The CPU 102 controls the entire head set device 1 and executes various programs stored in the main RAM 103. The main RAM 103 stores various programs that the CPU 102 executes and various kinds of data to be used in these programs. The various programs stored in the main RAM 103 contain pairing information 1031 which will be described later. The AD/DA converter 104 converts an analog voice signal inputted through the microphone 15 to a digital signal or converts a digital voice signal to an analog signal, and then outputs the obtained signal from the two speaker units 11, 12.
A main task 201 is a main program for controlling the entire system and provided with a pairing control portion 2011, which will be describe later. A key driver 202 is a device driver for detecting that the power switch 16 and the CALL key 18 are pressed and capable of distinguishing the long-time pressing from the short-time pressing upon the detection. Here, it is assumed that pressing for two or more seconds is detected as the long-time pressing while pressing for less than two seconds is detected as the short-time pressing. The LED driver 203 is a device driver that controls light of the green LED 17.
A BLUETOOTH® protocol stack 204 (hereinafter “BT protocol stack”) is a software module for executing the HSP protocol procedure. An audio input task 205 is a module that processes audio data inputted from the microphone 15 and transmits the audio data to the BT protocol stack 204. An audio output task 206 is a module that processes audio data received from the BT protocol stack 204 and outputs the audio data to the speakers.
A Continuously Variable Slope Delta (CVSD) encoder 207 is a subroutine for converting so-called PCM audio data that undergoes pulse code modulation to CVSD data. The CVSD is a standard audio coding system specified by HSP. A CVSD decoder 208 is a subroutine for converting the CVSD data to PCM audio data. A Dual Tone Multi-Frequency (DTMF) encoder is a subroutine for converting a BLUETOOTH® device address (hereinafter “BD_ADDR”) to a DTMF signal string. The DTMF is a tone signal to be used for a push-button phone. A DTMF encoder 209 is a subroutine for converting the DTMF signal to a BD_ADDR.
Next, the flow of processing in the entire system in the head set device 1 comprised of the above-described hardware configuration and software configuration will be described with reference to
If the power switch 16 is pressed under a state in which power is kept off, this head set device 1 starts up (block A1). After system initialization processing is executed (block A2), the head set device 1 is changed into an HSP waiting state for signal reception (block A3).
With this state, if the CALL key 18 is kept pressed for two seconds or more (block A4), the pairing control portion 2011 issues a blink command to the LED driver 203 so as to start blinking of the green LED 17 to indicate that the DTMF transmission operation is being executed (block AS), and then executes the DTMF transmission operation in which the BD_ADDR stored as pairing information 1031 is converted to DTMF signals and outputted through the speaker units 11, 12 in the form of acoustic signals (block A6).
The pairing control portion 2011, first, issues a DTMF transmission command to the audio output task 206 (block B1) and waits for an end of the DTMF transmission by end event waiting loop (block B2). On the other hand, the audio output task 206 having received this command inquires the BT protocol stack 204 and acquires a BD_ADDR of its own station (block C1). The BD_ADDR (pairing information 1031) is a byte string of 6 bytes and the BT protocol stack 204 reads out this value from the main RAM 103 at startup.
Next, the audio output task 206 converts this BD_ADDR to PCM audio data according to the DTMF rule (block C2). The DTMF contains totally 16 signal patterns. Therefore, the 4-bit information amount can be expressed. The audio output task 206 converts the BD_ADDR, namely 6 bytes or 48 bits, to successive PCM audio data each being 4 bits in size so as to generate a total of 12 DTMF signals.
Then, the audio output task 206 outputs such a generated PCM audio data to the AD/DA converter driver 211. Consequently, the AD/DA converter 211 outputs this PCM audio data to the AD/DA converter 104, so that the DTMF tone is outputted from the speaker units 11, 12 in the form of acoustic signals (block C3). That is, due to the above-described processing, the BD_ADDR is outputted as an acoustic signal in the form of the DTMF tone. After this PCM audio data is outputted to the AD/DA converter driver 211, the audio output task 206 issues a DTMF transmission completion event to the pairing control portion 2011 (block C4). Because the end event waiting loop of block B2 is released due to occurrence of the DTMF transmission completion event, the pairing control portion 2011 returns to the flow shown in
On the other hand, when the power switch 16 is kept pressed for two seconds or more in the HSP waiting state for signal reception (step A8), the pairing control portion 2011 of
The pairing control portion 2011 issues a DTMF reception command to the audio input task 205 (block D1) and waits for an end of the DTMF reception in the end event waiting loop (block D2). On the other hand, after receiving this command, the audio input task 205 instructs the AD/DA converter driver 211 to start fetching of the PCM audio data from the microphone 15 (block E1).
Next, the audio input task 205 detects the DTMF signal according to the DTMF rule from the inputted PCM audio data and converts the signal to corresponding 4-bit data (block E2).
The audio input task 205 records the data acquired by such conversion as a BD_ADDR successively from the upper bit side, and when 6 bytes are formed, the DTMF detection processing is terminated. The 6-byte data generated in this way is registered in the BT protocol stack 204 as a BD_ADDR of a connecting destination (block E3). That is, due to the above-described processing, the acoustic signal is converted to the BD_ADDR and registered in the BT protocol stack 204 as the address of the connecting destination. When this registration ends, the audio input stack 205 issues a DTMF reception completion event to the pairing control portion 2011 (block E4). Because generation of the DTMF reception completion event releases the end event waiting loop in block B2, the pairing control portion 2011 returns to the flow of
In this case, a user positions both head set devices such that the microphone 15 of the head set device (A)1 comes close to, for example, the left ear speaker unit 12 of the head set device (B)1. Therefore, a sound outputted from the left ear speaker unit 12 of the head set device (B)1 enters the microphone 15 of the head set device (A)1.
With this state, the user presses the power switch 16 of the head set device (A)1 for two seconds or more. Consequently, the head set device (A)1 starts the DTMF reception operation. Thereafter, the user presses the CALL key 18 of the head set device (B)1 for two seconds or more. Consequently, the head set device (B)1 starts the DTMF transmission operation.
As a result of the above operation, the BD_ADDR is outputted from the left ear speaker unit 12 as an acoustic signal by the DTMF transmission processing of the head set device (B)1 and the acoustic signal is inputted to the microphone 15 of the head set device (A)1. The acoustic signal is turned to the BD_ADDR by the DTMF reception processing of the head set device (A)1 and set in the BT protocol stack 204. In this way, the BD_ADDR of the head set device (B)1 is set in the BT protocol stack of the head set device (A)1. Subsequently, the user presses the CALL key of the head set device (A)1 for less than two seconds, which enables connection to the head set device (A)1.
Although according to this embodiment, the DTMF system is employed as the acoustic signal, an acoustic signal system other than the DTMF system may be utilized. For example, it is permissible to use voice synthetic recognition, that is, the portion of the DTMF transmission of this embodiment is executed by voice synthesis and the portion of the DTMF reception is executed by voice recognition.
Further, it is possible to apply a method for intensifying reliability by adding an error detecting code for determining presence or absence of an error or an error correction code for correcting an error when the BD_ADDR is converted to the PCM audio data.
The present invention is not restricted to the above-described embodiment, but its composition elements may be modified within a scope not departing from the gist thereof for embodying the invention. Further, by combining the plural composition elements disclosed in the above-described embodiment appropriately, various kinds of inventions may be formed. For example, it is permissible to delete some composition elements indicated in the embodiment. Further, it is permissible to combine the composition elements of different embodiments appropriately.
Additional advantages and modifications will readily occur to those skilled in the art. Therefore, the invention in its broader aspects is not limited to the specific details and representative embodiments shown and described herein. Further, by combining the plural composition elements disclosed in the above-described embodiment appropriately, various kinds of inventions may be formed. For example, it is permissible to delete some composition elements indicated in the embodiment. Further, it is permissible to combine the composition elements of different embodiments appropriately. Accordingly, various modifications may be made without departing from the spirit or scope of the general inventive concept as defined by the appended claims and their equivalents.
Number | Date | Country | Kind |
---|---|---|---|
P2003-372992 | Oct 2003 | JP | national |