So I was under the impression that Analog pins can work fine as Digital I/O pins.
I set up a one-wire temperature sensor to use one.
And it hangs completely. Cannot even re-flash.
This could of course be my code, hardware, or libraries.
And I did have some compile issues at first.
I am using
Particle Verison of OneWire Libary v2.2
Spark-dallas temp library, v 3.7.2
OH: And I am trying to connect TWO of them.
int one_wire_temp_pool = A0; // Pin int one_wire_temp_solr = A2; // Pin OneWire oneWire_pool(one_wire_temp_pool); OneWire oneWire_solr(one_wire_temp_solr); DallasTemperature sensors_pool(&oneWire_pool); DallasTemperature sensors_solr(&oneWire_solr); ... sensors_pool.requestTemperatures(); delay(100); tempc_pool = sensors_pool.getTempCByIndex(0);
Any ideas where to look first would be welcome.
Or should I not use A0/A3.
I have a 4.7K resistor on each.