Post on 12-Jul-2020
Draft Texas Instruments September 27, 2017
Mood Ring Project example program
for TI-84 Plus CE OS 5.3
Draft Texas Instruments September 27, 2017
Background: Example Program Send "CONNECT TEMPERATURE 1 TO IN 1 AS NTC”4“Connect Temperature sensor #1 to Input port #1”44For(C,1,30)4“For loop repeats 30 times”4Send("READ TEMPERATURE 1”)4“Reads the value for Temperature sensor #1”4Get(T)4Disp T4Wait 14“Gets to variable d then displays the value of T, then Waits 1 second”4If T<26 4“Compares values of variable d to determine and show mood”4Then4Send "SET COLOR 255 0 0”4Disp ”MY MOOD IS RED”4End4If T≥26 and T<27 4Then4Send "SET COLOR 0 255 0”4Disp ”MY MOOD IS GREEN”4EndIf4If T>27 4Then4Send "SET COLOR 0 0 255”4Disp ”MY MOOD IS BLUE”4End4End$4Send "SET COLOR 0 0 0”4“Turns the COLOR OFF”4
Additional Challenges • Add more than three moods. • Add variables and logic so that the
program will automatically adapt to each person’s temperature range.
• Store the temperatures values and the time to list variables. Display a plot of time vs. temperature after the For loop is done.
• Replace the For loop with a While loop and use getKey with the CLEAR key to exit the loop.
Note: Experiment with temperature values to determine relevant temperature ranges for each person.
Draft Texas Instruments September 27, 2017
Background: Mood Ring Project