This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

clearLED

Clear the data displayed on the LED on BBC micro:bit

Syntax

clearLED(microbitObj)

Description

example

clearLED(microbitObj) clears the data displayed on the LED matrix on the BBC micro:bit, specified as a microbit object.

Examples

collapse all

Autodetect and connect to a BBC micro:bit board.

microbitObj = microbit
microbitObj = 
  microbit with properties:

                  Port: "COM4"
  AvailableDigitalPins: ["P0-P16"]
      AvailablePWMPins: ["P0-P10", "P12-P16"]
   AvailableAnalogPins: ["P0-P4", "P10"] 
    AvailableI2CBusIDs: 1
    AvailableSPIBusIDs: 1
Show all properties, functions, latest values

Display the Happy Face image on the LED matrix.

writeLED(microbitObj, MicrobitImages.HappyFace)

Clear the image on the LED matrix.

clearLED(microbitObj)

Input Arguments

collapse all

BBC micro:bit hardware connection, specified as a microbit object created with the microbit function.

See Also

|

Introduced in R2017b