| 32 | |
| 33 | #if defined (ESP8266) || defined(ESP32) |
| 34 | bool SGP30::begin(uint8_t dataPin, uint8_t clockPin) |
| 35 | { |
| 36 | _wire = &Wire; |
| 37 | if ((dataPin < 255) && (clockPin < 255)) |
| 38 | { |
| 39 | _wire->begin(dataPin, clockPin); |
| 40 | } else { |
| 41 | _wire->begin(); |
| 42 | } |
| 43 | if (! isConnected()) return false; |
| 44 | return true; |
| 45 | } |
| 46 | #endif |
| 47 | |
| 48 |