Skip to content

Latest commit

 

History

History
53 lines (37 loc) · 1.35 KB

File metadata and controls

53 lines (37 loc) · 1.35 KB
title Press the Button
layout text-width-sidebar
meta-description How to use buttons and if conditions on the micro:bit in Python.
simple-description Microbit Buttons
share true
comments true
author jez
strapline Use the buttons to make a message
aboutbox Using the buttons on the front of the microbit to display a message
cats medium
date 2016-12-23 10:20:00 UTC
date-updated 2016-12-23 10:20:00 UTC

{% highlight python %} {% include_relative code/press-the-button.py %} {% endhighlight %}

Going Further

{: .ui .dividing .header}

The micro:bit api lists other images that can be drawn on the display. The Image class predefined images which can be used with display.show():

display.show(Image.HAPPY)

  • Image.HEART
  • Image.HEART_SMALL
  • Image.HAPPY
  • Image.SILLY

There is a full list on the API. Or use the display module and display a picture.