mirror of
https://github.com/brendanhaines/ECEN5458_Project.git
synced 2024-11-09 21:14:47 -07:00
WIP: remove if main
This commit is contained in:
parent
62952cfd5e
commit
7e7ffffd64
|
@ -13,7 +13,6 @@ from bokeh.layouts import column, row
|
||||||
from bokeh.models import ColumnDataSource, Slider, TextInput, Button
|
from bokeh.models import ColumnDataSource, Slider, TextInput, Button
|
||||||
from bokeh.plotting import figure
|
from bokeh.plotting import figure
|
||||||
|
|
||||||
if __name__ == "__main__":
|
|
||||||
mux_io = [None] * 4
|
mux_io = [None] * 4
|
||||||
mux_io[0] = digitalio.DigitalInOut(board.D17)
|
mux_io[0] = digitalio.DigitalInOut(board.D17)
|
||||||
mux_io[1] = digitalio.DigitalInOut(board.D27)
|
mux_io[1] = digitalio.DigitalInOut(board.D27)
|
||||||
|
@ -60,25 +59,25 @@ if __name__ == "__main__":
|
||||||
brightness = [get_normalized_reflectivity(c) for c in range(8)]
|
brightness = [get_normalized_reflectivity(c) for c in range(8)]
|
||||||
plt_source.data = dict(x=brightness_idx, y=brightness)
|
plt_source.data = dict(x=brightness_idx, y=brightness)
|
||||||
|
|
||||||
# def cal_white(*args, **kwargs):
|
def cal_white(*args, **kwargs):
|
||||||
# global white_cal
|
global white_cal
|
||||||
# white_cal = [get_reflectivity(c) for c in range(8)]
|
white_cal = [get_reflectivity(c) for c in range(8)]
|
||||||
# update_data()
|
update_data()
|
||||||
|
|
||||||
# def cal_black(*args, **kwargs):
|
def cal_black(*args, **kwargs):
|
||||||
# global black_cal
|
global black_cal
|
||||||
# black_cal = [get_reflectivity(c) for c in range(8)]
|
black_cal = [get_reflectivity(c) for c in range(8)]
|
||||||
# update_data()
|
update_data()
|
||||||
|
|
||||||
# cal_white_button = Button(label="Cal White")
|
cal_white_button = Button(label="Cal White")
|
||||||
# cal_white_button.on_click(cal_white)
|
cal_white_button.on_click(cal_white)
|
||||||
# cal_black_button = Button(label="Cal Black")
|
cal_black_button = Button(label="Cal Black")
|
||||||
# cal_black_button.on_click(cal_black)
|
cal_black_button.on_click(cal_black)
|
||||||
|
|
||||||
# controls = column(cal_white_button, cal_black_button)
|
controls = column(cal_white_button, cal_black_button)
|
||||||
|
|
||||||
# curdoc().add_root(row(controls, plot, width=800))
|
curdoc().add_root(row(controls, plot, width=800))
|
||||||
curdoc().add_root(row(plot, width=800))
|
# curdoc().add_root(row(plot, width=800))
|
||||||
curdoc().title = "test"
|
curdoc().title = "test"
|
||||||
|
|
||||||
# while True:
|
# while True:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user