Abstract:
Disclosed are a D2D resource allocation method, and data transmission method and device, the D2D resource allocation method comprising: determining a D2D resource configuration corresponding to the quality of service (QoS) level of a D2D service; and transmitting to a user equipment (UE) the information of the D2D resource configuration corresponding to the service quality level of the D2D service. The D2D data transmission method comprises: according to the received information of the D2D resource configuration corresponding to the service quality level of the D2D service, selecting a transmission resource for the D2D service to be transmitted; and transmitting the data of the D2D service over the selected transmission resource. The D2D service transmission requirement is considered in allocating and selecting D2D resources, thus further improving the system D2D resource allocation efficiency without affecting the D2D service transmission requirement.

Description:
[0001]    This application claims the benefit of Chinese Patent Application No. 201310741883.7, filed with the Chinese Patent Office on Dec. 27, 2013 and entitled “Method for allocating a D2D resource, and method and apparatus for transmitting data”, which is hereby incorporated by reference in its entirety. 
       FIELD 
       [0002]    The present application relates to the field of wireless communications and particularly to a method for allocating a D2D resource, and a method and apparatus for transmitting data. 
       BACKGROUND 
       [0003]    Communication is controlled centrally by a network In a Long Term Evolution (LTE) system, that is, both uplink and downlink data of a User Equipment (UE) are controlled by the network to be transmitted and received. In this mode, communication between one UE and another UE is forwarded and controlled by the network, and there is no direct communication link between the UE and the other UE, where data transmission between the UE and the network can be referred simply to as Device to Network (D2N) transmission. 
         [0004]    In future development of a mobile communication system, in order to better satisfy a user demand, and to improve the efficiency of exchanging information between the devices, the mechanisms of Device to Device (D2D) discovery and Device to Device (D2D) communication have been introduced. 
         [0005]    The D2D discovery mechanism is a direct discovery mechanism between two devices proximate to each other. Both of the D2D discovery devices may be online devices or may be offline devices, or one of the devices may be an online device, and the other device may be an offline device. The online device refers to a device located inside a coverage area of the network (e.g., a Third-Generation Partner Project (3GPP) network) and operating over a spectrum resource of the network is accessible. The offline device refers to a device located outside a coverage area of the network (e.g., a 3GPP network), or located inside the coverage area of the network but operating over a dedicated spectrum. 
         [0006]    At present, air interface resources of D2D discovery are allocated in two modes, where one of the modes is the common resource pool mode in which the UEs are configured with the same air interface resources over which D2D discovery data are transmitted in some area, and the data transmitting UEs can transmit the data in some detection and avoidance mechanism, and the common resource pool is controlled by an evolved Node B (eNB) if the devices are online, or the common resource pool may be pre-configured, or may be controlled by a central control node, if the devices are offline; and the other mode is the dedicated resource mode in which a dedicated D2D transmission resource (i.e., an air interface resource) is allocated for each UE by pre-configuring the dedicated D2D transmission resource or by a central control node configuring the dedicated D2D transmission resource (which is controlled by the eNB if the UE is online). 
         [0007]    Here the central control node is a UE or a network element capable of controlling resources, which can be referred to as a Central Node (CN) or a Central Element (CE). 
         [0008]    D2D communication is allowed to be performed directly between devices proximate to each other. For the sake of a convenient description, a direct communication link between Device to Device (D2D) UEs can be referred to as a D2D link, and a cellular communication link between the network and the D2D UE can be referred to as a D2N link.  FIG. 1  illustrates a schematic diagram of D2D communication. 
         [0009]    Both of the D2D communication devices can be online or offline, or one of the devices can be online, and the other device can be offline. 
         [0010]    There are the following three typical D2D communication scenarios: 
         [0011]    In a first scenario, there is one-to-one communication between D2D UEs. 
         [0012]    In a second scenario, one device transmits the same data once to all the devices in a communication group (group communication). 
         [0013]    In a third scenario, one device transmits the same data once to all the proximate devices (broadcast communication). 
         [0014]    Here one-to-one communication between D2D UEs is generally applicable to social and other applications, and the group and broadcast communication scenarios are generally applicable to fire fighting, rescuing, antiterrorism, and other public security applications. 
         [0015]    At present there are generally two resource allocation modes for D2D communication, i.e., the common resource pool mode and the dedicated resource mode, which are particularly similar to the resource allocation modes for D2D discovery. 
         [0016]    Different D2D transmission resource demands of different D2D services have not been taken into account in existing D2D resource allocation (including D2D discovery resource allocation and D2D communication resource allocation), and by the UE selecting a D2D service transmission resource. 
       SUMMARY 
       [0017]    Embodiments of the application provide a method for allocating a D2D resource, and a method and apparatus for transmitting data so as to allocate and select a D2D resource satisfying a D2D service transmission demand. 
         [0018]    An embodiment of the application provides a method for allocating a D2D resource, the method including:
       determining D2D resource configurations corresponding to quality of service levels of D2D services; and   transmitting information about the D2D resource configurations corresponding to the quality of service levels of the D2D services to a user equipment.       
 
         [0021]    In the method for allocating a D2D resource according to the embodiment of the application, a D2D resource is configured according to a Quality of Service (QoS) level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of Carrier Sense Multiple Access (CSMA)) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0022]    In the following respective embodiments of the application, a QoS level of a D2D service will be referred simply to as a QoS level. 
         [0023]    The D2D resource allocation modes typically include the common resource pool mode and the dedicated resource mode. The method for allocating a D2D resource according to the embodiment of the application will be described below taking these two modes respectively as examples. 
         [0024]    In the common resource pool mode, the D2D resource configurations corresponding to the QoS levels can be determined by determining D2D resource pool configurations corresponding to the respective QoS levels; and the information about the determined D2D resource configurations corresponding to the QoS levels can be transmitted to the UE by transmitting information about the D2D resource pool configurations corresponding to the respective QoS levels to the UE. Further to this, the information about the D2D resource pool configurations can include but will not be limited to at least one of:
       information about time-frequency resources in the D2D resource pools;   information about resource configuration periodicities of the D2D resource pools;   information about offsets of the D2D resource pools;   information about modulation and coding scheme (MCS) levels for use in transmission of data over resources in the D2D resource pools;   information about the numbers of retransmissions in transmission of data over resources in the D2D resource pools;   information about power allocation in transmission of data over resources in the D2D resource pools; and   parameters related to a collision detection mechanism for use in selection among resources in D2D resource pools.       
 
         [0032]    Here the resources in the resource pools corresponding to the different QoS levels may be different. Alternatively resources in a resource pool of a high QoS level include resources in a resource pool of a low QoS level, for example, the information about the time-frequency resources in the resource pool of the high QoS level include the information about the time-frequency resources in the resource pool of the low QoS level. 
         [0033]    In order to ensure reasonable division of resources into the respective QoS levels, the D2D resource pool configurations corresponding to the respective QoS levels need to be maintained. They can be maintained by an access stratum node, e.g., an eNB, a UE, a network element, etc., which can function as a central control node, or a resource control node at another access stratum; or they can be maintained by a higher-layer node, e.g., a Proximity Service (ProSe) node. Preferably the D2D resource pool configurations corresponding to the respective QoS levels can be maintained by detecting the amounts of transmitted service data over the resources in the respective D2D resource pools, judging the reasonability about division of the resources into the different QoS levels, and adjusting the resources in the resource pools corresponding to the different QoS levels according to a result of judgment for the reasonability about division of the resources. 
         [0034]    In the dedicated resource mode, the D2D resource configurations corresponding to the QoS levels can be determined by receiving a resource request of the UE carrying the information about the QoS levels, and determining the D2D resource configurations corresponding to the QoS levels indicated by the information about the QoS levels. The information about the determined D2D resource configuration corresponding to the QoS levels can be transmitted to the UE by transmitting the information about the determined D2D resource configurations, and D2D service indication information to the UE, where the D2D service indication information indicates the D2D services corresponding to the information about the determined D2D resource configuration; or the information about the determined D2D resource configurations corresponding to the QoS levels can be transmitted to the UE by transmitting the information about the determined D2D resource configurations, and QoS level indication information to the UE, where the QoS level indication information indicates the QoS levels corresponding to the information about the determined D2D resource configurations. Further to this, the information about the D2D resource configurations can include but will not be limited to at least one of:
       information about time-frequency resources among D2D resources;   information about modulation and coding scheme levels for use in transmission of data over D2D resources;   information about the numbers of retransmissions in transmission of data over D2D resources; and   information about transmit power in transmission of data over D2D resources.       
 
         [0039]    An embodiment of the application provides a method for transmitting D2D data, the method including:
       selecting transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels of the D2D service; and   transmitting data of the D2D services over the selected transmission resources.       
 
         [0042]    In the method for transmitting D2D data according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level of the D2D services. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, no (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0043]    The D2D resource allocation modes typically include the common resource pool mode and the dedicated resource mode. The method for transmitting D2D data according to the embodiment of the application will be described below taking these two modes respectively as examples. 
         [0044]    In the common resource pool mode, the transmission resources can be selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services by determining D2D resource pools corresponding to the QoS levels of the D2D services to be transmitted; and selecting the transmission resources in the determined D2D resource pools, for the D2D services to be transmitted, according to received information about D2D resource pool configurations corresponding to the respective QoS levels of the D2D services. 
         [0045]    In the dedicated resource mode, a resource request is further sent before the transmission resources are selected for the D2D services to be transmitted, where the resource requests canes the information about the QoS levels of the D2D services to be transmitted; and the transmission resources can be selected for the D2D services to be transmitted according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services by selecting the transmission resources for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted, where the information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted is transmitted by a resource request receiver in response to the resource request. 
         [0046]    Further to any one of the embodiments above of the method for transmitting D2D data, if there are a number of D2D services to be transmitted, then transmission resources can be selected only for those D2D services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted, or transmission resources can be selected for the D2D services to be transmitted by guaranteeing transmit power of preferentially those services to be transmitted at high QoS levels; or transmission resources can be selected for the D2D services to be transmitted by selecting transmission resources preferentially for those services to be transmitted at high QoS levels. 
         [0047]    Preferably if the number of D2D services allowed to be transmitted is less than the number of D2D services to be transmitted, then transmission resources can be selected only for those services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted. 
         [0048]    Preferably if there is limited transmit power of at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by guaranteeing the transmit power of preferentially those services to be transmitted at high QoS levels. 
         [0049]    Preferably if available transmission resources can not satisfy a resource demand for at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by selecting a transmission resource preferentially for a service to be transmitted at a high QoS level. 
         [0050]    Further to any one of the embodiments above of the method for transmitting D2D data, preferably the transmission resources can be selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services as follows: if the transmission resources selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted can not satisfy transmission requirements of the D2D services to be transmitted, then the transmission resources can be selected for the D2D services to be transmitted, according to information about D2D resource configurations of low QoS levels which are lower than the QoS levels of the D2D services to be transmitted. 
         [0051]    Based upon the same inventive idea as the method above, an embodiment of the application provides an apparatus for allocating a D2D resource, the apparatus including:
       a D2D resource configuring module is configured to determine D2D resource configurations corresponding to QoS levels; and   a D2D resource configuration information transmitting module is configured to transmit information about the determined D2D resource configurations corresponding to the QoS levels to a UE.       
 
         [0054]    In the apparatus for allocating a D2D resource according to the embodiment of the application, a D2D resource is configured according to a QoS level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0055]    In the common resource pool mode, preferably the D2D resource configuring module is particularly configured to determine D2D resource pool configurations corresponding to the respective QoS levels; and the D2D resource configuration information transmitting module is particularly configured to transmit information about the D2D resource pool configurations corresponding to the respective QoS levels to the UE. Further to this, the information about the D2D resource pool configurations includes at least one of:
       information about time-frequency resources in the D2D resource pools;   information about resource configuration periodicities of the D2D resource pools;   information about offsets of the D2D resource pools;   information about MCS levels for use in transmission of data over resources in the D2D resource pools;   information about the numbers of retransmissions in transmission of data over resources in the D2D resource pools;   information about power allocation in transmission of data over resources in the D2D resource pools; and   parameters related to a collision detection mechanism for use in selection among resources in D2D resource pools.       
 
         [0063]    Here the resources in the resource pools corresponding to the different QoS levels may be different. Alternatively resources in a resource pool of a high QoS level include resources in a resource pool of a low QoS level, for example, the information about the time-frequency resources in the resource pool of the high QoS level include the information about the time-frequency resources in the resource pool of the low QoS level. 
         [0064]    In order to ensure reasonable division of resources into the respective QoS levels, the D2D resource pool configurations corresponding to the respective QoS levels need to be maintained. They can be maintained by an access stratum node, e.g., an eNB, a UE, a network element, etc., which can function as a central control node, or a resource control node at another access stratum; or they can be maintained by a higher-layer node, e.g., a ProSe node. Preferably the D2D resource pool configurations corresponding to the respective QoS levels can be maintained by detecting the amounts of transmitted service data over the resources in the respective D2D resource pools, judging the reasonability about division of the resources into the different QoS levels, and adjusting the resources in the resource pools corresponding to the different QoS levels according to a result of judgment for the reasonability about division of the resources. Optionally the apparatus for allocating a D2D resource according to the embodiment of the application further includes a D2D resource configuration maintaining module configured to maintain the D2D resource pool configurations corresponding to the respective QoS levels, and reference can be made to the description above of the maintenance of the D2D resource pool configurations for details thereof. 
         [0065]    In the dedicated resource mode, preferably the D2D resource configuring module is particularly configured to receive a resource request of the LIE, carrying information about the QoS levels; and to determine the D2D resource configurations corresponding to the QoS levels indicated by the information about the QoS levels. Accordingly the D2D resource configuration information transmitting module is particularly configured to transmit the information about the determined D2D resource configurations, and D2D service indication information to the UE, where the D2D service indication information indicates D2D services corresponding to the information about the determined D2D resource configuration; or to transmit the information about the determined D2D resource configurations, and QoS level indication information to the UE, where the QoS level indication information indicates the QoS levels corresponding to the information about the determined D2D resource configurations. 
         [0066]    In the dedicated resource mode, preferably the information about the D2D resource configurations can include but will not be limited to at least one of:
       information about time-frequency resources among D2D resources;   information about MCS levels for use in transmission of data over D2D resources;   information about the numbers of retransmissions in transmission of data over D2D resources; and   information about transmit power in transmission of data over D2D resources.       
 
         [0071]    Based upon the same inventive idea as the application, an embodiment of the application further provides an access stratum resource control node including a processor and a radio frequency unit, where:
       the processor is configured to determine D2D resource configurations corresponding to QoS levels; and   the radio frequency unit is configured to transmit information about the determined D2D resource configurations corresponding to the QoS levels to a UE.       
 
         [0074]    The access stratum resource control node according to the embodiment of the application can include but will not be limited to an eNB, a central control node, etc. 
         [0075]    In the access stratum resource control node according to the embodiment of the application, a D2D resource is configured according to a QoS level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service an that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service 
         [0076]    Based upon the same inventive idea as the application, an embodiment of the application further provides an apparatus for transmitting D2D data, and as illustrated in  FIG. 6  the apparatus includes:
       a D2D transmission resource selecting module configured to select transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels; and   a D2D data transmitting module configured to transmit data of the D2D services over the selected transmission resources.       
 
         [0079]    In the apparatus for transmitting D2D data according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0080]    In the common resource pool mode, preferably the D2D transmission resource selecting module is particularly configured to determine D2D resource pools corresponding to the QoS levels of the D2D services to be transmitted; and to select the transmission resources in the determined D2D resource pools, for the D2D services to be transmitted, according to received information about D2D resource pool configurations corresponding to the respective QoS levels. 
         [0081]    In the dedicated resource mode, preferably the apparatus for transmitting D2D data according to the embodiment of the application can further include a resource requesting module configured to send a resource request carrying information about the QoS levels of the D2D services to be transmitted; and the D2D transmission resource selecting module is particularly configured to select the transmission resources for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted, where the information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted is transmitted by a resource request receiver in response to the resource request. 
         [0082]    Further to any one of the embodiments above of the apparatus for transmitting D2D data, if there are a number of D2D services to be transmitted, then transmission resources can be selected only for those D2D services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted, or transmission resources can be selected for the D2D services to be transmitted by guaranteeing transmit power of preferentially those services to be transmitted at high QoS levels; or transmission resources can be selected for the D2D services to be transmitted by selecting transmission resources preferentially for those services to be transmitted at high QoS levels. 
         [0083]    Preferably if the number of D2D services allowed to be transmitted is less than the number of D2D services to be transmitted, then transmission resources can be selected only for those services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted. 
         [0084]    Preferably if there is limited transmit power of at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by guaranteeing the transmit power of preferentially those services to be transmitted at high QoS levels. 
         [0085]    Preferably if available transmission resources can not satisfy a resource demand for at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by selecting a transmission resource preferentially for a service to be transmitted at a high QoS level. 
         [0086]    Further to any one of the embodiments above of the apparatus for transmitting D2D data, preferably the D2D transmission selecting module is particularly configured, if the transmission resources selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted can not satisfy transmission requirements of the D2D services to be transmitted, to select the transmission resources for the D2D services to be transmitted, according to information about D2D resource configurations of low QoS levels which are lower than the QoS levels of the D2D services to be transmitted. 
         [0087]    Based upon the same inventive idea as the application, an embodiment of the application further provides a user equipment including a processor and a radio frequency unit, where:
       the processor is configured to select transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels; and   the radio frequency unit is configured to transmit data of the D2D services over the selected transmission resources.       
 
         [0090]    In the user equipment according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0091]      FIG. 1  is a schematic diagram of D2D communication; 
           [0092]      FIG. 2  is a flow chart of a method for allocating a D2D resource according to an embodiment of the application; 
           [0093]      FIG. 3  is a flow chart of a method for transmitting D2D data according to an embodiment of the application; 
           [0094]      FIG. 4  is a schematic diagram of an apparatus for allocating a D2D resource according to an embodiment of the application; 
           [0095]      FIG. 5  is a schematic diagram of an access stratum resource control node according to an embodiment of the application; 
           [0096]      FIG. 6  is a schematic diagram of an apparatus for transmitting D2D data according to an embodiment of the application; and 
           [0097]      FIG. 7  is a schematic diagram of a user equipment according to an embodiment of the application. 
       
    
    
     DETAILED DESCRIPTION OF THE EMBODIMENTS 
       [0098]    Embodiments of the application provide a solution to QoS-based allocation and selection of a D2D data transmission resource, and with this solution, allocation of the D2D transmission resource can better match with a D2D service transmission attribute without discouraging a D2D service transmission demand or degrading the efficiency of allocating an air interface D2D resource. A core idea of the embodiments of the application lies in that D2D resources for services with different QoS&#39;s are allocated, and D2D data can be transmitted by selecting a D2D transmission resource corresponding to a QoS attribute of a D2D service to be transmitted. 
         [0099]    The technical solution according to the embodiments of the application will be described below in details with reference to the drawings. 
         [0100]      FIG. 2  illustrates a method for allocating a D2D resource according to an embodiment of the application, where the method particularly includes the following operations: 
         [0101]    The step  200  is to determine D2D resource configurations corresponding to QoS levels. 
         [0102]    Here D2D resources corresponding to the different QoS levels can be configured by an access stratum resource control node, e.g., an eNB, a central control node, etc., or can be configured by a higher layer, e.g., a ProSe node, etc. 
         [0103]    Accordingly if the D2D resources corresponding to the different QoS levels are configured by the present node, then the D2D resource configurations corresponding to the QoS levels will be determined according to the configuration by the present node; and if the D2D resources corresponding to the different QoS levels are configured by another node, then D2D resources corresponding to the different QoS levels will be obtained from the other node, and the D2D resources configuration corresponding to the QoS levels will be determined according to the obtained information. 
         [0104]    The step  210  is to transmit information about the determined D2D resource configurations corresponding to the QoS levels to a UE. 
         [0105]    In the method for allocating a D2D resource according to the embodiment of the application, a D2D resource is configured according to a QoS level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0106]    The method for allocating a D2D resource according to the embodiment of the application can be applicable to both a D2D discovery scenario and a D2D communication scenario. 
         [0107]    D2D resource allocation modes typically include the common resource pool mode and the dedicated resource mode. The method for allocating a D2D resource according to the embodiment of the application will be described below taking these two modes respectively as examples. 
         [0108]    In the common resource pool mode: 
         [0109]    The D2D resource configurations corresponding to the QoS levels can be determined by determining D2D resource pool configurations corresponding to the respective QoS levels. 
         [0110]    Particularly D2D resource pool configurations corresponding to the respective QoS levels in the LTE system can be determined, or D2D resource configurations corresponding to the respective QoS levels in a home area of a D2D service of the UE can be determined. 
         [0111]    Particularly the D2D resource configurations corresponding to the QoS levels can be determined according to the configuration by the access stratum resource control node, or the D2D resource configurations corresponding to the QoS levels can be determined according to the configuration by the higher-layer node. 
         [0112]    Accordingly the information about the determined D2D resource configurations corresponding to the QoS levels can be transmitted to the UE by transmitting information about the D2D resource pool configurations corresponding to the respective QoS levels to the UE. 
         [0113]    Particularly information about the D2D resource pool configurations corresponding to the respective QoS levels in the LTE system can be transmitted to the UE, or information about the D2D resource configurations corresponding to the respective QoS levels in the home area of the D2D service of the UE can be transmitted to the UE. 
         [0114]    Further to the respective embodiments in the common resource pool, the information about the D2D resource pool configurations can include but will not be limited to at least one of: 
         [0115]    Information about time-frequency resources in the D2D resource pools; 
         [0116]    Information about resource configuration periodicities of the D2D resource pools; 
         [0117]    Information about offsets of the D2D resource pools; 
         [0118]    Information about Modulation and Coding Scheme (MCS) levels for use in transmission of data over resources in the D2D resource pools; 
         [0119]    Information about the numbers of retransmissions in transmission of data over resources in the D2D resource pools; 
         [0120]    Information about power allocation in transmission of data over resources in the D2D resource pools; and 
         [0121]    Parameters related to a collision detection mechanism for use in selection among resources in D2D resource pools. 
         [0122]    Here the information about the offsets of the D2D resource pools can be information about temporal offsets of the D2D resource pools and/or information about frequency offsets of the D2D resource pools. 
         [0123]    Here the parameters related to the collision detection mechanism for use in selection of the resources in the D2D resource pools can include but will not be limited to a collision back-off length of time, etc. 
         [0124]    Here the resources in the resource pools corresponding to the different QoS levels may be different. Alternatively resources in a resource pool of a high QoS level include resources in a resource pool of a low QoS level, for example, the information about the time-frequency resources in the resource pool of the high QoS level include the information about the time-frequency resources in the resource pool of the low QoS level. 
         [0125]    Taking an online scenario as an example, a preferred embodiment of the method for allocating a D2D resource in a common resource pool is as follows: 
         [0126]    There are resource pools corresponding to different QoS levels in the LTE system. Since a QoS reflects information about a transmission delay, reliability, rate, and other attributes of a D2D service, the different resource pools in the LTE system correspond to different delay priorities, rate priorities, and/or transmission reliability. 
         [0127]    If the eNB knows in advance that there are three QoS levels, denoted as QoS levels 2 and 3 respectively, corresponding to D2D services in the present LTE system, through a core network or as pre-configured, and the eNB obtains in advance configurations of D2D resource pools corresponding to these three QoS levels respectively through the core network or as pre-configured, then the eNB can allocate a D2D resource by determining the D2D resource pool configurations corresponding to these three QoS levels respectively, and notifying the UE of information about the D2D resource pool configurations corresponding to these three QoS levels respectively through broadcasting, dedicated signaling, etc., where reference can be made for the description of the embodiment above for the information about the D2D resource pool configurations, so a repeated description thereof will be omitted here. 
         [0128]    In order to ensure reasonable division of resources into the respective QoS levels, the D2D resource pool configurations corresponding to the respective QoS levels need to be maintained, where they can be maintained by an access stratum node, e.g., an eNB, a UE, a network element, etc., which can function as a central control node, or a resource control node at another access stratum; or they can be maintained by a higher-layer node, e.g., a ProSe node. Preferably the D2D resource pool configurations corresponding to the respective QoS levels can be maintained by detecting the amounts of transmitted service data over the resources in the respective D2D resource pools, judging the reasonability about division of the resources into the different QoS levels, and adjusting the resources in the resource pools corresponding to the different QoS levels according to a result of judgment for the reasonability about division of the resources. 
         [0129]    Here the reasonability about division of the resources into the different QoS levels can be judged, and the resources in the resource pools corresponding to the different QoS levels can be adjusted, in a number of particular implementations, where they can be judged and adjusted particularly as demanded for the real services. Taking an online scenario as an example, in a preferred embodiment of the method for allocating a D2D resource in a common resource pool, the resource pools can be maintained as follows: 
         [0130]    If D2D resource pools corresponding to the QoS level 1 and the QoS level 2 respectively are configured in the system, where the QoS level 1 is a high QoS level, and the QoS level 2 is a low QoS level, then: 
         [0131]    The UE transmits the D2D service by counting usages and confliction conditions of resources in the respective resource pools, and reflects them to the maintenance network element (e.g., the eNB) periodically or in real time. For example, if the UE detects a resource selection success ratio of 10% in the resource pool corresponding to the QoS level 1, and a resource selection success ratio of 90% in the resource pool corresponding to the QoS level 2, then the UE will notify the eNB of this through RRC signaling or otherwise. 
         [0132]    The maintenance network element determines allocation conditions of the resource pools per QoS level according to the information reported by the UEs in its maintenance area, and thereafter increases the number of time-frequency resources divided into the resource pool of the QoS level 1, and decreases the number of time-frequency resources divided into the resource pool of the QoS level 2. 
         [0133]    In the dedicated resource mode: 
         [0134]    The D2D resource configurations corresponding to the QoS levels can be determined by receiving a resource request of the UE carrying the information about the QoS levels, and determining the D2D resource configurations corresponding to the QoS levels indicated by the information about the QoS levels. 
         [0135]    Optionally the D2D resource configurations can alternatively be determined by referring to the information about the QoS levels carried in the resource request. 
         [0136]    Here the information about the QoS levels can be identification information of the QoS levels, delay information corresponding to the QoS levels, rate information corresponding to the QoS levels, transmission reliability information corresponding to the QoS levels, etc. 
         [0137]    The information about the determined D2D resource configuration corresponding to the QoS levels can be transmitted to the UE by transmitting the information about the determined D2D resource configurations, and D2D service indication information to the UE, where the D2D service indication information indicates the D2D services corresponding to the information about the determined D2D resource configuration; or the information about the determined D2D resource configurations corresponding to the QoS levels can be transmitted to the UE by transmitting the information about the determined D2D resource configurations, and QoS level indication information to the UE, where the QoS level indication information indicates the QoS levels corresponding to the information about the determined D2D resource configurations. 
         [0138]    It shall be noted that the QoS levels or the D2D services corresponding to the information about the allocated D2D resource configurations may not be indicated. For example, if the resource request of the UE relates to one specific QoS level, then a D2D resource will be configured in response to the resource request, and information about the D2D resource configuration will be returned without carrying any D2D service indication information or QoS indication information. 
         [0139]    Further to the respective embodiments in the dedicated resource mode, the information about the D2D resource configurations can include but will not be limited to at least one of: 
         [0140]    Information about time-frequency resources among D2D resources; 
         [0141]    Information about MCS levels for use in transmission of data over D2D resources; 
         [0142]    Information about the numbers of retransmissions in transmission of data over D2D resources; and 
         [0143]    Information about transmit power in transmission of data over D2D resources. 
         [0144]    Taking an online scenario as an example, a preferred embodiment of the method for allocating a MD resource as a dedicated resource is as follows: 
         [0145]    The eNB receives a request of the UE for a dedicated resource of a D2D service, where the resource request carries information about a QoS level of the D2D service, determines the QoS level according to the information about the QoS level, and allocates a dedicated D2D resource for the QoS level, that is, determines a D2D resource configuration corresponding to the QoS level; and transmits information about the determined D2D resource configuration, and QoS level indication information to the UE, where reference can be made to the description of the embodiment above for the information about the D2D resource configuration, so a repeated description thereof will be omitted here. 
         [0146]      FIG. 3  illustrates a flow chart of a method for transmitting D2D data according to an embodiment of the application, where the method particularly includes the following operations: 
         [0147]    The step  300  is to select transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels. 
         [0148]    The step  310  is to transmit data of the D2D services over the selected transmission resources. 
         [0149]    In the method for transmitting D2D data according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0150]    The method for transmitting D2D data according to the embodiment of the application can be applicable to both a D2D discovery scenario and a D2D communication scenario. 
         [0151]    D2D resource allocation modes typically include the common resource pool mode and the dedicated resource mode. The method for transmitting D2D data according to the embodiment of the application will be described below taking these two modes respectively as examples. 
         [0152]    In the common resource pool mode: 
         [0153]    The transmission resources can be selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels by determining D2D resource pools corresponding to the QoS levels of the D2D services to be transmitted; and selecting the transmission resources in the determined D2D resource pools, for the D2D services to be transmitted, according to received information about D2D resource pool configurations corresponding to the respective QoS levels. 
         [0154]    Here the information about the D2D resource pool configurations corresponding to the respective QoS levels is received in advance. 
         [0155]    Particularly if there is a D2D service to be transmitted, then a higher layer at the UE side will transmit the D2D service to a lower layer while indicating information about a QoS level corresponding to the D2D service; and the lower layer at the UE side determines the QoS level of the D2D service according to the information about the QoS level, determines a D2D resource pool corresponding to the QoS level, and selects a transmission resource according to configuration information about the D2D resource pool. 
         [0156]    Taking non-line scenario as an example, a preferred embodiment of the method for transmitting D2D data in a common resource pool is as follows: 
         [0157]    If there are three QoS levels and D2D resource pools corresponding to the respective QoS levels in the system, then the UE will obtain information about resource pool configurations corresponding to these three QoS levels respectively from the eNB. 
         [0158]    If there is a demand of the higher layer of the UE for a D2D service to be transmitted, then the higher layer of the UE will transmit data of the D2D service to an Access Stratum (AS) (e.g., a Media Access Control (MAC) layer) while transmitting information about a QoS level corresponding to the D2D service to the Access Stratum (AS). 
         [0159]    The Access Stratum (AS) of the UE determines the QoS level of the D2D service according to the information about the QoS level, and further retrieves information about a D2D resource pool configuration corresponding to the QoS level, and selects a transmission resource according to the information about the D2D resource pool configuration. 
         [0160]    The Access Stratum (AS) of the UE transmits D2D data using a transmission parameter corresponding to the selected transmission resource at a select point of time. 
         [0161]    In the dedicated resource mode: 
         [0162]    A resource request is further sent before the transmission resources are selected for the D2D services to be transmitted, where the resource requests carries the information about the QoS levels of the D2D services to be transmitted; and the transmission resources can be selected for the D2D services to be transmitted according to the received information about the D2D resource configurations corresponding to the QoS levels by selecting the transmission resources for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted, where the information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted is transmitted by a resource request receiver in response to the resource request. 
         [0163]    Particularly if the resource request relates to some specific QoS level or D2D service, then a D2D resource indicated by received information about a D2D resource configuration will be determined as a transmission resource to be selected. If the resource request receiver further transmits D2D service indication information or QoS level indication information, then the transmission resource will be selected according to the indication information. 
         [0164]    Taking a on-line scenario as an example, a preferred embodiment of the method for transmitting D2D data over a dedicated resource is as follows: 
         [0165]    The UE sends a resource request carrying the information about the QoS levels to the eNB, and receives the information about the D2D resource configurations, and the QoS level indication information, fed back by the eNB to thereby obtain the information about the D2D resource configurations corresponding to the QoS level 1 and the QoS level 2 respectively. 
         [0166]    Here the UE can make the resource request in advance, or can make the resource request if there is a D2D service to be transmitted. 
         [0167]    The higher layer of the UE has data of a D2D service at the QoS level 1 to be transmitted, and transmits the data of the D2D service at the QoS level 1 to the Access Stratum (AS), and the Access Stratum (AS) of the UE selects a D2D transmission resource according to the Information about the D2D resource configuration corresponding to the QoS level 1, and transmits the data of the D2D service over the selected transmission resource by encapsulating only the data of the D2D service at the QoS level 1 into one MAC PDU and transmitting the MAC PDU both a transmission rule and a transmission parameter in the D2D resource configuration corresponding to the QoS level 1. 
         [0168]    Further to any one of the embodiments above of the method for transmitting D2D data, if there are a number of D2D services to be transmitted, then transmission resources can be selected only for those D2D services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted, or transmission resources can be selected for the D2D services to be transmitted by guaranteeing transmit power of preferentially those services to be transmitted at high QoS levels; or transmission resources can be selected for the D2D services to be transmitted by selecting transmission resources preferentially for those services to be transmitted at high QoS levels. 
         [0169]    Preferably if the number of D2D services allowed to be transmitted is less than the number of MD services to be transmitted, then transmission resources can be selected only for those services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted. 
         [0170]    Taking a on-line scenario as an example, another preferred embodiment of the method for transmitting D2D data over a dedicated resource is as follows: 
         [0171]    If the UE has concurrent D2D services at the QoS level 1, the QoS level 2, and the QoS level 3 to be transmitted, but only one D2D service is allowed to be transmitted via an air interface, then firstly a D2D service at a high QoS level will be transmitted. For example, if the QoS level 1 is the highest QoS level, then a transmission resource can be selected preferentially for the D2D service at the QoS level 1, and data of preferentially the D2D service at the QoS level 1 can be transmitted. If both the QoS level 1 and the QoS level 2 are the highest QoS levels, then a transmission resource can be selected for one of the D2D services, and data of the one D2D service can be transmitted, in around-robin manner, randomly, etc. 
         [0172]    Taking non-line scenario as an example, another preferred embodiment of the method for transmitting D2D data over a dedicated resource is as follows: 
         [0173]    The UE sends a resource request carrying the information about the QoS levels to the eNB, and receives the information about the D2D resource configurations, and the QoS level indication information, fed back by the eNB, where the UE can make the resource request in advance, or can make the resource request if there is a D2D service to be transmitted. 
         [0174]    If only one D2D service is allowed to be transmitted via the air interface, then firstly a D2D service at a high QoS level will be transmitted. 
         [0175]    For example, if the higher layer of the UE has D2D services at the QoS level 1 and the QoS level 2 to be transmitted, where the QoS level 1 is higher than the QoS level 2, then the higher layer of the UE can transmit only data of the D2D service at the QoS level 1 to the Access Stratum (AS) (or Access Stratum (AS)-based D2D service transmission level indication information); and for the QoS level 1, the Access Stratum of the UE can select a transmission resource for the D2D service at the QoS level 1 according to the received information about the D2D resource configuration, and QoS level indication information, and transmit the data of the D2D service at the QoS level 1 over the selected D2D transmission resource. 
         [0176]    For example, if the higher layer of the UE has D2D services at the QoS level 1, the QoS level 2, and the QoS level 3 to be transmitted, where the QoS level 1 is the same as the QoS level 2, and both of them are higher than the QoS level 3, then the higher layer of the UE can transmit data of the D2D service at the QoS level 1 or the QoS level 1 to the Access Stratum (AS) in a round-robin manner, randomly, etc. Reference can be made to the description of the previous embodiment for the process at the Access Stratum (AS), so a repeated description thereof will be omitted here. 
         [0177]    Preferably if there is limited transmit power of at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by guaranteeing the transmit power of preferentially those services to be transmitted at high QoS levels. 
         [0178]    Taking a on-line scenario as an example, another preferred embodiment of the method for transmitting D2D data over a dedicated resource is as follows: 
         [0179]    The UE sends a resource request carrying the information about the QoS levels to the eNB, and receives the information about the D2D resource configurations, and the QoS level indication information, fed back by the eNB, where the UE can make the resource request in advance, or can make the resource request if there is a D2D service to be transmitted. 
         [0180]    If the UE has concurrent D2D services at the QoS level 1 and the QoS level 2 being transmitted in the same sub-frame, and transmit power of the UE is limited, then the UE can perform a power back-off process by firstly guaranteeing the transmit power at which the D2D service at the QoS level 1 (i.e., a high QoS level) is transmitted. 
         [0181]    Preferably if available transmission resources can not satisfy a resource demand for at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by selecting a transmission resource preferentially for a service to be transmitted at a high QoS level. 
         [0182]    Further to any one of the embodiments above of the method for transmitting D2D data, preferably the transmission resources can be selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels as follows: if the transmission resources selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted can not satisfy transmission requirements of the D2D services to be transmitted, then the transmission resources can be selected for the D2D services to be transmitted, according to information about D2D resource configurations of low QoS levels which are lower than the QoS levels of the D2D services to be transmitted. 
         [0183]    Here the function of preempting a D2D resource of a D2D service at a low QoS level by a D2D service at a high QoS level can be configured by the access stratum node (e.g., the eNB, the CE, etc.), or can be enabled or disabled under a pre-configured condition. 
         [0184]    Taking a on-line scenario as an example, another preferred embodiment of the method for transmitting D2D data in a common resource pool is as follows: 
         [0185]    If the UE obtains information about D2D resource pool configurations corresponding to the QoS level 1 (a high QoS level) and a QoS level 2 respectively. 
         [0186]    The function of preempting a D2D resource of a D2D service at a low QoS level by a D2D service at a high QoS level has been configured by an access stratum resource control node, or can be pre-configured to be enabled. 
         [0187]    If the higher layer of the UE has a D2D service at the QoS level 1 to be transmitted, then the higher layer of the UE can transmit data of the D2D service to the Access Stratum (AS) (e.g., the MAC layer) of the UE while transmitting the information about the QoS level 1 to the Access Stratum (AS); and the Access Stratum (AS) of the UE can retrieve the information about the D2D resource pool configuration corresponding to the QoS level 1, and select a transmission resource according to the information about the D2D resource pool configuration, but may not select any appropriate transmission resource (possibly due to the busy service or other reasons), no the UE can further select a transmission resource according to the information about the D2D resource pool configuration corresponding to the QoS level 2, and if the transmission resource has been selected successfully in the D2D resource pool corresponding to the QoS level 2, then the UE can transmit the D2D service at the QoS level 1 according to the D2D resource pool configuration corresponding to the QoS level 2. 
         [0188]    Here the resource pool configuration corresponding to the QoS level 2 can be applied to all the configurations, or can be applied only to the time-frequency resource configuration in the resource pool corresponding to the QoS level 2, and the resource pool configuration corresponding to the QoS level 1 can still be applied to the other configurations. 
         [0189]    Taking non-line scenario as an example, another preferred embodiment of the method for transmitting D2D data over a dedicated resource is as follows: 
         [0190]    The UE sends a resource request carrying the information about the QoS levels to the eNB, and receives the information about the D2D resource configurations, and the QoS level indication information, fed back by the eNB to thereby obtain the information about the D2D resource configurations corresponding to the QoS level 1 and the QoS level 2 respectively. 
         [0191]    The function of preempting a D2D resource of a D2D service at a low QoS level by a D2D service at a high QoS level has been configured by an access stratum resource control node, or can be pre-configured to be enabled. 
         [0192]    The higher layer of the UE has data of a D2D service at the QoS level 1 to be transmitted, and the higher layer of the UE transmits the data of the D2D service to the Access Stratum (AS) (i.e., the MAC layer) of the UE while transmitting the information about the QoS level 1 to the Access Stratum (AS); and the Access Stratum (AS) of the UE selecting a transmission resource detects that a D2D resource corresponding to the QoS level 1 is being accessed by data of another D2D service at the QoS level 1 (or a time-frequency resource which can be available soon is a D2D resource corresponding to the QoS level 2), then the Access Stratum (AS) of the UE can select the D2D resource configuration corresponding to the QoS level 2 directly, and transmit the data of the D2D service at the QoS level 1. 
         [0193]    Here the resource pool configuration corresponding to the QoS level 2 can be applied to all the configurations, or can be applied only to the time-frequency resource configuration in the resource pool corresponding to the QoS level 2, and the resource pool configuration corresponding to the QoS level 1 can still be applied to the other configurations, 
         [0194]    Based upon the same inventive idea as the method above, an embodiment of the application provides an apparatus for allocating a D2D resource, and as illustrated in  FIG. 4 , the apparatus includes: 
         [0195]    A D2D resource configuring module  401  is configured to determine D2D resource configurations corresponding to QoS levels; and 
         [0196]    A D2D resource configuration information transmitting module  402  is configured to transmit information about the determined D2D resource configurations corresponding to the QoS levels to a UE. 
         [0197]    In the apparatus for allocating a D2D resource according to the embodiment of the application, a D2D resource is configured according to a QoS level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0198]    In the common resource pool mode, preferably the D2D resource configuring module  401  is particularly configured to determine D2D resource pool configurations corresponding to the respective QoS levels; and the D2D resource configuration information transmitting module  402  is particularly configured to transmit information about the D2D resource pool configurations corresponding to the respective QoS levels to the UE. Further to this, the information about the D2D resource pool configurations includes at least one of: 
         [0199]    Information about time-frequency resources in the D2D resource pools; 
         [0200]    Information about resource configuration periodicities of the D2D resource pools; 
         [0201]    Information about offsets of the D2D resource pools; 
         [0202]    Information about MCS levels for use in transmission of data over resources in the D2D resource pools; 
         [0203]    Information about the numbers of retransmissions in transmission of data over resources in the D2D resource pools; 
         [0204]    Information about power allocation in transmission of data over resources in the D2D resource pools; and 
         [0205]    Parameters related to a collision detection mechanism for use in selection among resources in D2D resource pools. 
         [0206]    Here the resources in the resource pools corresponding to the different QoS levels may be different. Alternatively resources in a resource pool of a high QoS level include resources in a resource pool of a low QoS level, for example, the information about the time-frequency resources in the resource pool of the high QoS level include the information about the time-frequency resources in the resource pool of the low QoS level. 
         [0207]    In order to ensure reasonable division of resources into the respective QoS levels, the D2D resource pool configurations corresponding to the respective QoS levels need to be maintained. They can be maintained by an access stratum node, e.g., an eNB, a UE, a network element, etc., which can function as a central control node, or a resource control node at another access stratum; or they can be maintained by a higher-layer node, e.g., a ProSe node. Preferably the D2D resource pool configurations corresponding to the respective QoS levels can be maintained by detecting the amounts of transmitted service data over the resources in the respective D2D resource pools, judging the reasonability about division of the resources into the different QoS levels, and adjusting the resources in the resource pools corresponding to the different QoS levels according to a result of judgment for the reasonability about division of the resources. Optionally the apparatus for allocating a D2D resource according to the embodiment of the application further includes a D2D resource configuration maintaining module configured to maintain the D2D resource pool configurations corresponding to the respective QoS levels, and reference can be made to the description above of the maintenance of the D2D resource pool configurations for details thereof. 
         [0208]    In the dedicated resource mode, preferably the D2D resource configuring module  401  is particularly configured to receive a resource request of the UE, carrying information about the QoS levels; and to determine the D2D resource configurations corresponding to the QoS levels indicated by the information about the QoS levels. Accordingly the D2D resource configuration information transmitting module  402  is particularly configured to transmit the information about the determined D2D resource configurations, and D2D service indication information to the UE, where the D2D service indication information indicates D2D services corresponding to the information about the determined D2D resource configuration; or to transmit the information about the determined D2D resource configurations, and QoS level indication information to the UE, where the QoS level indication information indicates the QoS levels corresponding to the information about the determined D2D resource configurations. 
         [0209]    In the dedicated resource mode, preferably the information about the D2D resource configurations can include but will not be limited to at least one of: 
         [0210]    Information about time-frequency resources among D2D resources; 
         [0211]    Information about MCS levels for use in transmission of data over D2D resources; 
         [0212]    Information about the numbers of retransmissions in transmission of data over D2D resources; and 
         [0213]    Information about transmit power transmission of data over D2D resources. 
         [0214]    Based upon the same inventive idea as the application, an embodiment of the application further provides an access stratum resource control node, and as illustrated in  FIG. 5 , the access stratum resource control node includes a processor  501  and a radio frequency unit  502 , where: 
         [0215]    The processor  501  is configured to determine D2D resource configurations corresponding to QoS levels; and 
         [0216]    The radio frequency unit  502  is configured to transmit information about the determined D2D resource configurations corresponding to the QoS levels to a UE. 
         [0217]    The access stratum resource control node according to the embodiment of the application can include but will not be limited to an eNB, a central control node, etc. 
         [0218]    In the access stratum resource control node according to the embodiment of the application, a D2D resource is configured according to a QoS level of a D2D service, and information about the D2D resource configuration corresponding to the QoS level of the D2D service is transmitted to the UE. Stated otherwise, the D2D resource can be allocated for the UE by taking into account a transmission demand for the D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0219]    Based upon the same inventive idea as the application, an embodiment of the application further provides an apparatus for transmitting D2D data, and as illustrated in  FIG. 6 , the apparatus includes: 
         [0220]    A D2D transmission resource selecting module  601  is configured to select transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels; and 
         [0221]    A D2D data transmitting module  602  is configured to transmit data of the D2D services over the selected transmission resources. 
         [0222]    In the apparatus for transmitting D2D data according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0223]    In the common resource pool mode, preferably the D2D transmission resource selecting module  601  is particularly configured to determine D2D resource pools corresponding to the QoS levels of the D2D services to be transmitted; and to select the transmission resources in the determined D2D resource pools, for the D2D services to be transmitted, according to received information about D2D resource pool configurations corresponding to the respective QoS levels. 
         [0224]    In the dedicated resource mode, preferably the apparatus for transmitting D2D data according to the embodiment of the application can further include a resource requesting module configured to send a resource request carrying information about the QoS levels of the D2D services to be transmitted; and the D2D transmission resource selecting module  601  is particularly configured to select the transmission resources for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted, where the information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted is transmitted by a resource request receiver in response to the resource request. 
         [0225]    Further to any one of the embodiments above of the apparatus for transmitting D2D data, if there are a number of D2D services to be transmitted, then transmission resources can be selected only for those D2D services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted, or transmission resources can be selected for the D2D services to be transmitted by guaranteeing transmit power of preferentially those services to be transmitted at high QoS levels; or transmission resources can be selected for the D2D services to be transmitted by selecting transmission resources preferentially for those services to be transmitted at high QoS levels. 
         [0226]    Preferably if the number of D2D services allowed to be transmitted is less than the number of D2D services to be transmitted, then transmission resources can be selected only for those services to be transmitted at high QoS levels, and service data of only those D2D services can be transmitted. 
         [0227]    Preferably if there is limited transmit power of at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by guaranteeing the transmit power of preferentially those services to be transmitted at high QoS levels. 
         [0228]    Preferably if available transmission resources can not satisfy a resource demand for at least two D2D services to be transmitted, then transmission resources can be selected for the D2D services to be transmitted, by selecting a transmission resource preferentially for a service to be transmitted at a high QoS level. 
         [0229]    Further to any one of the embodiments above of the apparatus for transmitting D2D data, preferably the D2D transmission selecting module  601  is particularly configured, if the transmission resources selected for the D2D services to be transmitted, according to the received information about the D2D resource configurations corresponding to the QoS levels of the D2D services to be transmitted can not satisfy transmission requirements of the D2D services to be transmitted, to select the transmission resources for the D2D services to be transmitted, according to information about D2D resource configurations of low QoS levels which are lower than the QoS levels of the D2D services to be transmitted. 
         [0230]    Based upon the same inventive idea as the application, an embodiment of the application further provides a user equipment, and as illustrated in  FIG. 7 , the user equipment includes a processor  701  and a radio frequency unit  702 , where: 
         [0231]    The processor  701  is configured to select transmission resources for D2D services to be transmitted, according to received information about D2D resource configurations corresponding to QoS levels; and 
         [0232]    The radio frequency unit  702  is configured to transmit data of the D2D services over the selected transmission resources. 
         [0233]    In the user equipment according to the embodiment of the application, a D2D transmission resource is selected according to a QoS level. Stated otherwise, the D2D transmission resource can be selected by taking into account a transmission demand for a D2D service so that the QoS of D2D transmission can be guaranteed based upon the correspondence relationship between the QoS level and the D2D resource, so (particularly in the case of CSMA) a transmission resource for transmitting a service with a high required QoS will not be preempted by the D2D service with a low required QoS so that the former service will not be blocked, and the efficiency of allocating a D2D resource of the system can be further improved without discouraging the transmission demand for the D2D service. 
         [0234]    Those skilled in the art shall appreciate that the embodiments of the application can be embodied as a method, a system or a computer program product. Therefore the application can be embodied in the form of an all-hardware embodiment, an all-software embodiment or an embodiment of software and hardware in combination. Furthermore the application can be embodied in the form of a computer program product embodied in one or more computer useable storage mediums (including but not limited to a disk memory, a CD-ROM, an optical memory, etc.) in which computer useable program codes are contained. 
         [0235]    The application has been described in a flow chart and/or a block diagram of the method, the device (system) and the computer program product according to the embodiments of the application. It shall be appreciated that respective flows and/or blocks in the flow chart and/or the block diagram and combinations of the flows and/or the blocks in the flow chart and/or the block diagram can be embodied in computer program instructions. These computer program instructions can be loaded onto a general-purpose computer, a specific-purpose computer, an embedded processor or a processor of another programmable data processing device to produce a machine so that the instructions executed on the computer or the processor of the other programmable data processing device create means for performing the functions specified in the flow(s) of the flow chart and/or the block(s) of the block diagram. 
         [0236]    These computer program instructions can also be stored into a computer readable memory capable of directing the computer or the other programmable data processing device to operate in a specific manner so that the instructions stored in the computer readable memory create an article of manufacture including instruction means which perform the functions specified in the flow(s) of the flow chart and/or the block(s) of the block diagram. 
         [0237]    These computer program instructions can also be loaded onto the computer or the other programmable data processing device so that a series of operational steps are performed on the computer or the other programmable data processing device to create a computer implemented process so that the instructions executed on the computer or the other programmable device provide steps for performing the functions specified in the flow(s) of the flow chart and/or the block(s) of the block diagram. 
         [0238]    Although the preferred embodiments of the application have been described, those skilled in the art benefiting from the underlying inventive concept can make additional modifications and variations to these embodiments. Therefore the appended claims are intended to be construed as encompassing the preferred embodiments and all the modifications and variations coming into the scope of the application. 
         [0239]    Evidently those skilled in the art can make various modifications and variations to the application without departing from the spirit and scope of the application. Thus the application is also intended to encompass these modifications and variations thereto so long as the modifications and variations come into the scope of the claims appended to the application and their equivalents.