A simulator of the CSMA protocol