Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
MarlinKimbra
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
machinery
MarlinKimbra
Commits
e7267fe5
Commit
e7267fe5
authored
Oct 28, 2015
by
MagoKimbra
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix Dondolo
parent
5cc5f404
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
28 deletions
+22
-28
Marlin_main.cpp
MarlinKimbra/Marlin_main.cpp
+9
-13
stepper.cpp
MarlinKimbra/stepper.cpp
+12
-14
stepper.h
MarlinKimbra/stepper.h
+1
-1
No files found.
MarlinKimbra/Marlin_main.cpp
View file @
e7267fe5
...
@@ -6950,26 +6950,22 @@ inline void gcode_T(uint8_t tmp_extruder) {
...
@@ -6950,26 +6950,22 @@ inline void gcode_T(uint8_t tmp_extruder) {
active_driver
=
0
;
active_driver
=
0
;
ECHO_LMV
(
DB
,
MSG_ACTIVE_COLOR
,
(
int
)
active_extruder
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_COLOR
,
(
int
)
active_extruder
);
#elif ENABLED(DONDOLO)
#elif ENABLED(DONDOLO)
active_extruder
=
target_extruder
;
st_synchronize
();
active_driver
=
0
;
servo
[
DONDOLO_SERVO_INDEX
].
attach
(
0
);
if
(
active_extruder
==
0
)
{
if
(
target_extruder
==
0
)
{
st_synchronize
();
servo
[
DONDOLO_SERVO_INDEX
].
attach
(
0
);
servo
[
DONDOLO_SERVO_INDEX
].
write
(
DONDOLO_SERVOPOS_E0
);
servo
[
DONDOLO_SERVO_INDEX
].
write
(
DONDOLO_SERVOPOS_E0
);
delay
(
DONDOLO_SERVO_DELAY
);
servo
[
DONDOLO_SERVO_INDEX
].
detach
();
}
}
else
if
(
active_extruder
==
1
)
{
else
if
(
target_extruder
==
1
)
{
st_synchronize
();
servo
[
DONDOLO_SERVO_INDEX
].
attach
(
0
);
servo
[
DONDOLO_SERVO_INDEX
].
write
(
DONDOLO_SERVOPOS_E1
);
servo
[
DONDOLO_SERVO_INDEX
].
write
(
DONDOLO_SERVOPOS_E1
);
delay
(
DONDOLO_SERVO_DELAY
);
servo
[
DONDOLO_SERVO_INDEX
].
detach
();
}
}
delay
(
DONDOLO_SERVO_DELAY
);
servo
[
DONDOLO_SERVO_INDEX
].
detach
();
active_extruder
=
target_extruder
;
active_driver
=
0
;
set_stepper_direction
(
true
);
set_stepper_direction
(
true
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_DRIVER
,
active_driver
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_DRIVER
,
active_driver
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_EXTRUDER
,
active_extruder
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_EXTRUDER
,
active_extruder
);
#else
#else
active_driver
=
active_extruder
=
target_extruder
;
active_driver
=
active_extruder
=
target_extruder
;
ECHO_LMV
(
DB
,
MSG_ACTIVE_EXTRUDER
,
active_extruder
);
ECHO_LMV
(
DB
,
MSG_ACTIVE_EXTRUDER
,
active_extruder
);
#endif // end MKR4 || NPR2 || DONDOLO
#endif // end MKR4 || NPR2 || DONDOLO
...
...
MarlinKimbra/stepper.cpp
View file @
e7267fe5
...
@@ -576,24 +576,22 @@ void set_stepper_direction(bool onlye) {
...
@@ -576,24 +576,22 @@ void set_stepper_direction(bool onlye) {
#if DISABLED(ADVANCE) && ENABLED(DONDOLO)
#if DISABLED(ADVANCE) && ENABLED(DONDOLO)
if
(
TEST
(
out_bits
,
E_AXIS
))
{
if
(
TEST
(
out_bits
,
E_AXIS
))
{
if
(
active_extruder
==
0
)
{
switch
(
active_extruder
)
{
REV_E_DIR
();
case
0
:
count_direction
[
E_AXIS
]
=
-
1
;
REV_E_DIR
();
break
;
}
case
1
:
else
{
NORM_E_DIR
();
break
;
NORM_E_DIR
();
count_direction
[
E_AXIS
]
=
-
1
;
}
}
count_direction
[
E_AXIS
]
=
-
1
;
}
}
else
{
else
{
if
(
active_extruder
==
0
)
{
switch
(
active_extruder
)
{
NORM_E_DIR
();
case
0
:
count_direction
[
E_AXIS
]
=
1
;
NORM_E_DIR
();
break
;
}
case
1
:
else
{
REV_E_DIR
();
break
;
REV_E_DIR
();
count_direction
[
E_AXIS
]
=
1
;
}
}
count_direction
[
E_AXIS
]
=
1
;
}
}
#elif DISABLED(ADVANCE)
#elif DISABLED(ADVANCE)
if
(
TEST
(
out_bits
,
E_AXIS
))
{
if
(
TEST
(
out_bits
,
E_AXIS
))
{
...
...
MarlinKimbra/stepper.h
View file @
e7267fe5
...
@@ -52,7 +52,7 @@ enum EndstopEnum {X_MIN=0, Y_MIN=1, Z_MIN=2, Z_PROBE=3, X_MAX=4, Y_MAX=5, Z_MAX=
...
@@ -52,7 +52,7 @@ enum EndstopEnum {X_MIN=0, Y_MIN=1, Z_MIN=2, Z_PROBE=3, X_MAX=4, Y_MAX=5, Z_MAX=
#define E_STEP_WRITE(v) { if(extruder_duplication_enabled) { E0_STEP_WRITE(v); E1_STEP_WRITE(v); } else if(current_block->active_driver == 1) { E1_STEP_WRITE(v); } else { E0_STEP_WRITE(v); }}
#define E_STEP_WRITE(v) { if(extruder_duplication_enabled) { E0_STEP_WRITE(v); E1_STEP_WRITE(v); } else if(current_block->active_driver == 1) { E1_STEP_WRITE(v); } else { E0_STEP_WRITE(v); }}
#define NORM_E_DIR() { if(extruder_duplication_enabled) { E0_DIR_WRITE(!INVERT_E0_DIR); E1_DIR_WRITE(!INVERT_E1_DIR); } else if(current_block->active_driver == 1) { E1_DIR_WRITE(!INVERT_E1_DIR); } else { E0_DIR_WRITE(!INVERT_E0_DIR); }}
#define NORM_E_DIR() { if(extruder_duplication_enabled) { E0_DIR_WRITE(!INVERT_E0_DIR); E1_DIR_WRITE(!INVERT_E1_DIR); } else if(current_block->active_driver == 1) { E1_DIR_WRITE(!INVERT_E1_DIR); } else { E0_DIR_WRITE(!INVERT_E0_DIR); }}
#define REV_E_DIR() { if(extruder_duplication_enabled) { E0_DIR_WRITE(INVERT_E0_DIR); E1_DIR_WRITE(INVERT_E1_DIR); } else if(current_block->active_driver == 1) { E1_DIR_WRITE(INVERT_E1_DIR); } else { E0_DIR_WRITE(INVERT_E0_DIR); }}
#define REV_E_DIR() { if(extruder_duplication_enabled) { E0_DIR_WRITE(INVERT_E0_DIR); E1_DIR_WRITE(INVERT_E1_DIR); } else if(current_block->active_driver == 1) { E1_DIR_WRITE(INVERT_E1_DIR); } else { E0_DIR_WRITE(INVERT_E0_DIR); }}
#endif
#endif
#else
#else
#define E_STEP_WRITE(v) E0_STEP_WRITE(v)
#define E_STEP_WRITE(v) E0_STEP_WRITE(v)
#define NORM_E_DIR() E0_DIR_WRITE(!INVERT_E0_DIR)
#define NORM_E_DIR() E0_DIR_WRITE(!INVERT_E0_DIR)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment