propreté
This commit is contained in:
parent
b92fbe42af
commit
ee50a8eb44
3 changed files with 5 additions and 7 deletions
|
@ -150,11 +150,10 @@ class GCodeToMotors:
|
|||
# HARDWARE.realize() applies the current commands to the actual hardware
|
||||
|
||||
def move(self):
|
||||
#self.HARDWARE.probe(self)
|
||||
#while not self.CONTROLLER(self): # Allow controller to alter self
|
||||
# self.HARDWARE.realize(self)
|
||||
self.HARDWARE.probe(self)
|
||||
while not self.CONTROLLER(self): # Allow controller to alter self
|
||||
self.HARDWARE.realize(self)
|
||||
|
||||
self.current_units = self.target_units.copy() # Too good to be true
|
||||
self.calculate_deltas()
|
||||
|
||||
def calculate_feedrate_delay(self, feedrate: float) -> float:
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
import socket
|
||||
import os
|
||||
|
||||
import GCode_Interpreterdc
|
||||
import simulator
|
||||
|
||||
class Hardware:
|
||||
def __init__(self, bind):
|
||||
|
|
|
@ -120,7 +120,8 @@ class NaiveSimulator(Simulator, Douche):
|
|||
x_v = parse_speed(socket.SocketIO(self.s, 'r').readline())
|
||||
y_v = parse_speed(socket.SocketIO(self.s, 'r').readline())
|
||||
z_v = parse_speed(socket.SocketIO(self.s, 'r').readline())
|
||||
|
||||
self.speed = np.array([x_v, y_v, z_v])
|
||||
|
||||
inertia = - self.alpha * self.speed
|
||||
gamma_command = np.array([x_v, y_v, z_v]) - self.speed
|
||||
self.speed = self.time_step * (inertia + gamma_command)
|
||||
|
|
Loading…
Reference in a new issue