1 Gig Nic カードの帯域幅を正確に計算する式が必要です。私がやっていることは、レイヤー 2 パケット @ 1Gbps を送信することですが、私のソフトウェアは 6oo Mbps を示しています。
実験全体は背中合わせです。スイッチもルーターもありません。
これが私がしたことです。
// LinkSpeed = 1Gb
UINT nBandwidth = LinkSpeed/100;//Mbps
nBandwidth = nBandwidth/8; //Bytes/sec
nBandwidth = nBandwidth/FrameLength;
//Frames/Sec. Frame Length = 1518
UINT FramesPerBurst = (nBandwidth*Sleeptime)/1000;
//Frames/Burst
UINT nBufferSpaceNeededPerFrame = FrameLength-4 + sizeof(dump_bpf_hdr));
UINT nTxBufferSize = FramesPerBurst * nBufferSpaceNeededPerFrame;
unsigned char* pTxBuffer = new
unsigned char[m_nTxBufferSize];