pxt-calliope/docs/lessons/temperature.md

36 lines
1001 B
Markdown
Raw Normal View History

2016-03-26 00:47:20 +01:00
# temperature blocks lesson
2016-04-02 01:22:47 +02:00
measure the temperature on the BBC micro:bit.
2016-03-26 00:47:20 +01:00
## Topic
Temperature
## Quick Links
* [activity](/microbit/lessons/temperature/activity)
* [challenges](/microbit/lessons/temperature/challenges)
## Prior learning/place of lesson in scheme of work
Learn how to get the ambient temperature (degree Celsius °C). The temperature is inferred from the the surface temperature of the various chips on the micro:bit. We will be learning how to get the temperature using on shake, local variables, as well as simple commands such as show number.
## Documentation
2016-03-30 01:17:34 +02:00
```docs
input.temperature()
let x = 0
basic.showNumber(7)
basic.showString("Hello!")
input.onGesture(Gesture.Shake, () => {
})
```
2016-03-26 00:47:20 +01:00
## Objectives
* learn how to create a variable to store data
* learn how to get the ambient temperature (degree Celsius °C). The temperature is inferred from the the surface temperature of the various chips on the micro:bit.
* learn how to show a number on the LED screen