update constants

This commit is contained in:
Siwat Sirichai 2022-04-01 17:39:15 +07:00
parent 5c1caffc64
commit 43226a9046
2 changed files with 5 additions and 4 deletions

View File

@ -1,3 +1,4 @@
import multiprocessing
from tkinter import TOP from tkinter import TOP
import pyautogui import pyautogui
import scipy.cluster as cluster import scipy.cluster as cluster
@ -25,8 +26,8 @@ MIN_TIME = 0.05
METHOD = 'MEDIAN' #MEAN/MEDIAN/MODE/CLUSTER_MEAN, WARNING: CLUSTER_MEAN might burn down your house. METHOD = 'MEDIAN' #MEAN/MEDIAN/MODE/CLUSTER_MEAN, WARNING: CLUSTER_MEAN might burn down your house.
SATURATION_BOOST_FACTOR = 2 SATURATION_BOOST_FACTOR = 2
NUM_CLUSTERS = 3 NUM_CLUSTERS = 3
KMEAN_QUALITY = 50 KMEAN_QUALITY = 50
NUM_THREADS = 16 NUM_THREADS = 8
if __name__ == '__main__': if __name__ == '__main__':
board = telemetrix_rpi_pico.TelemetrixRpiPico() board = telemetrix_rpi_pico.TelemetrixRpiPico()

View File

@ -21,8 +21,8 @@ timecounter = 0
while(True): while(True):
for j in range(0,NUM_LEDS): for j in range(0,NUM_LEDS):
r, g, b = colorsys.hsv_to_rgb(((-timecounter*VELOCITY+j*4)%360)/360,1,1) r, g, b = colorsys.hsv_to_rgb(((-timecounter*VELOCITY+j*2)%360)/360,1,1)
board.neo_pixel_set_value(j,r=int(r*255),g=int(g*255),b=int(b*255)) board.neo_pixel_set_value(j,r=int(r*255),g=int(g*255),b=int(b*255))
timecounter+=1 timecounter+=1
delay(0.1) delay(0.05)
board.neopixel_show() board.neopixel_show()