What is the constant ARDUINO for? it used to be 22 but is now 100 -
i using thermocouples , downloaded max6675 library. wondered value of arduino constant in following lines for.
#if arduino >= 100 lcd.write((byte)0); #else lcd.print(0, byte); #endif lcd.print("c "); lcd.print(thermocouple.readfahrenheit()); #if arduino >= 100 lcd.write((byte)0); #else lcd.print(0, byte); #endif lcd.print('f');
i have searched answer have turned little info. can print out value following line, still can't find out means.
serial.println(arduino);
the arduino
constant gives version of arduino environment being used.
for example, 22
old arduino 22 ide , 100
version 1.0 of arduino environment. value of arduino
constant in latest arduino release (1.6.5) appears 10605.
there significant changes in arduino apis between old versions (e.g. 22) , 1.0 release. value of arduino
can used conditionally compile different code different versions of api.
in example appears in version 1.0+ environment need use lcd.write()
in old environments had use lcd.print
. testing value of arduino
allows same code work in both environments.
Comments
Post a Comment