original_docstring:  Auto enroll the PowerMax/Master unit 
docstring: Auto enroll the PowerMax/Master unit
docstring_tokens: Auto enroll the PowerMax / Master unit
code: def SendMsg_ENROLL(self):
          """ Auto enroll the PowerMax/Master unit """
          if not self.doneAutoEnroll:
              self.doneAutoEnroll = True
              #yield from asyncio.sleep(1.0)
              sleep(1.0)
              log.info("[SendMsg_ENROLL]  download pin will be " + self.toString(DownloadCode))
              # Remove anything else from the List, we need to restart
              self.pmExpectedResponse = []
              # Clear the list
              self.ClearList()
  
              # The 3 and 4 ignore 0x0D header. Is this 3 or 4.  4 according to Lua plugin but 3 according to https://www.domoticaforum.eu/viewtopic.php?f=68&t=6581
              self.SendCommand("MSG_ENROLL",  options = [4, DownloadCode])
  
              # We are doing an auto-enrollment, most likely the download failed. Lets restart the download stage.
              if self.DownloadMode:
                  log.debug("[SendMsg_ENROLL] Resetting download mode to 'Off' in order to retrigger it")
                  self.DownloadMode = False
              self.Start_Download()
          else:
              log.warning("Warning: Trying to re enroll and it is only allowed once at the start")
code_tokens: def SendMsg_ENROLL ( self ) : if not self . doneAutoEnroll : self . doneAutoEnroll = True sleep ( 1.0 ) log . info ( "[SendMsg_ENROLL]  download pin will be " + self . toString ( DownloadCode ) ) self . pmExpectedResponse = [ ] self . ClearList ( ) self . SendCommand ( "MSG_ENROLL" , options = [ 4 , DownloadCode ] ) if self . DownloadMode : log . debug ( "[SendMsg_ENROLL] Resetting download mode to 'Off' in order to retrigger it" ) self . DownloadMode = False self . Start_Download ( ) else : log . warning ( "Warning: Trying to re enroll and it is only allowed once at the start" )
short_docstring: Auto enroll the PowerMax/Master unit
short_docstring_tokens: Auto enroll the PowerMax / Master unit
comment: """ Auto enroll the PowerMax/Master unit """$SEP$#yield from asyncio.sleep(1.0)$SEP$# Remove anything else from the List, we need to restart$SEP$# Clear the list$SEP$# The 3 and 4 ignore 0x0D header. Is this 3 or 4.  4 according to Lua plugin but 3 according to https://www.domoticaforum.eu/viewtopic.php?f=68&t=6581$SEP$# We are doing an auto-enrollment, most likely the download failed. Lets restart the download stage.