METHOD FOR CONTROLLING TRANSMISSION SPEED OF MULTI-CAST PACKETS
First Claim
1. A method for controlling transmission speed of multi-cast packets, used for enabling a network interface card (NIC) to transmit a plurality of multi-cast packets at a target speed, and the method for controlling the transmission speed of the multi-cast packets comprises:
- calculating a standard time according to sizes of the multi-cast packets and the target speed, and recording an accumulated error time;
transmitting one of the multi-cast packets, and calculating a transmission time of the transmitted multi-cast packet;
calculating a difference between the standard time and the transmission time, recording the difference between the standard time and the transmission time as a current error time, adding the accumulated error time and the current error time, and recording the add result as a preset sleep time; and
when the preset sleep time is greater than an error threshold value, performing following steps;
sleeping for the preset sleep time;
being waked from sleep, and calculating a practical sleep time;
calculating a difference between the preset sleep time and the practical sleep time, and using the difference between the preset sleep time and the practical sleep time as the new accumulated error time; and
returning to the step of calculating the standard time according to the sizes of the multi-cast packets and the target speed, and recording the accumulated error time, so as to transmit the next one of the multi-cast packets.
2 Assignments
0 Petitions
Accused Products
Abstract
A transmission speed controlling method for multi-cast packets includes the steps of calculating a standard time, and recording an accumulated error time; transmitting one of the multi-cast packets, and calculating a transmission time of the transmitted multi-cast packet; calculating a difference between the standard time and the transmission time, recording the difference as a current error time, adding the accumulated error time and the current error time, and recording the add result as a preset sleep time; and performing the following steps when the preset sleep time is greater than an error threshold value, wherein the following steps are sleeping for the preset sleep time; being awaked from sleep, and calculating a practical sleep time; calculating a new accumulated error time by subtracting the practical sleep time from the preset sleep time; and returning to the first step to transmit the next one of the multi-cast packets.
7 Citations
7 Claims
-
1. A method for controlling transmission speed of multi-cast packets, used for enabling a network interface card (NIC) to transmit a plurality of multi-cast packets at a target speed, and the method for controlling the transmission speed of the multi-cast packets comprises:
-
calculating a standard time according to sizes of the multi-cast packets and the target speed, and recording an accumulated error time; transmitting one of the multi-cast packets, and calculating a transmission time of the transmitted multi-cast packet; calculating a difference between the standard time and the transmission time, recording the difference between the standard time and the transmission time as a current error time, adding the accumulated error time and the current error time, and recording the add result as a preset sleep time; and when the preset sleep time is greater than an error threshold value, performing following steps; sleeping for the preset sleep time; being waked from sleep, and calculating a practical sleep time; calculating a difference between the preset sleep time and the practical sleep time, and using the difference between the preset sleep time and the practical sleep time as the new accumulated error time; and returning to the step of calculating the standard time according to the sizes of the multi-cast packets and the target speed, and recording the accumulated error time, so as to transmit the next one of the multi-cast packets. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
Specification