def __init__(self, *args, **kwds):
# Setup the NCS object, containing mechanisms
# for communicating between NCS and this User code.
self._ncs = NcsPyVM(*args, **kwds)
# Just checking if the NCS logging works...
self.debug('Initalizing object')
# Register our 'finish' callback
self._finish_cb = lambda: self.finish()
self._ncs.reg_finish(self._finish_cb)
self.mypipe = os.pipe()
self.waithere = threading.Semaphore(0) # Create as blocked
# This method starts the user application in a thread
评论列表
文章目录