コード例 #1
0
 public async Task<bool> SetLamp(int ledNumber, int r, int g, int b)
 {
     var ledDetails = new HolidayLampColorRGB {value = new[] {r, g, b}.ClampValues()};
     return await Put(String.Format(holidayGetLedValueEndpoint, ledNumber), JsonConvert.SerializeObject(ledDetails));
 }
コード例 #2
0
 // base 
 public async Task<bool> SetLamp(int r, int g, int b)
 {
     var lampColor = new HolidayLampColorRGB { value = new[] { r, g, b }.ClampValues() };
     return await Put(holidaySetLampColorEndpoint, JsonConvert.SerializeObject(lampColor));
 }