A data transmission method for device-to-device communications performed by a first device, the method comprising the steps of: • determining a frequency hopping parameter and a maximum quantity of retransmission times Nm of to-be-transmitted data, wherein the frequency hopping parameter comprises: ∘ an initial frequency hopping location comprising a first start location n VRB,1 at which a frequency hopping over first subframes starts, the first subframes having corresponding subframe indices forming a first set, Set 1, and comprising a second start location n VRB,2 at which a frequency hopping over second subframes starts, the second subframes having corresponding subframe indices forming a second set, Set 2, ∘ wherein in a first alternative: the Set 1 includes even subframe indices and Set 2 includes odd subframe indices, or wherein in a second alternative: the Set 1 includes odd subframe indices and Set 2 includes even subframe indices, ∘ a bandwidth N D2D-Tx_BW of the to-be-transmitted data configured for use during a data transmission in a device to device, D2D communication between the first device and a second device, ∘ a frequency hopping offset N offset, ∘ a total bandwidth N RB D 2 ⁢ D configured for use during the D2D communication between the first device and the second device (step 301); • determining for each subframe of the Set 1 and the Set 2 a first start location for the to-be-transmitted data according to the following formula: n PRB i = { n VRB, 1 + mN offset mod N RB D 2 ⁢ D i ∈ Set 1 N RB D 2 ⁢ D − 1 − n VRB, 2 − N D 2 ⁢ D − Tx _ BW − mN offset mod N RB D 2 ⁢ D i ∈ Set 2, wherein n PRB ( i) indicates a location of the to-be-transmitted data within an i-th subframe, m indicates a current quantity of retransmissions of the to-be transmitted data and is a value from 0 to Nm-1 and Nm is the maximum quantity of retransmission times of the to be transmitted data, thereby determining multiple first start locations, (step 302) • sending the to-be-transmitted data Nm times on those subframes having subframe indices of the Set 1 and the Set 2 to the second device at the multiple first start locations and with the bandwidth N D2D-Tx_BW of the to-be-transmitted data, thereby performing the D2D communication with the second device. • determining a frequency hopping parameter and a maximum quantity of retransmission times Nm of to-be-transmitted data, wherein the frequency hopping parameter comprises: ∘ an initial frequency hopping location comprising a first start location n VRB,1 at which a frequency hopping over first subframes starts, the first subframes having corresponding subframe indices forming a first set, Set 1, and comprising a second start location n VRB,2 at which a frequency hopping over second subframes starts, the second subframes having corresponding subframe indices forming a second set, Set 2, ∘ wherein in a first alternative: the Set 1 includes even subframe indices and Set 2 includes odd subframe indices, or wherein in a second alternative: the Set 1 includes odd subframe indices and Set 2 includes even subframe indices, ∘ a bandwidth N D2D-Tx_BW of the to-be-transmitted data configured for use during a data transmission in a device to device, D2D communication between the first device and a second device, ∘ a frequency hopping offset N offset, ∘ a total bandwidth N RB D 2 ⁢ D configured for use during the D2D communication between the first device and the second device (step 301); ∘ an initial frequency hopping location comprising a first start location n VRB,1 at which a frequency hopping over first subframes starts, the first subframes having corresponding subframe indices forming a first set, Set 1, and comprising a second start location n VRB,2 at which a frequency hopping over second subframes starts, the second subframes having corresponding subframe indices forming a second set, Set 2, ∘ wherein in a first alternative: the Set 1 includes even subframe indices and Set 2 includes odd subframe indices, or wherein in a second alternative: the Set 1 includes odd subframe indices and Set 2 includes even subframe indices, the Set 1 includes even subframe indices and Set 2 includes odd subframe indices, or wherein in a second alternative: the Set 1 includes odd subframe indices and Set 2 includes even subframe indices, ∘ a bandwidth N D2D-Tx_BW of the to-be-transmitted data configured for use during a data transmission in a device to device, D2D communication between the first device and a second device, ∘ a frequency hopping offset N offset, ∘ a total bandwidth N RB D 2 ⁢ D configured for use during the D2D communication between the first device and the second device (step 301); • determining for each subframe of the Set 1 and the Set 2 a first start location for the to-be-transmitted data according to the following formula: n PRB i = { n VRB, 1 + mN offset mod N RB D 2 ⁢ D i ∈ Set 1 N RB D 2 ⁢ D − 1 − n VRB, 2 − N D 2 ⁢ D − Tx _ BW − mN offset mod N RB D 2 ⁢ D i ∈ Set 2, wherein n PRB ( i) indicates a location of the to-be-transmitted data within an i-th subframe, m indicates a current quantity of retransmissions of the to-be transmitted data and is a value from 0 to Nm-1 and Nm is the maximum quantity of retransmission times of the to be transmitted data, thereby determining multiple first start locations, (step 302) • sending the to-be-transmitted data Nm times on those subframes having subframe indices of the Set 1 and the Set 2 to the second device at the multiple first start locations and with the bandwidth N D2D-Tx_BW of the to-be-transmitted data, thereby performing the D2D communication with the second device.