Skip to content
This repository has been archived by the owner on Dec 1, 2020. It is now read-only.

Mousepad Object

Tim edited this page Jan 27, 2017 · 2 revisions

Functions and constants included in the Chroma Mousepad object:

Initialize:

Mousepad = Chroma.Mousepad()

Functions:

setColor

sets the Mousepad-LED-Grid to one color.

Usage: setColor(Color)

Example:

Mousepad.setColor(RED) or Mousepad.setColor((255,0,0)) //RGB for RED

setbyLED

sets a specific LED of the Mousepad-LED-Grid to one color.

Usage: setbyLED(LED, Color)

Example:

Mousepad.setbyLED(3,RED) or Mousepad.setbyLED(3,(255,0,0)) //RGB for RED

clearLED

clears the Mousepad-LED-Grid.

Usage: clearLED()

Example:

Mousepad.clearLED()

applyLED

applies the Mousepad-LED-Grid to the Mousepad.

Usage: applyLED()

Example:

Mousepad.applyLED()

setBreathing

sets the Mousepad to Breathing.

Usage: Usage: setBreathing(mode,Color1,Color2)

Mode: 1 - two colors, 0 - random colors

Example:

Mousepad.setBreathing(1,RED,GREEN) or Mousepad.setBreathing(0,0,0)

setWave

sets the Mousepad to Wave.

Usage: setWave(direction)

Direction: 1 - left to right, 2 - right to left

Example:

Mousepad.setWave(1)

resetEffect

resets the current Chroma-Effect.

Usage: resetEffect()

Example:

Mousepad.resetEffect()

Constants:

MaxLED

Maximum LEDs of the Mousepad-LED-Grid. Hint: Use this as iteration borders.

Example:

Mousepad.MaxLED