Patent Publication Number: US-2018048405-A1

Title: Semiconductor device, radio communication device, and control method for radio communication device

Description:
The present application is a Continuation Application of U.S. patent application Ser. No. 15/069,342, filed on Mar. 11, 2016, which is based on and claims priority from Japanese Patent Application No. 2015-079729, filed on Apr. 9, 2015, the entire contents of which are incorporated herein by reference. 
    
    
     BACKGROUND 
     The present invention relates to a semiconductor device, a radio communication device, and a control method for a radio communication device. For example, the present invention can be suitably applied to a semiconductor device that measures the strength of a received signal (hereinafter referred to as a “received signal strength”), a radio communication device, and a control method for a radio communication device. 
     Recently, radio communication techniques have been used in various electronic apparatuses such as mobile phones, smart phones, IoT (Internet of Things) devices, and wearable devices. As examples of the radio communication techniques, a wireless LAN, Bluetooth (registered trademark), and Zigbee (registered trademark) have been known. 
     Japanese Unexamined Patent Application Publication No. 2006-109323 discloses a related art. In Japanese Unexamined Patent Application Publication No. 2006-109323, power consumption is reduced by controlling a threshold by which a decision on an RSSI (Received Signal Strength Indication) is made. 
     SUMMARY 
     The present inventors have found the following problem. In the related art such as the one disclosed in Japanese Unexamined Patent Application Publication No. 2006-109323, there are cases in which it is very difficult to reduce the consumption power depending on the radio-wave state, such as the presence of interfering radio waves. Therefore, in one embodiment, one of the problems is to reduce the consumption power. 
     Other problems and novel features will be more apparent from the following description in the specification and the accompanying drawings. 
     According to one embodiment, a radio communication device includes an antenna and a semiconductor device. The semiconductor device receives a radio signal through the antenna and measures a received signal strength of the received radio signal. Further, the semiconductor device compares the measured received signal strength with a threshold, demodulates the received radio signal based on a result of the comparison, and sets the threshold according co the measured received signal strength. 
     According to the embodiment, the power consumption can be reduced. 
    
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
       The above and other aspects, advantages and features will be more apparent from the following description of certain embodiments taken in conjunction with the accompanying drawings, in which: 
         FIG. 1  is a configuration diagram showing a configuration of a semiconductor device according to a reference example 1; 
         FIG. 2  is a signal waveform chart showing an operation of the semiconductor device according to the reference example 1; 
         FIG. 3  is a configuration diagram showing a configuration of a semiconductor device according to a reference example 2; 
         FIG. 4  is a signal waveform chart showing an operation of the semiconductor device according to the reference example 2; 
         FIG. 5  is a configuration diagram showing an outline of a semiconductor device according to an embodiment; 
         FIG. 6  is a configuration diagram showing a configuration of a radio communication system according to a first embodiment; 
         FIG. 7  is a configuration diagram showing a configuration of a semiconductor device according to the first embodiment; 
         FIG. 8  shows an example of a power threshold table according to the first embodiment; 
         FIG. 9  is a flowchart showing an operation of the semiconductor device according to the first embodiment; 
         FIG. 10  is a signal waveform chart showing an operation of the semiconductor device according to the first embodiment; 
         FIG. 11  is a state machine diagram showing state transitions of a semiconductor device according to a second embodiment; 
         FIG. 12  shows an example of a power threshold table according to the second embodiment; 
         FIG. 13  is a flowchart showing an operation of the semiconductor device according to the second embodiment; 
         FIG. 14  is a flowchart showing an operation of the semiconductor device according to the second embodiment; 
         FIG. 15  is a configuration diagram showing a configuration of a semiconductor device according to a third embodiment; 
         FIG. 16  shows an example of a control table according to the third embodiment; and 
         FIG. 17  is a flowchart showing an operation of the semiconductor device according to the third embodiment. 
     
    
    
     DETAILED DESCRIPTION 
     For clarifying the explanation, the following descriptions and the drawings may be partially omitted and simplified as appropriate. Further, each of the elements that are shown in the drawings as functional blocks for performing various processes can be implemented by hardware such as a CPU, a memory, and other types of circuits, or implemented by software such as a program loaded in a memory. Therefore, those skilled in the art will understand that these functional blocks can be implemented solely by hardware, solely by software, or a combination thereof. That is, they are limited to neither hardware nor software. Note that the same symbols are assigned to the same components throughout the drawings and duplicated explanations are omitted as required. 
     (Examination Leading to Embodiment) 
     Recently, research on perform radio communication with lower power consumption has been underway. For example, Bluetooth Low Energy (BLE), which consumes lower power, has been standardized as the new Bluetooth standard. Further, IoT devices and wearable devices have been receiving attention. As the sizes of such devices have been increasingly reduced, it has been strongly desired to reduce the power requirement in order to reduce the trouble of replacing batteries and/or recharging batteries. Therefore, firstly, reference examples 1 and 2, to which an embodiment according to an embodiment is not applied, are examined. 
     The reference example 1 is an example in which demodulation starts when the RSSI of a received signal exceeds a threshold.  FIG. 1  shows a configuration of a semiconductor device  900  according to the reference example 1. The semiconductor device  900  is a radio receiver that receives a radio signal. As shown in  FIG. 1 , the semiconductor device  900  according to the reference example 1 includes a quadrature conversion circuit  101 , an ADC (Analog-to-Digital Converter)  102 , an RSSI measurement unit  103 , a threshold comparison unit  104 , and a demodulation unit  105 . 
     An antenna  111  supplies a received radio signal RF to the semiconductor device  900 . The quadrature conversion circuit  101  generates a quadrature signal IQ based on the radio signal RF and the ADC  102  generates an ADC output code ADOUT based on the quadrature signal IQ. The RSSI measurement unit  103  measures the strength SI of a received electric field (hereinafter referred to as a “received electric field strength SI”) of the radio signal RF based on the ADC output code ADOUT. The threshold comparison unit.  104  compares the received electric field strength SI with a power threshold TH and outputs a receiving start signal SA according to the comparison result. The demodulation unit  105  demodulates the ADC output code ADOUT according to (or in response to) the receiving start signal BA. 
       FIG. 2  is a signal waveform chart showing an operation example of the semiconductor device  900  according to the reference example 1.  FIG. 2  shows signal waveforms of the radio signal RF, the ADC output code ADOUT, the power threshold TH and the received electric field strength SI, and the receiving start signal SA. In  FIG. 2 , the horizontal axis of each of these charts indicates the lapse of time. Further, the vertical axes of the radio signal RF, the ADC output code ADMIT, the power threshold TH and the received electric field strength SI, and the receiving start signal. BA indicate voltage levels (V), code values (CODE), power dBm, and high (H)/low (L) levels, respectively. In this example, radio signals RF 1 , RF 2  and RF 3  are received one after another at regular intervals in periods T 2 , T 4  and T 6 , respectively, and an interfering radio-wave signal ITF 1  is received in a period between the receptions of the received signals RF 2  and RF 3 . 
     Since no radio signal is received in periods T 1 , T 3  and T 7 , the received electric field strength SI is lower than the power threshold TH in these periods Therefore, the threshold comparison unit  104  sets the receiving start signal SA to a low level and the demodulation unit  105  performs no demodulation operation. Further, the received signals RF 1 , RF 2  and RF 3  are received in the periods T 2 , T 4  and T 6 , respectively, and hence the received electric field strength SI is higher than the power threshold TH in these periods. Therefore, the threshold comparison unit  104  sets the receiving start signal SA to a high level and the demodulation unit  105  starts (i.e., performs) a demodulation operation. 
     In the semiconductor device  900  according to the reference example 1, the power threshold TH is a permanently fixed value. Therefore, when the semiconductor device  900  receives the interfering radio-wave signal ITF 1  in a period T 5   a  in the period T 5 , the received electric field strength SI becomes larger than the power threshold TH. As a result, the threshold comparison unit  104  sets the receiving start signal SA to a high level and the demodulation unit  105  starts (i.e., performs) demodulation for the interfering radio-wave signal ITF 1 . 
     Therefore, there is a problem in the reference example 1, in which the power threshold TH is fixed, that when an interfering radio-wave signal is received, the demodulation unit  105  starts a demodulation operation and hence the current consumption (power consumption) increases in the demodulation unit  105 . Further, if the demodulation of a normal received signal (such as the received signal RF 3 ) ends in failure due to the influence of an interfering radio-wave signal, the transmission side performs the transmission process again, thus further increasing the current consumption. 
     In contrast to this, the reference example 2 is an example in which a threshold by which a decision on the RSSI of a received signal is made is controlled according to a demodulation result of a received signal.  FIG. 3  shows a configuration of a semiconductor device  901  according to the reference example 2. As shown in  FIG. 3 , the semiconductor device  901  according to the reference example 2 includes a control unit  906  in addition to the configuration of the reference example 1 shown in  FIG. 1 . 
     In the reference example 2, the demodulation unit  105  outputs an error detection result FL (flag) indicating whether or not there is an error in a demodulation result of a received signal. The control unit  906  estimates a radio-wave state based on the error detection result FL, and raises the power threshold TH when the interfering radio wave is estimated to be large and lowers the power threshold TH when the interfering radio wave is estimated to be small. By doing so, the control unit  906  prevents the threshold comparison unit  104  from mistakenly detecting an interfering radio wave as being a normal received signal. 
       FIG. 4  is a signal waveform chart showing an operation example of the semiconductor device  901  according to the reference example 2. Similarly to  FIG. 2 , in the example shown in  FIG. 4 , radio signals RF 1 , RF 2  and RF 3  are received one after another at regular intervals in periods T 2 , T 4  and T 6 , respectively, and an interfering radio-wave signal ITF 1  is received in a period between the receptions of the received signals RF 2  and RF 3 . 
     In the semiconductor device  901  according to the reference example 2, the power threshold is determined by using the error detection result FL. Therefore, when no error occurs in the received signals RF 1  and RF 2  in the periods T 2  and T 4 , respectively, in which there is no interfering radio-wave signal, the power threshold TH is gradually lowered. When an interfering radio-wave signal is received in a period T 5   a  in the period T 5  after the power threshold TH is lowered, the received electric field strength SI of the interfering radio-wave signal ITF 1  received at the antenna becomes larger than the power threshold TH. Therefore, the threshold comparison unit  104  sets the receiving start signal SA to a high level and the demodulation unit  105  starts the demodulation of the interfering radio-wave signal ITF 1 . 
     Therefore, even in the reference example 2, in which the power threshold TH is controlled according to the demodulation result, there is a problem that when an interfering radio-wave signal is received, the demodulation unit  105  starts a demodulation operation and hence the current consumption is increased, as in the case of the reference example 1. 
     Note that the characteristic of the reference example 2 is expected to significantly improve under the condition that interfering radio waves occur continuously over time and their power is substantially unchanged. However, communication methods which could cause interfering radio waves, such as a wireless LAN, Bluetooth, and Zigbee, are packet communication methods. Therefore, they cause interfering radio waves that are discontinuous on a packet-by-packet basis. Further, the power of received interfering radio waves changes as the terminal that is outputting the interfering radio wave moves. It can be said that since the reference example 2 has a configuration in which the power threshold for the next reception is changed based on the result of the error detection result FL having a binary value (i.e., based on the presence/absence of an error), the appropriate power threshold could change between when the power threshold is determined and when a received signal is received due to the change in the power of the interfering radio wave over time, thus causing the receiving circuit to mistakenly start up due to the interfering radio wave and thereby causing an increase in the current consumption and deterioration in the reception characteristic. 
     Outline of Embodiment 
       FIG. 5  shows an example of an outline of a semiconductor device according to an embodiment. As shown in  FIG. 5 , a semiconductor device  10  according to an embodiment includes a receiving unit  11 , a received signal strength measurement unit  12 , a threshold comparison unit  13 , a demodulation unit  14 , and a threshold setting unit  15 . 
     The receiving unit  11  receives a radio signal and the received signal strength measurement unit  12  measures the received signal strength of the radio signal received by the receiving unit  11 . The threshold comparison unit  13  compares the received signal strength measured by the received signal strength measurement unit  12  with a threshold and the demodulation unit  14  demodulates the radio signal received by the receiving unit  11  based on the result of the comparison performed by the threshold comparison unit  13 . Further, the threshold setting unit  15  sets the threshold in the threshold comparison unit  13  according to the received signal strength measured by the received signal strength measurement unit  12 . 
     As described above, in the embodiment, the threshold by which the start of demodulation is determined is set (i.e., changed) according to the received signal strength of the received radio signal. In this way, since an appropriate threshold can be set according to the received signal strength, it is possible to prevent a false operation that would otherwise occur when an interfering radio wave is received and thereby to reduce the power consumption. 
     First Embodiment 
     A first embodiment is explained hereinafter with reference to the drawings. 
     &lt;Configuration of Radio Communication System&gt; 
       FIG. 6  shows a configuration example of a radio communication system  200  according to this embodiment. As shown in  FIG. 6 , the radio communication system  200  according to this embodiment includes radio communication devices  210  and  220 . The radio communication system  200  is an example in which an embodiment is applied to an activity meter application. Note that the embodiment can be applied to an application other than the activity meter application, provided that the application can perform a radio communication such as Bluetooth. 
     The radio communication device  210  is an active meter module such as a pedometer and transmits the detected number of steps to the radio communication device  220 . The radio communication device  220  is a display module such as a smart phone and displays the number of steps received from the radio communication device  210 . For example, in the case of adopting Bluetooth as its communication method, the radio communication device  220  serves as a master device and the radio communication device  210  serves as a slave device. One radio communication device  220  (master device) may be wirelessly connected to one radio communication device  210  (slave device). Alternatively, one radio communication device  220  may be wirelessly connected to a plurality of radio communication devices  210 . 
     The radio communication device  210  includes an antenna  111   a , a semiconductor device  100   a , and an acceleration sensor  211 . The semiconductor device  100   a  includes an RF circuit.  110   a , an MCU  120   a , and an ADC  130 . 
     In the radio communication device  210 , the acceleration sensor  211  detects an acceleration and generates an acceleration voltage according to the detected acceleration. The ADC  130  converts the analog acceleration voltage generated by the acceleration sensor  211  into a digital signal and thereby generates digital acceleration data (code). The MCU  120   a  generates a packet (transmission data) to be transmitted based on the acceleration data generated by the ADC  130 . The RF circuit  110   a  modulates the packet (transmission data) generated by the MCU  120  and transmits the modulated signal to the radio communication device  220  through the antenna  111   a . Further, the RF circuit  110   a  receives a radio signal transmitted from the radio communication device  220  through the antenna  111   a  and demodulates the received radio signal and thereby obtains a packet (received data). The MCU  120   a  performs a necessary process based on the packet (received data) demodulated (i.e., obtained) by the RF circuit  110   a.    
     The radio communication device  220  includes an antenna  111   b , a semiconductor device  100   b , a driver IC  221 , and a display  222 . The semiconductor device  100   b  of the radio communication device  220  includes an RF circuit  110   b  and an MCU  120   b.    
     In the radio communication device  220 , the RF circuit  1104  receives a radio signal transmitted from the radio communication device  210  through the antennal  111   b  and demodulates the received radio signal and thereby obtains a packet (received data). The MCU  120   b  acquires acceleration data based on the packet (received data) demodulated (i.e., obtained) by the RF circuit  110   b . Further, the MCU  120   b  outputs the acquired acceleration data to the display  222  through the driver IC  221 , and the display  222  displays the acceleration data (measured activity quantity). 
     The semiconductor devices  100   a  and  100   b  (either of them is also referred to as a “a semiconductor device  100 ”) of the radio communication devices  210  and  220 , respectively, are semiconductor devices similar to each other, and serve as radio communication units that perform radio communication in accordance with a radio communication standard such as Bluetooth, a wireless LAN, and Zigbee. As an example, the semiconductor device  100   b  shown in  FIG. 6 , which has an MCU function and an RF function, may have other functions according to the need. Similarly, the semiconductor device  100   a , which has an MCU function, an RF function, and an ADC function, may have other functions according to the need. 
     In this embodiment, in the semiconductor device  100   a  of the radio communication device  210  (e.g., the slave device), a distance between the radio communication devices  210  and  220  is estimated based on an RSSI measurement result that is obtained when the radio communication device  210  communicates with the radio communication device  220 . Then, an optimal parameters) is determined according to the estimated distance by using a table or a calculation formula included, in software of the MCU  120   a  and the determined parameter(s) is set in the RF circuit  110   a  (such as a register). 
     In this embodiment, the optimal parameter is a threshold by which an RSSI, which is used to trigger demodulation, is determined. Note that as described in a later-shown embodiment, the optimal parameter may include a transmission power setting and/or a reception gain setting. When the distance is short, the transmission power and/or the reception gain can be reduced and the power consumption of the RF circuit  110  is thereby reduced. On the other hand, when the distance is long, the communication available distance can be increased by increasing the transmission power and/or the reception gain. 
     Note that similarly to the semiconductor device  100   a  of the radio communication device  210 , a parameters) may be controlled according to the distance (RSSI) in the semiconductor device  100   b  of the radio communication device  220  (e.g., the master device). For example, when the radio communication device  220  communicates with a plurality of radio communication devices  210 , the radio communication device  220  may set a parameters) for each of the radio communication devices  210  according to its distance (RSSI). 
     &lt;Configuration of Semiconductor Device&gt; 
       FIG. 7  shows a configuration example of a semiconductor device  100  (the semiconductor device  100   a  or  100   b  shown in  FIG. 6 ) according to this embodiment.  FIG. 7  mainly shows a configuration of a signal receiving unit of the semiconductor device  100 , which is a configuration of a receiver of the radio communication device. As shown in  FIG. 7 , the semiconductor device  100  according to this embodiment includes a quadrature conversion circuit  101 , an ADC  102 , an RSSI measurement unit  103 , a threshold, comparison unit  104 , a demodulation unit  105 , and a control unit  106 . The configuration shown in  FIG. 7  differs from the configuration of the reference example 2 shown in  FIG. 3  in that the received electric field strength SI is also supplied from the RSSI measurement unit  103  to the control unit  106 . Note that although  FIG. 7  shows a Zero-IF type receiving architecture as an example, other receiving architectures such as a Low-IF type receiving architecture may be used. Further, although the IQ-separation is performed in the analog part (analog circuit) as an example in  FIG. 7 , the IQ-separation may be performed in the digital part (digital circuit) Still further, although the RSSI measurement unit  103  formed by a digital circuit as an example in  FIG. 7 , the RSSI measurement unit  103  may be formed by an analog circuit. 
     For example, the RF circuit  110  (the RF circuit  110   a  or  110   b ) shown in  FIG. 6  includes the quadrature conversion circuit  101 , the ADC  102 , the RSSI measurement unit  103 , the threshold comparison unit  104 , and the demodulation unit  105 . Meanwhile, the MCU  120  (the MCU  120   a  or  120   b ) shown in  FIG. 6  includes the control unit  106 . The control unit  106  is implemented by having the MCU  120  execute a program. 
     The quadrature conversion circuit  101  performs a quadrature conversion on a radio signal RF received by the antenna  111  (the antenna  111   a  or  111   b ) and thereby generates a quadrature signal IQ. The ADO  102  converts the analog quadrature signal IQ generated by the quadrature conversion circuit  101  into a digital signal and thereby generates an ADC output code ADOUT. The RSSI measurement unit  103  measures the received electric field strength SI of the received radio signal RF based on the ADC output code ADOUT output from the ADC  102 . 
     The threshold comparison unit  104  compares the received electric field strength SI measured by the RSSI measurement unit  103  with a power threshold. TH and outputs a receiving start signal. SA according to the comparison result. The demodulation unit  105  demodulates the ADC output code ADOUT output from the ADC  102  according to (or in response to) the receiving start signal. SA output from the threshold comparison unit  104 . The threshold comparison unit.  104  compares the magnitude of the received electric field strength SI with the power threshold TH. When the received electric field strength SI becomes larger than the power threshold TH, the threshold comparison unit  104  determines that the semiconductor device  100  has received a packet and hence outputs the receiving start signal SA. Further, the demodulation unit  105  starts demodulation according to (or in response to) the receiving start signal SA. The control unit (threshold setting unit)  106  determines the power threshold TH according to the received electric field strength SI measured by the RSSI measurement unit  103  and sets the determined power threshold TH in the threshold comparison unit  104 . Further, the control unit  106  determines whether the power threshold TH should be controlled (i.e., changed) or not based on the error detection result FL, which is the demodulation result of the demodulation unit  105 . 
     &lt;Details of Control Unit&gt; 
     The control unit  106  determines the power threshold TH, which is used to determine the next packet reception, according to the received electric field strength SI in the current packet reception. For example, the control unit  106  stores a power threshold table in a memory (table storage unit) or the like in advance and sets the power threshold TH according to the received electric field strength SI based on the stored power threshold table. 
       FIG. 8  shows an example of the power threshold table according to this embodiment. As shown in  FIG. 8 , a power threshold table  106   a  associates received electric field strengths SI, which are input to the control unit  106 , with power thresholds TH, which are output from the control unit  106 . That is, the power threshold table  106   a  associates measured electric field strengths SI with power thresholds TH to be set. 
       FIG. 8  shows an example in which the power threshold TH to be set has three levels. The control unit  106  outputs −60 dBm as a power threshold TH to be set when the received electric field strength SI is equal to or larger than −39 dBm, outputs −95 dBm as a power threshold TH to be set when the received electric field strength SI is equal to or smaller than −90 dBm, and outputs −90 dBm as a power threshold TH to be set when the received electric field strength SI is in a range between −40 dBm and −89 dBm. For example, in the example shown in  FIG. 8 , it can be said that the received electric field strength SI is compared with the threshold by using the reference values −40 dBm and −90 dBm as thresholds (i.e., as setting determination thresholds that are used to set the power threshold TH). When the received electric field strength SI is smaller than −90 dBm, the power threshold TH is set to −95 clan (first threshold) When the received electric field strength SI is larger than −40 dBm, the power threshold TIS is set to −60 dBm (second threshold larger than the first threshold). By doing so, when the received electric field strength SI is large (the distance is short), the power threshold TH is increased and the influence of interfering radio waves is thereby prevented or suppressed. 
     Note that the received electric field strength values and the power threshold values in the power threshold table  106   a  shown in  FIG. 8  are merely examples and they may be changed. Further, although a relation between three power thresholds and three received electric field strengths is shown in  FIG. 8 , the number of power thresholds may be arbitrarily determined. For example, the number of power thresholds may be two or more than three. Further, the power threshold may be determined by using a calculation formula (program) instead of using the table shown in  FIG. 8 . 
     &lt;Detail of RSSI Measurement Unit&gt; 
     The RSSI measurement unit  103  estimates (measures) a received electric field strength (received signal strength) by performing, for example, a calculation shown by the below-shown Expression (1) In Expression (1), RSSI represents a received electric field strength and its unit is dBm. Further, n is the number of RSSI calculation data pieces; ARCO is an ADC output code ADOUT; ADC 0 dBm  is an ADC output code when 0 dBm is input to the ADC  102 ; and RFgain is a dB value of the gain of the quadrature conversion circuit  101 . In Expression (1), an average value of received electric field strengths over a certain period is obtained by dividing the sum total of n ADCO by n ADC 0 dBm . The RSSI measurement unit  103  obtains an average value of received electric field strengths for each received signal (for each packet) by using Expression (1). 
     
       
         
           
             
               
                 
                   [ 
                   
                     Expression 
                      
                     
                         
                     
                      
                     1 
                   
                   ] 
                 
               
               
                 
                     
                 
               
             
             
               
                 
                   RSSI 
                   = 
                   
                     
                       20 
                        
                       
                           
                       
                        
                       log 
                        
                       
                         
                           ( 
                           
                             
                               ∑ 
                               
                                 k 
                                 = 
                                 1 
                               
                               n 
                             
                              
                             
                                
                               
                                 ADCO 
                                 k 
                               
                                
                             
                           
                           ) 
                         
                         
                           n 
                           × 
                           
                             ADC 
                             
                               0 
                                
                               
                                   
                               
                                
                               dBm 
                             
                           
                         
                       
                     
                     - 
                     
                       RF 
                        
                       
                           
                       
                        
                       gain 
                     
                   
                 
               
               
                 
                   ( 
                   1 
                   ) 
                 
               
             
           
         
       
     
     Further, when the output of the quadrature conversion circuit  101  is a complex output, the RSSI measurement unit  103  estimates (measures) a received electric field strength by performing a calculation shown by the below-shown Expression (2). In Expression (2), ADCOI and ADCOQ are I component and Q component, respectively, of an ADC output code. 
     
       
         
           
             
               
                 
                   [ 
                   
                     Expression 
                      
                     
                         
                     
                      
                     2 
                   
                   ] 
                 
               
               
                 
                     
                 
               
             
             
               
                 
                   RSSI 
                   = 
                   
                     
                       20 
                        
                       
                           
                       
                        
                       log 
                        
                       
                         
                           
                             ∑ 
                             
                               k 
                               = 
                               1 
                             
                             n 
                           
                            
                           
                             
                               
                                 ADCOI 
                                 2 
                               
                               + 
                               
                                 ADCOQ 
                                 2 
                               
                             
                           
                         
                         
                           n 
                           × 
                           
                             ADC 
                             
                               0 
                                
                               dBm 
                             
                           
                         
                       
                     
                     - 
                     RFgain 
                   
                 
               
               
                 
                   ( 
                   2 
                   ) 
                 
               
             
           
         
       
     
     &lt;Relation Between Received Electric Field Strength and Communication Distance&gt; 
     Base on the fact that a propagation loss in a free space is in proportion to the square of a frequency and in proportion to the square of a communication distance, the relation between the received electric field strength and the communication distance is expressed by the below-shown Expression (3), where: RXPOW [dBm] is a received electric field strength; TXPOW [dBm] is transmission power; f [MHZ] is a carrier frequency; and d [m] is a communication distance. 
         RXPOW=TXPOW− 20 log( f )−20 log( d )+27.6  (3)
 
     That is, the communication distance between a transmitter and a receiver (between radio communication devices) can be calculated by substituting a received electric field strength into Expression (3). 
     In this embodiment, the power threshold TH for the next packet reception is determined mainly based on the received electric field strength SI. However, since the received electric field strength has a relation with the communication distance, it can be said that the power threshold TH is determined based on the communication distance. 
     That is, the control unit  106  may calculate the communication distance from the measured received electric field strength SI by using Expression (3) and set the power threshold TH according to the calculated communication distance. For example, the power threshold table  106   a  shown in  FIG. 8  may be replaced by a table recording communication distances. That is, communication distances may be associated with power thresholds TH. Then, when the communication distance is equal to or shorter than 1 m, the power threshold TH is set to −60 dBm. When the theoretical value for the communication distance according to Expression (3) is equal to or longer than 320 m (or when the communication distance in the real space is equal to or longer than 10 in), the power threshold TH is set to −95 dBm. Further, when the communication distance is in a range between 1 m and 320 in, the power threshold TH is set to −90 dBm. 
     &lt;Operation Flow of Semiconductor Device&gt; 
       FIG. 9  is a flowchart showing an operation of the semiconductor device  100  according to this embodiment.  FIG. 9  shows an operation corresponding to the example of the power threshold table  106   a  shown in  FIG. 8 . 
     Firstly, steps S 1  and S 2  show an operation that is performed when the semiconductor device  100  is waiting for a radio signal. In the step S 1 , when the antenna  111  receives a radio signal, the quadrature conversion circuit  101  performs a quadrature conversion on the received radio signal RF. Further, the ADC  102  converts the quadrature-converted analog quadrature signal IQ into a digital signal and the RSSI measurement unit  103  performs an RSSI calculation based on an ADC output code ADOUT obtained by the AD conversion. That is, the RSSI measurement unit  103  calculates a received electric field strength by using the above-shown Expression (1) or (2) and outputs an received electric field strength SI, which is the result of the received electric field strength estimation, to the threshold comparison unit  104 . 
     In the step S 2 , the threshold comparison unit  104  compares the magnitude of the received electric field strength SI with a power threshold TN, i.e., determines whether or not the received electric field strength SI is larger than the power threshold TN. When the received electric field strength SI is equal to or smaller than the power threshold TH in the step S 2 , the process returns to the step S 1 , in which the semiconductor device  100  waits for a radio signal and have the RSSI measurement unit  103  estimate a received electric field strength again. When the received electric field strength SI is equal to or smaller than the power threshold TN, the threshold comparison unit  104  maintains the receiving start signal SA, which is output by the threshold comparison unit  104 , at the low level. Therefore, the demodulation unit  105  does not perform demodulation. 
     Further, in the step S 2 , when the received electric field strength SI is larger than the power threshold TH, the process proceeds to a step S 3  and the demodulation unit  105  starts demodulating the received signal. That is, when the received electric field strength SI is larger than the power threshold TH, the threshold comparison unit  104  changes the receiving start signal SA, which is output by the threshold comparison unit  104 , to a high level and hence the demodulation unit  105  starts demodulating the received signal according to (or in response to) the receiving start signal SA. 
     Next, steps S 3  and S 4  show an operation that is performed when the demodulation unit.  105  demodulates a received signal. In the step S 3 , the demodulation unit  105  demodulates the ADC output code ADOUT (received signal) output from the ADC  102 . The demodulation unit  105  demodulates the received signal and detects, if any, an error in the demodulated data (packet) (i.e., data (packet) obtained by the demodulation) by performing a CRC calculation thereof. For example, in the case of Bluetooth Low Energy, a packet includes a preamble, an access address, payload data (PDU), and a CRC (Cyclic Redundancy Check). Therefore, the demodulation unit  105  performs the CRC calculation based on the access address and the payload data of the demodulated packet. 
     In the step  34 , the demodulation unit  105  makes a decision on the error detection result obtained by the CRC calculation. That is, the demodulation unit  105  compares the CRC calculation result obtained in the step S 3  with a CRC included in the demodulated data (packet). Then, when they match each other (CRC=OK), the demodulation unit  105  determines that there is no error in the demodulated data. On the other hand, when they do not match each other (CRC=NG), the demodulation unit  105  determines that there is an error(s) in the demodulated data. The demodulation unit  105  outputs the presence/absence of an error as an error detection result FL. That is, when there is an error in the demodulated data, the process returns to the step S 1  without changing the power threshold TH and the semiconductor device  100  waits for a radio signal. On the other hand, when there is no error in the demodulated data, the process proceeds to a step S 5  and the control unit  105  sets (i.e., changes) the power threshold TH. By maintaining the power threshold when there is an error and setting (i e, changing) the power threshold when there is no error, the influence of interfering radio waves on the power threshold can be prevented or suppressed. 
     Next, steps S 5  to S 9  show a power threshold setting flow in this embodiment. Similarly to the power threshold table  106   a  shown in  FIG. 8 , in this example, when the received electric field strength SI is larger than −40 dBm (or equal to or larger than −39 dBm) the control unit  106  sets the power threshold. TH for the next reception to −60 dBm. When the received electric field strength SI is smaller than −90 dBm (or equal to or smaller than −90 dBm) the control unit  106  sets the power threshold TH for the next reception to −95 dBm. Further, when the received electric field strength SI is no larger than −40 dBm and no smaller than −90 dBm (or in a range between −40 dBm and −89 dBm), the control unit  106  sets the power threshold TH for the next reception to −90 dBm. 
     In a step S 5 , the control unit  106  determines whether or not the received electric field strength SI is larger than −40 dBm. Then, when the received electric field strength SI is larger than −40 dBm, the control unit  106  sets the power threshold TH to −60 dBm and sets it in the threshold comparison unit  104  in a step S 7 . When the received electric field strength SI is equal to or smaller than −40 dBm in the step S 5 , the control unit  106  determines whether or not the received electric field strength SI is smaller than −90 dBm in the step S 6 . Then, when the received electric field strength SI is smaller than −90 dBm, the control unit  106  sets the power threshold TH to −95 dBm and sets it in the threshold comparison unit  104  in a step S 8 . On the other hand, when the received electric field strength SI is equal to or larger than −90 dBm in the step S 6 , the control unit  106  sets the power threshold TH to −90 dBm and sets it in the threshold comparison unit  104  in a step S 9 . 
     After setting the power threshold TH in the steps S 7  to S 9 , the process returns to the step S 1 , in which the semiconductor device  100  waits for a radio wave again and determines a received electric field strength by using the set power threshold TH. 
     Note that in the flow shown in  FIG. 9 , only when there is no error in the CRC calculation result in the step S 4 , the power threshold TH is set in the step S 5  and the subsequent steps. However, the step S 4  may be omitted. That is, the power threshold TH may be set by unconditionally performing the processes in the step S 5  and the subsequent steps after the demodulation is completed. Further, the operation flow from the step S 1  to the step S 9  may be implemented by a circuit (hardware) or may be implemented by software. 
     &lt;Operation Waveform of Semiconductor Device&gt; 
       FIG. 10  shows an example of waveforms of an operation according to this embodiment explained above with reference to the flowchart shown in  FIG. 9 . Similarly to the reference examples shown in  FIGS. 2 and 4 , changes in each signal are shown on the time base. Radio signals RF 1 , RF 2  and RF 3  are received at regular intervals in periods T 2 , T 4  and T 6 , respectively, and an interfering radio-wave signal ITF 1  is received in a period between the receptions of the received signals RF 2  and RF 3 . 
     The operation waveforms shown in  FIG. 10  are explained with reference to steps in the flowchart shown in  FIG. 9 . Firstly, in a period T 1 , since no signal is received at the antenna  111  (i.e., there is no signal), the levels of the radio signal RF output from the antenna  111  and the ADC output code ADOUT output from the ADC  102  do not change. Therefore, when the RSSI measurement unit  103  calculates an RSSI (step S 1 ), the resulting received electric field strength SI is smaller than the power threshold TH (step S 2 ). As a result, the receiving start signal SA remains at the low level and the demodulation unit  105  does not start demodulation. That is, the demodulation is in a stopped state. 
     Next, in a period T 2 , when the antenna  111  receives a received signal RF 1  (packet), the levels of the radio signal RF and the ADO output code ADOUT change according to the received signal RF 1 . Therefore, when the RSSI measurement unit  103  calculates an RSSI (step S 1 ) the resulting received electric field strength SI becomes larger than the power threshold TH (step S 2 ) As a result, the receiving start signal SA becomes a high level and the demodulation unit  105  starts the demodulation of the received signal RF 1  (step S 3 ). When the demodulation of the received signal RF 1  is completed, the receiving start signal SA is returned to a low level and the demodulation unit  105  stops the demodulation. Further, the control unit  106  checks whether there is no error in the demodulation result by using (i.e., performing) a CRC calculation. Here, assume that there is no error in the demodulation result. Then, the control unit  106  sets the power threshold TH for the next reception (steps S 7  to S 9 ) according to the received electric field strength SI of the received signal RF 1  (steps S 5  and S 6 ) and returns to the radio-signal waiting state (step S 1 ). For example, in a period T 2 , since the received electric field strength SI of the received signal RF 1  is smaller than −90 dBm (steps S 5  and S 6 ), the power threshold TH is set to −95 dBm (i.e., the threshold does not change) (step S 8 ). 
     Next, in a period T 3 , no signal is received at the antenna  111  as in the case of the period T 1 . Therefore, when the RSSI measurement unit  103  calculates an RSSI (step S 1 ), the resulting received electric field strength SI is smaller than the power threshold TH (step S 2 ) and the demodulation unit  105  remains in the demodulation stopped state. 
     Next, in a period T 4 , the antenna  111  receives a received signal RF 2  as in the case of the period T 2 . Therefore, when the RSSI measurement unit  103  calculates an RSSI (step S 1 ), the resulting received electric field strength SI becomes larger than the power threshold TH (step S 2 ) As a result, the demodulation unit.  105  performs the demodulation of the received signal RF 2  (steps S 3  and S 4 ) and the control unit  106  sets the power threshold TH for the next reception (steps S 7  to S 9 ) according to the received electric field strength SI of the received signal RF 2  (steps S 5  and S 6 ). For example, in the period T 4 , since the received electric field strength SI of the received signal RF 2  is larger than −40 dBm (step S 5 ), the power threshold TH is set to −60 dBm (i.e., the threshold is raised) (step S 7 ). 
     Next, in the first half of a period T 5 , since no signal is received at the antenna  111  as in the case of the periods T 1  and T 3 , demodulation is not started. When the antenna  111  receives an interfering radio-wave signal ITF 1  in the second half T 5   a  of the period T 5 , the levels of the radio signal RF and the ADC output code ADOUT change according to the interfering radio-wave signal ITF 1  However, the power threshold TH was set to a high value, i.e., −60 dBm in the period T 4 . Therefore, even when the interfering radio-wave signal ITF 1  is received, the received electric field strength SI, which is obtained as a result of the RSSI calculation performed by the RSSI measurement unit  103  (step S 1 ), is smaller than the power threshold TH (step S 2 ) Therefore, even when the interfering radio-wave signal ITF 1  is received by the antenna  111  in the step S 1 , the receiving start signal SA remains at the low level and demodulation is not started. 
     Next, in a period T 6 , when the antenna  111  receives a received signal RF 3  as in the case of the periods T 2  and T 4 , the received electric field strength SI becomes larger than the power threshold TH and the control unit  106  sets the power threshold TB for the next reception (steps S 7  to S 9 ) according to the received electric field strength SI of the received signal RF 3  (steps S 5  and S 6 ). For example, in the period T 6 , since the received electric field strength SI of the received signal RF 3  is smaller than −90 dBm (steps S 5  and S 6 ), the power threshold TN is set to −95 dBm (i.e., the threshold is lowered) (step S 8 ). In a step T 7 , demodulation is not started as in the case of the periods T 1  and T 3 . 
     &lt;Advantageous Effect of this Embodiment&gt; 
     As described above, in this embodiment, the power threshold is set according to the received electric field strength (or the distance). As a result, the tolerance to interfering radio waves is improved in short-distance communication, thus making it possible to reduce the possibility of occurrences of false start-up of the receiver circuit due to interfering radio waves and thereby to reduce the power consumption. 
     In the reference examples 1 and 2 shown in  FIGS. 2 and 4 , when the power of received interfering radio waves changes over time, the demodulation unit mistakenly starts demodulation when, for example, an interfering radio wave equal to or larger than −90 dBm is received, thus causing an increase in the power consumption and deterioration in the communication characteristic. In contrast to this, in this embodiment, in the case of short-distance communication, no false reception is performed (no demodulation is started) by, for example, an interfering radio wave equal to or smaller than −60 dBm as shown in  FIG. 10 . Therefore, the tolerance to interfering radio waves is improved by 30 dB in comparison to the reference examples 1 and 2. 
     In mobile phone communication and the like, a distance between a base station and a terminal could drastically change in a short time due to a high-speed movement of the terminal. In contrast to this, in communication such as Bluetooth and a wireless LAN, since changes in the communication distance over time are very gentle, changes in the RSSI are also gentle. Therefore, even when an interfering radio wave whose power changes over time is received, it does not exceed the power threshold set in this embodiment. Therefore, it is possible to prevent or reduce false start-up of the demodulator and thereby to reduce the power consumption. 
     Second Embodiment 
     A second embodiment is explained hereinafter with reference to the drawings. 
     &lt;Detail of Control Unit&gt; 
       FIG. 11  shows a state machine diagram of the control unit  106  and its conditions for transitions among states according to the second embodiment.  FIG. 12  shows power thresholds TH corresponding to the respective states shown in  FIG. 11 . Similarly to the first embodiment, power thresholds may be determined by using a power threshold table according to the states shown in  FIG. 12  or determined by using a program. Note that the configuration of the second embodiment is similar to that of the first embodiment except for the control unit  106 , and therefore the explanation thereof is omitted. 
     While the control unit  106  in the first embodiment, upon receiving a received electric field strength SI, outputs a power threshold TH by using the power threshold table  106   a  shown in  FIG. 8 , the control unit  106  in the second embodiment, upon receiving a received electric field strength SI, performs a state transition by using the state machine shown in  FIG. 11  and outputs (sets) a power threshold TH corresponding to a respective state shown in  FIG. 12 . Similarly to the first embodiment, the states and the respective power thresholds TH are related to received electric field strengths and hence related to distances. For example, when the state ST 1  corresponds to a distance between 1 m and 320 m (or 10 m in the real space), the state ST 2  correspond to a distance shorter than 1 m and the state ST 3  corresponds to a distance longer than 320 m. 
     As shown in  FIG. 11 , the control unit  106  has internal states including the states ST 1  to ST 3  and performs a state transition according to the respective transition conditions. For example, the control unit  106  stores its internal state in a memory or the like. Then, when the transition condition is met, the control unit  106  updates the stored internal state and thereby performs a state transition. 
     Each transition condition between states includes a condition for the received electric field strength SI and a condition for the number of consecutive receptions. The condition for the received electric field strength SI is a condition for determining whether or not the received electric field strength SI meets a reference value. The condition for the number of consecutive receptions is a condition for determining whether or not the number of consecutive receptions of received signals meets a reference number for the number of receptions. The number of consecutive receptions is the number of receptions in which a series of received signals are received in a row on a packet--by-packet basis (i.e., the number of consecutive receptions of packets). For each transition condition, the state is changed when the received signal (packet) meets the condition for the received electric field strength SI and the reception is consecutively performed a predetermined times. 
     A transition condition IF 1  from the state ST 1  (e.g., initial state) to the state ST 2  is a condition for determining whether or not received signals whose received electric field strength SI is smaller than −40 dBm have been received more than cnt_th_M 2 L times in a row. When the transition condition IF 1  is met, the control unit  106  changes its state from the state ST 1  to the state ST 2  and changes the power threshold TH from −90 dBm, which is the power threshold TH corresponding to the state ST 1 , to −60 dBm, which is the power threshold TH corresponding to the state ST 2 . 
     A transition condition IF 2  from the state ST 2  to the state ST 1  is a condition for determining whether or not received signals whose received electric field strength SI is larger than −45 dBm have been received more than cnt_th_L 2 M times in a row. When the transition condition IF 2  is met, the control unit  106  changes its state from the state ST 2  to the state ST 1  and changes the power threshold TH from −60 dBm, which is the power threshold TH corresponding to the state ST 2 , to −90 dBm, which is the power threshold TH corresponding to the state ST 1 . 
     A transition condition IF 3  from the state ST 1  to a state ST 3  is a condition for determining whether or not received signals whose received electric field strength SI is larger than −90 dBm have been received more than cnt_th_M 2 H times in a row. When the transition condition IF 3  is met, the control unit  106  changes its state from the state ST 1  to the state ST 3  and changes the power threshold TH from −90 dBm, which is the power threshold TH corresponding to the state ST 1 , to −95 dBm, which is the power threshold TH corresponding to the state ST 3 . 
     A transition condition IF 4  from the state ST 3  to the state ST 1  is a condition for determining whether or not received signals whose received electric field strength SI is smaller than −85 dBm have been received more than cnt_th_H 2 M times in a row. When the transition condition IF 4  is met, the control unit  106  changes its state from the state ST 3  to the state ST 1  and changes the power threshold TH from −95 dBm, which is the power threshold TH corresponding to the state ST 3 , to −90 dBm, which is the power threshold TH corresponding to the state ST 1 . 
     The numbers cnt_th_M 2 L, cnt_th_L 2 M, cnt_th_H 2 M, and cnt_th_M 2 H (reference numbers for the number of consecutive receptions) are arbitrary integers. By setting large numbers to these numbers, it is possible to prevent the state from being mistakenly changed due to interfering radio waves or noises. In the example shown in  FIG. 11 , the value in the transition condition IF 1  from the state ST 1  to the state ST 2  differs from that in the transition condition. IF 2  from the state ST 2  to the state ST 1 , and the value in the transition condition IF 3  from the state ST 1  to the state ST 3  differs from that in the transition condition IF 4  from the state ST 3  to the state ST 1 . That is, they have hysteresis. In particular, the reference value (−40 dBm) for the received electric field strength in the transition condition IF 1  is higher than the reference value (−45 dBm) for the received electric field strength in the transition condition IF 2 , and the reference value (−90 dBm) for the received electric field strength in the transition condition IF 3  is lower than the reference value (−85 dBm) for the received electric field strength in the transition condition IF 4 . In this way, it is possible to prevent the state from being wastefully changed due to small fluctuations in the radio signal. 
     &lt;Operation Flow of Semiconductor Device&gt; 
       FIGS. 13 and 14  show a flowchart showing an operation of the semiconductor device  100  according to this embodiment. 
     As shown in  FIGS. 13 and 14 , firstly, in steps S 1  to S 4 , when a radio signal is received, an RSSI is calculated (step S 1 ) as in the case of the first embodiment. Then, when the received electric field strength SI exceeds the power threshold TH (step S 2 ), demodulation is performed (step S 3 ) and a CRC calculation result is checked (step S 4 ). 
     Next, steps S 10  to S 17  show a power threshold setting flow in this embodiment. When there is no error in the CRC calculation result, the control unit  106  makes a decision on the transition condition corresponding to the current state and performs a state transition and the setting of the power threshold TH according to the result of the decision on the transition condition. 
     In a step S 10 , the control unit  106  determines the current state. Then, when the current state is the state ST 1 , the control unit  106  makes a decision on the transition condition IF 1  in a step S 11 . In the step S 11 , the control unit  106  determines whether or not the received electric field strength SI is smaller than −40 dBm and the number of consecutive receptions exceeds the number cnt_th_M 2 L. When the number of consecutive receptions in which received signals having an received electric field strength SI smaller than −40 dBm are received in a row is larger than the number cnt_th_M 2 L, the control unit  106  changes its state from the state ST 1  to the state ST 2 , and sets the power threshold TH to −60 dBm and sets it in the threshold comparison unit  104  in a step S 15 . 
     Further, when the received electric field strength SI is equal to or larger than −40 dBm or the number of consecutive receptions in which received signals having an received electric field strength SI smaller than −40 dBm are received in a row is equal to or smaller than the number cnt_th_M 2 L in the step S 11 , the control unit  106  makes a decision on the transition condition IF 3  in a step S 12 . In the step S 12 , the control unit  106  determines whether or not the received electric field strength SI is larger than −90 dBm and the number of consecutive receptions exceeds the number cnt_th_M 2 H. When the received electric field strength SI is equal to or smaller than −90 dBm or the number of consecutive receptions in which received signals having an received electric field strength SI larger than −90 dBm are received in a row is equal to or smaller than the number cnt_th_M 2 H, the control unit  106  does not change its state and returns to the step S 1  in which the semiconductor device  100  waits for a radio signal. Further, when the number of consecutive receptions in which received signals having an received electric field strength SI larger than −90 clan are received in a row is larger than the number cnt_th_M 2 H, the control unit  106  changes its state from the state ST 1  to the state ST 3 , and sets the power threshold TH to −95 dBm and sets it in the threshold comparison unit  104  in a step S 16 . 
     In the step S 10 , when the current state is the state ST 2 , the control unit  106  makes a decision on the transition condition IF 2  in a step S 13 . In the step S 13 , the control unit  106  determines whether or not the received electric field strength SI is larger than −45 dBm and the number of consecutive receptions exceeds the number cnt_th_L 2 M. When the received electric field strength SI is equal to or smaller than −45 dBm or the number of consecutive receptions in which received signals having an received electric field strength SI larger than −45 dBm are received in a row is equal to or smaller than the number cnt_th_L 2 M, the control unit  106  does not change its state and returns to the step S 1  in which the semiconductor device  100  waits for a radio signal. Further, when the number of consecutive receptions in which received signals having an received electric field strength SI larger than −45 dBm are received in a row is larger than the number cnt_th_L 2 M, the control unit  106  changes its state from the state ST 2  to the state ST 1 , and sets the power threshold TH to −90 dBm and sets it in the threshold comparison unit  104  in a step S 17 . 
     In the step S 10 , when the current state is the state ST 3 , the control unit  106  makes a decision on the transition condition IF 4  in a step S 14 . In the step S 14 , the control unit  106  determines whether or not the received electric field strength SI is smaller than −85 dBm and the number of consecutive receptions exceeds the number cnt_th_H 2 M. When the received electric field strength SI is equal to or larger than −85 dBm or the number of consecutive receptions in which received signals having an received electric field strength SI smaller than −85 dBm are received in a row is equal to or smaller than the number cnt_th_H 2 M, the control unit  106  does not change its state and returns to the step S 1  in which the semiconductor device  100  waits for a radio signal. Further, when the number of consecutive receptions in which received signals having an received electric field strength SI smaller than −85 dBm are received in a row is larger than the number cnt_th_H 2 M, the control unit  106  changes its state from the state ST 3  to the state ST 1 , and sets the power threshold TH to −90 dBm and sets it in the threshold comparison unit  104  in a step S 17 . 
     &lt;Advantageous Effect of this Embodiment&gt; 
     As described above, in this embodiment, the state is changed according to the received electric field strength (or the distance) and the power threshold is set for each state (i.e., set according to the state). In this way, since the power threshold is set according to the received electric field strength (or the distance), the power consumption can be reduced as in the case of the first embodiment. 
     Further, by setting large numbers to the number cnt_th_M 2 L, cnt_th_L 2 M, cnt_th_H 2 M, and cnt_th_M 2 H, it is possible to prevent the state from being mistakenly changed due to interfering radio waves or multipath fading. Further, by providing hysteresis for the reference values in the transition conditions that are used for the magnitude comparison of the received electric field strength SI as shown in  FIG. 11 , it is possible to further prevent the state from being mistakenly changed due to interfering radio waves or multipath fading. The reference values for which the hysteresis is provided are determined, for example, by performing evaluations or/and simulations. 
     Third Embodiment 
     A third embodiment is explained hereinafter with reference to the drawings. 
     Configuration Semiconductor Device&gt; 
       FIG. 15  shows a configuration diagram of a semiconductor device  100  according to a third embodiment. In comparison to the configuration of the first embodiment shown in  FIG. 7 , the configuration shown in  FIG. 15  additionally includes a modulation unit  201 , which is a transmission circuit, a transmission amplifier  202 , and a switch  203  that switches between the transmission circuit and the reception circuit. Further, the configuration shown in  FIG. 15  also includes, as control signals, a reception gain RG that is used to set a reception gain of the quadrature conversion circuit  101  and a transmission power SP that is supplied from the control unit  106  to the transmission amplifier  202  and used to set transmission power of the transmission amplifier  202 . 
     In a transmitting operation, the modulation unit  201  modulates transmission data and the transmission amplifier  202  amplifies its signal amplitude to transmission power that is set according to the transmission power SP. The switch  203  connects the antenna  111  with the transmission amplifier  202  in a transmitting operation, and connects the antenna  111  with the quadrature conversion circuit.  101  in a receiving operation. 
     &lt;Detail of Control Unit&gt; 
     In this embodiment, the control unit  106  sets the transmission power SP and the reception gain RG in addition to the power threshold TH according to the received electric field strength SI. For example, the control unit  106  serves as a transmission power setting unit that sets transmission power in addition to serving as the threshold setting unit that sets the power threshold TH. Further, the control unit  106  also serves as a reception gain setting unit that sets a reception gain.  FIG. 16  shows a control table  106   b  possessed by the control unit  106  according to this embodiment. Compared to the power threshold table  106   a  in the first embodiment, the control table  106   b  additionally includes (i.e. records) transmission powers SP and reception gains RG. For example, the control unit  106  stores the control table in a memory or the like in advance. Then, the control unit  106  sets the power threshold TH, the transmission power SP, and the reception gain RG according to the received electric field strength SI based on the stored control table. Note that similarly to the first embodiment, the power threshold, the transmission power, and/or the reception gain may be determined by using a calculation formulas) (program) instead of using the table shown in  FIG. 16 . Further, similarly to the second embodiment, the power threshold, the transmission power, and/or the reception gain may be associated with the states ST 1  to ST 3  and set according to the state transition. Note that only one or two of the power threshold, the transmission power, and the reception gain may be set. 
     In the example shown in  FIG. 16 , when the received electric field strength SI is equal to or larger than −39 dBm, the control unit  100  outputs −60 dBm as a power threshold TH to be set, −15 dBm as a transmission power SP to be set, and 60 dB as a reception gain RG to be set. When the received electric field strength SI is equal to or smaller than −90 dBm, the control unit  106  outputs −95 dBm as a power threshold TH to be set, 2 dBm as a transmission power SP to be set, and 76 dB as a reception gain RG to be set. Further, when the received electric field strength SI is between −40 dBm and −89 dBm, the control unit  106  outputs −90 dBm as a power threshold TH to be set, 0 dBm as a transmission power SP to be set, and 70 dB as a reception gain RG to be set. Note that the distance may be used instead of using the received electric field strength SI as in the case of the first embodiment. 
     &lt;Operation Flow of Semiconductor Device&gt; 
       FIG. 17  is a flowchart showing an operation of the semiconductor device  100  according to this embodiment. In comparison to the flowchart in the first embodiment shown in  FIG. 9 , the flowchart shown in  FIG. 17  additionally includes steps S 20  to S 25 . 
     As shown in  FIG. 17 , firstly, in steps S 1  to S 4 , when a radio signal is received, an RSSI is calculated (step S 1 ) as in the case of the first embodiment. Then, when the received electric field strength SI exceeds the power threshold TH (step S 2 ), demodulation is performed (step S 3 ) and a CRC calculation result is checked (step S 4 ). 
     In a step S 5 , the control unit  106  determines whether or not the received electric field strength SI is larger than −40 dBm. Then, when the received electric field strength SI is larger than −40 dBm, the control unit  106  sets the power threshold TH to −60 dBm and sets it in the threshold comparison unit  104  in a step  37 . Further, the control unit  106  sets the transmission power SP to −15 dBm and sets it in the transmission amplifier  202  in a step S 20 , and sets the reception gain RG to 60 dB and sets it in the quadrature conversion circuit  101  in a step S 23 . 
     Further, when the received electric field strength SI is equal to or smaller than −40 dBm, the control unit  106  determines whether or not the received electric field strength SI is smaller than −90 dBm in a step S 6 . Then, when the received electric field strength SI is smaller than −90 dBm, the control unit  106  sets the power threshold TH to −95 dBm and sets it in the threshold comparison unit  104  in a step S 8 . Further, the control unit  106  sets the transmission power SP to 0 dBm and sets it in the transmission amplifier  202  in a step S 21  and sets the reception gain RG to 70 dB and sets it in the quadrature conversion circuit  101  in a step S 24 . 
     Further, when the received electric field strength SI is equal to or larger than −90 dBm, the control unit  106  sets the power threshold TH to −90 dBm and sets it in the threshold comparison unit  104  in a step S 9 . Further, the control unit  106  sets the transmission power SP to 2 dBm and sets it in the transmission amplifier  202  in a step S 22  and sets the reception gain RG to 76 dB and sets it in the quadrature conversion circuit  101  in a step S 25 . 
     &lt;Advantageous Effect of this Embodiment&gt; 
     As shown in the above-shown Expression (3), since the received electric field strength SI is in proportion to the square of the communication distance, the communication distance can be estimated from the received electric field strength SI. When the communication distance is short, the propagation loss in a free space is small. Therefore, the power consumption in the transmission amplifier can be reduced by setting a small value to the transmission power SP. On the other hand, when the communication distance is long, the propagation loss in a free space is large. Therefore, communication can be performed in a longer distance by setting a large value to the transmission power SP. 
     In the third embodiment, when the received electric field strength SI is large, the reception gain RG is reduced by using the control table shown in  FIG. 16 . The power consumption can be reduced by reducing the reception gain. RG. However, when the reception gain RG is reduced, the NF (Noise Factor) of the quadrature conversion circuit  101  increases. 
     The below-shown Expression (4) shows a relation between the received electric field strength and the C/N (Carrier per Noise). In the expression, CN is C/N [dB] in an antenna; RXPOW is a received electric field strength [dBm]; B is a bandwidth [Hz]; k is Boltzmann constant (1.38×10 −23  [J/Hz]); and T is a temperature [K]. 
         CN=RXPOW −(10 log( B )−10 log( kT ))  (4)
 
     When the C/N satisfies a condition expressed by the below-shown Expression (5), demodulation is possible. In the expression, CNR is a required CNR (Carrier to Noise Ratio), i.e., represents C/N [dB] with which the demodulation unit  105  can perform demodulation, and NF (Noise Figure) represents a noise factor [dB] in the quadrature conversion circuit  101 . 
         CN&gt;CNR+NF   (5)
 
     By substituting the above-shown Expression (5) into the above-shown Expression (4), the below-shown Expression (6) is obtained. 
         RXPOW−NF&gt;CNR+ 10 log( B )−10 log( kT )  (6)
 
     Based on the above--shown Expression (6), when the RXPOW (received electric field strength SI) is large, demodulation can be performed even when the NF (Noise Factor) of the quadrature conversion circuit  101  is increased. Therefore, an advantageous effect that the power consumption can be reduced can be achieved. 
     As described above, in this embodiment, the power threshold, the transmission power, and/or the reception gain are set according to the received electric field strength (or the distance). In this way, since the transmission power and the reception gain as well as the power threshold can be set to their optimal values, the power consumption can be reduced even further. 
     Further, the program in the above-described embodiments can be stored in various types of non-transitory computer readable media and thereby supplied to computers. The non-transitory computer readable media includes various types of tangible storage media. Examples of the non-transitory computer readable media include a magnetic recording medium (such as a flexible disk, a magnetic tape, and a hard disk drive), a magneto-optic recording medium (such as a magneto-optic disk), a CD-ROM (Read Only Memory), a CD-R, and a CD-R/W, and a semiconductor memory (such as a mask ROM, a PROM (Programmable ROM), an EPROM (Erasable PROM), a flash ROM, and a RAM (Random Access Memory)). Further, the program can be supplied to computers by using various types of transitory computer readable media. Examples of the transitory computer readable media include an electrical signal, an optical signal, and an electromagnetic wave. The transitory computer readable media can be used to supply programs to computer through a wire communication path such as an electrical wire and an optical fiber, or wireless communication path. 
     The present invention made by the inventors has been explained above in a specific manner based on embodiments. However, the present invention is not limited to the above-described embodiments, and needless to say, various modifications can be made without departing from the spirit and scope of the present invention. 
     The first, second and third embodiments can be combined as desirable by one of ordinary skill in the art. 
     While the invention has been described in terms of several embodiments, those skilled in the art will recognize that the invention can be practiced with various modifications within the spirit and scope of the appended claims and the invention is not limited to the examples described above. 
     Further, the scope of the claims is not limited by the embodiments described above. 
     Furthermore, it is noted that, Applicant&#39;s intent is to encompass equivalents of all claim elements, even if amended later during prosecution.