Singer Instruments PIXL Client
UV Sterilisation
This topic assumes that there is an instance of the PIXLClient object called pixl. If this is not the case, please see the Connecting To The PIXL topic.

The PIXL features dual ultraviolet bulbs that can be used to sterilise the inside 'working' area and its head.

UV sterilisation can be invoked by calling the RunUVSterilisation method on the PIXLClient.

Running UV sterilisation for 20 minutes
Copy Code
pixl.RunUVSterilisation(20);

This will asynchronously run UV sterilisation on the PIXLClient. The RunUVSterilisation method return an instance of the ApiCommandResponse structure, which can be used to determine the result of the initialisation.

Running UV sterilisation for 20 minutes and checking the result
Copy Code
var result = pixl.RunUVSterilisation(20).Result;

if (result.IsSuccess)
    Console.WriteLine("UV Sterilisation Complete.");
else
    Console.WriteLine($"UV Sterilisation failed with code {result.Code}, because {result.Message}");

Alternatively, the RunUVSterilisation method can be provided with a callback of type ApiCommandResponseCallback which is invoked when the result from the RunUVSterilisation method is obtained.

Running UV sterilisation for 20 minutes with a callback
Copy Code
pixl.RunUVSterilisation(20, x => System.Console.WriteLine(x.Message));

 

See Also

Getting Started

Reference