Hi, everyone. Now I am do a study in the area of FEC rate control mechanism, I just think out rate control based on the throughput capacity. Sender checks the throughput capacity and estimates the available bandwidth how much it can use. then sender calculate the FEC coding rate based on the throughput data. Such as, when the network is better, sender will send more FEC redundancy packet, or else, it will reduce the redundancy packet rate. Above is my idea, however, I dont know how to do that in NS2. About how to program between Mac layer and Application layer. Can someone give me a guide to do that or give me suggestion on that idea? I have been in this problem for 1 month. Really waiting for your help, and thanx very much.