diff --git a/OpenSprinkler.cpp b/OpenSprinkler.cpp index 6e0f9855..0a22de92 100644 --- a/OpenSprinkler.cpp +++ b/OpenSprinkler.cpp @@ -364,7 +364,7 @@ unsigned char OpenSprinkler::iopts[] = { 100,// this and next byte define flow pulse rate (100x) 0, // default is 1.00 (100) 0, // set as remote extension - 8, // this and the next three byte define the custom dns server ip + 8, // this and the next three bytes define the custom dns server ip 8, 8, 8, @@ -429,7 +429,7 @@ bool detect_i2c(int addr) { bool OpenSprinkler::load_hardware_mac(unsigned char* buffer, bool wired) { #if defined(ESP8266) WiFi.macAddress((unsigned char*)buffer); - // if requesting wired Ethernet MAC, flip the last unsigned char to create a modified MAC + // if requesting wired Ethernet MAC, flip the last byte to create a modified MAC if(wired) buffer[5] = ~buffer[5]; return true; #else diff --git a/utils.cpp b/utils.cpp index 60c28174..b9209ec1 100644 --- a/utils.cpp +++ b/utils.cpp @@ -424,14 +424,14 @@ ulong water_time_resolve(uint16_t v) { } // encode a 16-bit signed water time (-600 to 600) -// to unsigned unsigned char (0 to 240) +// to unsigned byte (0 to 240) unsigned char water_time_encode_signed(int16_t i) { i=(i>600)?600:i; i=(i<-600)?-600:i; return (i+600)/5; } -// decode a 8-bit unsigned unsigned char (0 to 240) +// decode a 8-bit unsigned byte (0 to 240) // to a 16-bit signed water time (-600 to 600) int16_t water_time_decode_signed(unsigned char i) { i=(i>240)?240:i;