I am struggling to implement this concept correctly,

enter image description hereso basically the concept in there is that a global time is ongoing, and each stations randomly transmit data in any slot (so I have to create a simulation with packets coming from station A and B in random time) when packet arrive it senses media is free or not by first sending DIFS to see if media is free and then send RTS to control media and then sends data. Meanwhile station B should sees media is busy and should wait. I am like lost on what could be best approach to implement it, I looked at producer consumer concept in python, but it does not synchronize well in my logic flow. Any ideas/directions with examples will be highly appreciated.

New contributor
Sal is a new contributor to this site. Take care in asking for clarification, commenting, and answering. Check out our Code of Conduct.
  • I would start by defining what it is that you want to accomplish. Do you want to read existing data with this format and process it? Do you want to create a communications infrastructure with it? What exactly do you want to do? – Robert Harvey Oct 10 at 19:09
  • I updated it, in a simple approach I can read certain data set and use it as my frames arrival time, but in actual scenario I would like to create a simulation with global time, and frames arriving at random interval and transmitting without collision. So i can simply assume, Difs, SIFS, ACK to be 1 time slot and frame to be 100, slots in that time B should stay idle and wait – Sal Oct 10 at 19:19
  • Is your problem how to represent these frames in code, or is it something else? – Robert Harvey Oct 10 at 20:18
  • Correct, how to represent it in code, and the best approach towards it, likes libraries I can make use of, builtin functions or anything to implement the algorithm. – Sal Oct 10 at 20:39

Your Answer

Sal is a new contributor. Be nice, and check out our Code of Conduct.

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.