Pixel Kit List of Commands

dialValue:

Stores the last dial value. This value is always between 0 and 4095


isPressingUp:

Stores if the joystick up is being pressed. This value is False or True


isPressingDown:

Stores if the joystick down is being pressed. This value is False or True


isPressingLeft:

Stores if the joystick left is being pressed. This value is False or True


isPressingRight:

Stores if the joystick right is being pressed. This value is False or True


isPressingClick:

Stores if the joystick click is being pressed. This value is False or True


isPressingA:

Stores if the button A is being pressed. This value is False or True


isPressingB:

Stores if the button B is being pressed. This value is False or True


checkControls():

Update all button values and dial value


checkJoystick():

Update only joystick buttons values


checkButtons():

Update only buttons values


checkDial():

Update only dial value


onJoystickUp():

Called when joystick up is pressed


onJoystickDown():

Called when joystick down is pressed


onJoystickLeft():

Called when joystick left is pressed


onJoystickRight():

Called when joystick right is pressed


onJoystickClick():

Called when joystick click is pressed


onButtonA():

Called when button A is pressed


onButtonB():

Called when button B is pressed


onDial(dialValue):

Called when dial value has changed


setPixel(x, y, color):

Set the pixel on x, y with the color in the format [red, green, blue] where red, green and blue are the amount of those colors you want in our final color. Values can be between 0 and 100 but after 20 you might need eye protection.


setBackground(color):

Set background to color


clear():

Set background to black (turn off all LEDs)


render():

Render the pixels on the screen. Previous drawing methods won’t change the LEDs until render() is called.