Ejemplo n.º 1
0
def RUN_Experiment():
    global logbool
    confirmBox.disable()
    confirmBox.hide()
    close_Exp_Conf()
    print("Running")
    #	prime_log()

    progress_Win.enable()
    progress_Win.show()

    abort_exp_button.enable()
    abort_exp_button.show()
    logbool = 1

    flowCmd = flow.SetPoint_Write(flow.Exp_flow_Rate)
    s.write(flowCmd)

    flow.create_filename()
    updateBox = Box(progressBox)
    updateBox.repeat(2000, Update_Progress)
Ejemplo n.º 2
0
def namefile():
    global file_name
    file_name = log.create_filename()
    logbox = Box(gui)
    logbox.repeat(3000, test1)
Ejemplo n.º 3
0
    if ChkUsrInputX.chkUsrNum(flowtext.value):
        #s.write(flow.SetPoint_Write(flowtext.value))
        print("Worked")
    else:
        # Error message
        warn("Oops", "Not a Valid Number.")


file_op = [["File", file_Exit], ["file2", get_Text]]
edit_op = [["log window", log_window], ["edit2", get_Text]]
app = App(title="Mass Flow Control")
menuebar = MenuBar(app, ["File", "Edit"], [file_op, edit_op])
box = Box(app)
box.bg = "red"
box.height = 200
box.repeat(1000, counter)
#logbox.repeat(1000,log_data )
#box.tk.configure(height =200, width = 200, background = "blue")
#for child in box.tk.winfo_children():
#	child.configure(background="blue")

text1 = Text(box, text="Hello box")
#text1.tk.configure(background="blue")
Message = Text(app, text="Sierra Instruments Micro Trak 101")
text = Text(app)
button = PushButton(app, text="Enter", command=get_Text)
#mywindow = Window(app, title = "Flow")
mytext = Text(app, text="The SetPoint is ")
flowtext = Text(app)
Cmd = Text(app)
input_box = TextBox(app, text="0.000")
Ejemplo n.º 4
0
controls_title = Text(controls, text="Controls", size=18)
temp_title = Text(controls, text="Temperature", size=12)
temp_slider = Slider(controls)
temp_slider.text_size = 7
simple_title = Text(controls, text="Simple Controls for Boiler", size=12)
simple_radio = ButtonGroup(controls,
                           options=["on", "off"],
                           horizontal=True,
                           selected=actions.get_on_or_off())
vacation = CheckBox(controls, text="Vacation Settings")
always_on = CheckBox(controls, text="Always On")
update = PushButton(
    controls,
    text="Update Settings",
    padx=5,
    pady=5,
    command=actions.change_state,
    args=[temp_slider, simple_radio, vacation, always_on],
)
update.bg = "blue"
controls.repeat(10000,
                actions.update_gui,
                args=[temp_slider, simple_radio, vacation, always_on])

data = Box(app, grid=[1, 2], width=240, height=210)
data.bg = "beige"
data_title = Text(data, text="Data", size=18)
graph = Picture(data, image="test.png", width=150, height=150)
data.repeat(900000, actions.update_graph, args=[graph])
app.display()
Ejemplo n.º 5
0
              bg=base_color,
              layout="auto")
    button_box = Box(app, width="fill", height=40, align="bottom")
    message_box = Box(app, border=4, height="fill", width="fill")
    message_box.bg = (255, 255, 255)
    message = TextBox(message_box,
                      multiline=True,
                      width="fill",
                      height=350,
                      visible=True)
    message.text_size = 16
    chat = ChatHandlerWS()

    btn_connect = PushButton(button_box,
                             text="Connect",
                             align="left",
                             command=connection_button,
                             args=[chat],
                             width=20,
                             height=30,
                             visible=True,
                             padx=2,
                             pady=2)
    btn_connect.text_size = 18
    btn_connect.bg = "white"
    btn_connect.show()
    notify = Notifications()
    message_box.repeat(Notifications.CHECK_LOOP_MS, verify_chat, [chat])
    app.display()
    closing(chat)