I recently added more temp probes and they are working fine displayed on the LCD, but since they aren't bytes they don't display as the temp in ascii. Can you and if so, how do you code to display the temperature? Maybe only the rounded to the whole number if it won't handle the decimal?
Thanks,
-Jon
Custom variable temp
- jsclownfish
- Posts: 375
- Joined: Mon Oct 24, 2011 7:52 pm
- Location: Saint Louis
Re: Custom variable temp
Not sure I follow.
Temperature should be decimal just like the other ones.
Temperature should be decimal just like the other ones.
Roberto.
- jsclownfish
- Posts: 375
- Joined: Mon Oct 24, 2011 7:52 pm
- Location: Saint Louis
Re: Custom variable temp
Yes, it looks fine on the LCD, but I want to track them as a custom variable. It looks like the custom variable is a byte.
-Jon
-Jon
Re: Custom variable temp
Those custom variables being bytes are a pain! When can we turn that into ints Roberto (or better yet floats!)
Jon, try dividing the number by 10 and it should fit in the byte, you just won't have the precision but you'll be inside a degree which should work ok, no?
Jon, try dividing the number by 10 and it should fit in the byte, you just won't have the precision but you'll be inside a degree which should work ok, no?
Re: Custom variable temp
I wonder if we could use two variables, one to represent the whole number part and another to represent the decimal part?
Like custom variable 1 would equal 78 and custom variable 2 would equal 10 to represent 78.1.
--Colin
Like custom variable 1 would equal 78 and custom variable 2 would equal 10 to represent 78.1.
--Colin
Re: Custom variable temp
Yes i just can't think of the math this early. Seems a big waste to me though on variable usage. Would still like to see this change to int. too easy to wrap with only a byte. Have hit that too many times.
- jsclownfish
- Posts: 375
- Joined: Mon Oct 24, 2011 7:52 pm
- Location: Saint Louis
Re: Custom variable temp
In my case, I just put my 'less important' temperature probes in the custom variables where the whole number temp is sufficient. I can't afford to use other custom variable slots for the decimal as I have them all tied up with other measurable (flow meters, lights, etc). Maybe more custom variables are in future plans???
-Jon

-Jon