Announcement

Collapse
No announcement yet.

Turn off logging for all z-wave devices

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • widert
    replied
    Originally posted by SteveMSJ View Post

    I think what you are doing wrong is clearing the Enums.dvMISC.NO_LOG flag. You want to Set the flag if you don't want the device to log commands.

    Steve
    Oh, embarrassing, thank you!

    Leave a comment:


  • SteveMSJ
    replied
    Originally posted by widert View Post
    Hello, does anybody know how I can turn off all logging? I've been trying this script with limited success:

    Code:
    sub Main(ByVal Parm As Object)
    
    Try
    'run through the enumerator, remove the location two strings
    
    Dim dv As Scheduler.Classes.DeviceClass
    Dim EN As Scheduler.Classes.clsDeviceEnumeration
    
    EN = hs.GetDeviceEnumerator
    
    Do
    dv = EN.GetNext
    If dv Is Nothing Then Continue Do
    If dv.Interface(Nothing).ToLower = "z-wave" Then
    hs.writelog("Log ZDev Start", "Device: " & dv.Name(Nothing))
    dv.MISC_Clear(hs, Enums.dvMISC.NO_LOG)
    System.Threading.Thread.Sleep(50)
    End If
    
    Loop Until EN.Finished
    
    Catch ex As Exception : hs.writelog("Device Clear", "Exception: " & ex.message)
    End Try
    
    End Sub
    I think what you are doing wrong is clearing the Enums.dvMISC.NO_LOG flag. You want to Set the flag if you don't want the device to log commands.

    Steve

    Leave a comment:


  • widert
    started a topic Turn off logging for all z-wave devices

    Turn off logging for all z-wave devices

    Hello, does anybody know how I can turn off all logging? I've been trying this script with limited success:

    Code:
    sub Main(ByVal Parm As Object)
    
    Try
    'run through the enumerator, remove the location two strings
    
    Dim dv As Scheduler.Classes.DeviceClass
    Dim EN As Scheduler.Classes.clsDeviceEnumeration
    
    EN = hs.GetDeviceEnumerator
    
    Do
    dv = EN.GetNext
      If dv Is Nothing Then Continue Do
      If dv.Interface(Nothing).ToLower = "z-wave" Then
          hs.writelog("Log ZDev Start", "Device: " & dv.Name(Nothing))
          dv.MISC_Clear(hs, Enums.dvMISC.NO_LOG)
          System.Threading.Thread.Sleep(50)
      End If
    
    Loop Until EN.Finished
    
    Catch ex As Exception : hs.writelog("Device Clear", "Exception: " & ex.message)
    End Try
    
    End Sub
Working...
X