intrig-unicamp / mininet-wifi

Emulator for Software-Defined Wireless Networks
https://mn-wifi.readthedocs.io/
Other
431 stars 239 forks source link

Can I modify def getCustomRate(self) in mn-wif/link.py ? #430

Closed larryliu2018 closed 2 years ago

larryliu2018 commented 2 years ago

Thank you very much for your open source project, I have a question for you. Because I want to set the rate of 802.11b to 11Mbit/s and the rate of 802.11g to 54Mbit/s; but I found through debug that the setting in the master branch is def getCustomRate(self): mode_rate = {'a': 11, 'b': 3, 'g':11, 'n': 600, 'n2': 600, 'ac': 1000, 'ax2': 500, 'ax5': 700, 'ax': 1000, 'ad': 1000} return mode_rate.get(self.mode); Now, I set it to def getCustomRate(self): mode_rate = {'a': 54, 'b': 11, 'g': 54, 'n': 600, 'n2': 600, 'ac': 1000, 'ax2': 500, 'ax5': 700, 'ax': 1000, 'ad': 1000} return mode_rate.get(self.mode); I don't know if I changed it this way correctly?

ramonfontes commented 2 years ago

This works if you don't use wmediumd. bw parameter should also work in scenarios without mobility.

larryliu2018 commented 2 years ago

I see, thank you very much for your prompt answer