Skip to content

Latest commit

 

History

History
56 lines (37 loc) · 1.41 KB

README.md

File metadata and controls

56 lines (37 loc) · 1.41 KB

#ColorBit driver

makecode pxt of ColorBit Tranditional Chinese version because of makecode bug: load zh folder for both zh-CN and zh-TW at present

once the makecode bug fix, this extension will merge into ColorBit

ColorBit:

Alt text

Basic Usage

let colorbit_51bit: colorbit.Strip = null
input.onButtonPressed(Button.A, function () {
    colorbit_51bit.showColorIcon(ColorIcon.ChristmasTree, colorbit.colors(BitColors.Red))
})
input.onButtonPressed(Button.AB, function () {
    colorbit_51bit.setMultiColor(false)
})
input.onButtonPressed(Button.B, function () {
    colorbit_51bit.showScrollStringColor("ABC#$123", colorbit.colors(BitColors.Red))
})
colorbit_51bit = colorbit.initColorBit(DigitalPin.P0, BitColorMode.RGB)
basic.forever(function () {

})

Use ||initColorBit|| to init ColorBit.

Use ||showColorIcon|| to show ColorBit icons.

Use ||setMultiColor|| to set multiple color per light.

Use ||showScrollStringColor|| to show scroll colorful string in ColorBit.

Alt text Alt text Alt text

Gif demo

Show single color string

Alt text

Show multiple color string

Alt text

Supported targets

  • for PXT/microbit

License

MIT