rfemu_amarisoftctrl: import websocket module on first use
Change-Id: I568af52ffb7ac57222697f5d861a532c0e2a70de
This commit is contained in:
parent
326091555b
commit
a8b8990bb8
|
@ -18,7 +18,6 @@
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
import json
|
import json
|
||||||
from websocket import create_connection
|
|
||||||
|
|
||||||
from ..core import log
|
from ..core import log
|
||||||
from .rfemu import RFemulation
|
from .rfemu import RFemulation
|
||||||
|
@ -40,6 +39,8 @@ class RFemulationAmarisoftCtrl(RFemulation):
|
||||||
self.cell_id = conf.get('cell_id')
|
self.cell_id = conf.get('cell_id')
|
||||||
if self.cell_id is None:
|
if self.cell_id is None:
|
||||||
raise log.Error('No "cell_id" attribute provided in supply conf!')
|
raise log.Error('No "cell_id" attribute provided in supply conf!')
|
||||||
|
|
||||||
|
from websocket import create_connection
|
||||||
self.ws = create_connection("ws://%s:%s" % (self.addr, self.port))
|
self.ws = create_connection("ws://%s:%s" % (self.addr, self.port))
|
||||||
|
|
||||||
def __del__(self):
|
def __del__(self):
|
||||||
|
|
Loading…
Reference in New Issue