Skip to content

Instantly share code, notes, and snippets.

@rdeva31
Last active March 23, 2017 22:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rdeva31/930a1d07a14059769159f47b3708f0ce to your computer and use it in GitHub Desktop.
Save rdeva31/930a1d07a14059769159f47b3708f0ce to your computer and use it in GitHub Desktop.
Script to stress test MG1
from nodelib.utils import get_config
import logging.config
import logging
logging.config.dictConfig(get_config('/etc/nodelib.conf')['logging'])
log = logging.getLogger('Mg1Test')
from nodelib.system.common.mg1 import *
import sys
sys.excepthook = sys.__excepthook__
with MG1:
while True:
MG1.mode(MG1DeviceType.Bluetooth)
print(MG1.firmware_version())
MG1.mode(MG1DeviceType.Thread)
print(MG1.firmware_version())
@rdeva31
Copy link
Author

rdeva31 commented Mar 23, 2017

@rowanc ^^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment