The error model provided by ns can introduce errors into packets created by Agents like TCP or UDP. It cannot introduce errors at the lower layers. In order to test our acknowledgement mechanism, we introduce an error model that produces random errors in (simulated) RLC PDUs ie for slot level transmissions.
This error model (in bs_recv()) marks a randomly chosen RLC fragment (either going up or down) as erroneous. This causes the packet to be dropped at its destination. At each drop, we use Random::integer(error_rate_) to decide the next drop.
The user may choose to include this error model through rlc_error_ in the OTcl script. The error_rate_ can also be set by the user from the OTcl script.