# Color Mixer

Change the color of the LED ring by RGB values. We'll use touchpad 0, 1, and 2 to control each of the values.

![](https://2169521322-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2Fpakronics-education%2F-Lpg0r0jyU3XQdgAmqp8%2F-Lpg5O76IisYU_HWDjPX%2F0.png?generation=1569476678784352\&alt=media)

**Introduction to HaloCode's touchpads**

HaloCode has four touchpads.

![](https://2169521322-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2Fpakronics-education%2F-Lpg0r0jyU3XQdgAmqp8%2F-Lpg5O77owYDbeUVMVIo%2F1.png?generation=1569476678847909\&alt=media)

**Toggle on Upload mode**

Click to toggle on Upload mode

![](https://2169521322-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2Fpakronics-education%2F-Lpg0r0jyU3XQdgAmqp8%2F-Lpg5O78S4ufz1ot-KCt%2F2.gif?generation=1569476678990880\&alt=media)

**Program touchpads**

1\. Drag an Events block when HaloCode starts up to the Scripts area，and then add a Control block forever。

![](https://2169521322-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2Fpakronics-education%2F-Lpg0r0jyU3XQdgAmqp8%2F-Lpg5O79N66lfav5MAku%2F3.gif?generation=1569476678838574\&alt=media)

2\. Add a Lighting block light up all LEDs with color R()G()B()and three Sensing blocks touchpad () value. Choose touchpad 0, 1, and 2

![](https://2169521322-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2Fpakronics-education%2F-Lpg0r0jyU3XQdgAmqp8%2F-Lpg5O7AqMI_9IcLtGEd%2F4.gif?generation=1569476678886544\&alt=media)

3\. Upload the program
