forked from zietzm/Helmholtz_Test_Bench
5f23c71bff
- added checkbox for ambient field compensation - moved part of axis setup to axis.__init__
33 lines
1008 B
Python
33 lines
1008 B
Python
import numpy as np
|
|
|
|
XY_DEVICE = None
|
|
Z_DEVICE = None
|
|
|
|
X_AXIS = None # object structure: (device, channel, arduino pin, axis index)
|
|
Y_AXIS = None
|
|
Z_AXIS = None
|
|
|
|
AXES = None # list containing [X_AXIS, Y_AXIS, Z_AXIS]
|
|
|
|
# Constants:
|
|
COIL_CONST = np.array([38.6, 38.45, 37.9]) * 1e-6 # Coil constants [x,y,z] in T/A
|
|
AMBIENT_FIELD = np.array([30, 30, 30]) * 1e-6 # ambient magnetic field in measurement area, to be cancelled out
|
|
RESISTANCES = np.array([1.7, 1.7, 1.7]) # resistance of [x,y,z] circuits
|
|
MAX_WATTS = np.array([15, 15, 15]) # max. allowed power for [x,y,z] circuits
|
|
MAX_VOLTS = [16, 16, 16] # max. allowed voltage, limited to 16V by used diodes!
|
|
|
|
# COM-Ports for power supply units:
|
|
XY_PORT = "COM10" # placeholders
|
|
Z_PORT = "COM11"
|
|
|
|
AXIS_NAMES = ["X-Axis", "Y-Axis", "Z-Axis"]
|
|
ports = [XY_PORT, XY_PORT, Z_PORT]
|
|
|
|
ARDUINO = None
|
|
|
|
RELAY_PINS = [15, 16, 17] # pin on the Arduino for switching relay of each axis [x,y,z]
|
|
|
|
app = None
|
|
|
|
# ToDo: make proper settings file to read from and write to
|