Revision a9c0f9f5d04965175bce6a60dae3ddc243b8b738

HW/IT/GTE_Tabletop/Documentation/index

Changes from a9c0f9f5d04965175bce6a60dae3ddc243b8b738 to 8f6a56b37e65bee2a63f1c78804598808a9ef013

---
format:markdown
...

# Help on module gte\_control:

## NAME

    gte\_control

=======
# Help on module gte\_control:

## NAME

    gte\_control

>>>>>>> a9c0f9f5d04965175bce6a60dae3ddc243b8b738
## DATA

    ### home - folder where file is executing

    ### noscp = False
     
    ### IP = "http://192.168.254.2/" - ip adress of quido eth

<<<<<<< edited
    ### osc\_ip = '192.168.254.10' - ip adress of osciloscope

    ### sc = 1 - relay for shortcutting the condenser, defualt is shortcutted
    ### ch = 2 - relay for charging the condenser
    ### trig = 6 - relay for simulating trigger
    ### cur\_stab = 7 - relay for switching curent stability, defualt is no stabilization, currently unused
    ### dch = 8 - relay for conecting condenser to discharging circuits
=======
    ###osc_ip = '192.168.254.10' - ip adress of osciloscope

    ### sc = 1 - relay for shortcutting the condenser, defualt is shortcutted
    ### ch = 2 - relay for charging the condenser
    ###trig = 6 - relay for simulating trigger
    ### cur_stab = 7 - relay for switching curent stability, defualt is no stabilization, currently unused
    ### dch = 8 - relay for conecting condenser to discharging circuits

    ### u_coil = 1 - osciloscope channel with coil voltage
>>>>>>> a9c0f9f5d04965175bce6a60dae3ddc243b8b738

    ### u\_coil = 1 - osciloscope channel with coil voltage

FUNCTIONS
    add_num(num, name='counter.txt')

## FUNCTIONS
    ### add_num(num, name='counter.txt')

        Adds 1 to num ands saves as shot number into counter file.
        Input:
        num -- int, number of previous shot
        name = counter.txt -- string, name of file containign counter
    
    charge(wait=2, url='http://192.168.254.2/', shortcut=1, charging=2)
    ### charge(wait=2, url='http://192.168.254.2/', shortcut=1, charging=2)

        Charges condenser.
        Input:
            wait = 2 -- duration of charging in seconds
            url = IP -- ip adress of I/O module
            shortcut = sc -- number of relay switching shortcutting
            charging = ch -- number of relay switching charging
    
    close_all(url='http://192.168.254.2/')
    ### close_all(url='http://192.168.254.2/')

        Switches all relays to defaul position, called 'off'.
        Input:
            url = IP -- ip adress of I/O module
    
    discharge(wait=0.5, stab=False, url='http://192.168.254.2/', disch=8, cstab=7, delay=0.1)
        Discharges condenser.
        Input:
            wait = 0.5 -- delay between opening discharging relay and shortcutting condenser
            stab_i = False -- toggles current stabilisation
            url = IP -- ip adress of I/O module
            disch = dch -- number of relay switching discharging
            thyr = th --number of relay switching thyristor
    
    get_num(name='counter.txt')
        Loads shot number from file.
        Input:
        name = counter.txt -- string, name of file containign counter
    
    input_read(num, url='http://192.168.254.2/')
        Gets input messured on I/O module's input numbered num
        Input:
            num -- number of input
            url = IP -- ip adress of I/O module
        Output:
            val -- int, 1 or 0 representing logical values on or off
    
    make_graphs(graphs, save=False)
    
    shot(wait=0.1, chwait=2, dchwait=0.5, url='http://192.168.254.2/', stab_i=False, cstab=7, graphs=[], save=False, noscope=False)
        Executes Golem tokamak like shot: charges and discharges condenser.
        Input:
            wait = 0.1 -- delay between charge and discharge in seconds
            chwait = 2 -- duration of charging in seconds
            dchwait = 0.5 -- duration of discharge in seconds
            url = IP -- ip adress of I/O module
            stab_i = False -- toggles current stabilisation
            cstab = cur_stab -- number of relay switching current stabilisation on
            graphs = [] -- numbers of channels on osciloscope to be ploted
            save = False -- enables saving graphs to file
            noscope = False -- disables osciloscope
        Output:
            none or graphs
    
    switch_off(num, url='http://192.168.254.2/')
        Switches off relay numbered num.
        Input:
            num -- number of relay to be switched
            url = IP -- ip adress of I/O module
    
    switch_on(num, url='http://192.168.254.2/')
        Switches on relay numbered num.
        Input:
            num -- number of relay to be switched
            url = IP -- ip adress of I/O module