Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
marlin-anet-a8
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jonas Leder
marlin-anet-a8
Commits
352aa3f4
Commit
352aa3f4
authored
Mar 13, 2015
by
Scott Lahteine
Browse files
Options
Downloads
Plain Diff
Merge branch 'Development' into marlin_configurator
Latest upstream
parents
08694339
196db572
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
Marlin/temperature.cpp
+31
-48
31 additions, 48 deletions
Marlin/temperature.cpp
with
31 additions
and
48 deletions
Marlin/temperature.cpp
+
31
−
48
View file @
352aa3f4
...
@@ -516,6 +516,36 @@ void checkExtruderAutoFans()
...
@@ -516,6 +516,36 @@ void checkExtruderAutoFans()
#define WRITE_FAN(v) WRITE(FAN_PIN, v)
#define WRITE_FAN(v) WRITE(FAN_PIN, v)
#endif
#endif
inline
void
_temp_error
(
int
e
,
const
char
*
msg1
,
const
char
*
msg2
)
{
if
(
!
IsStopped
())
{
SERIAL_ERROR_START
;
if
(
e
>=
0
)
SERIAL_ERRORLN
((
int
)
e
);
serialprintPGM
(
msg1
);
MYSERIAL
.
write
(
'\n'
);
#ifdef ULTRA_LCD
lcd_setalertstatuspgm
(
msg2
);
#endif
}
#ifndef BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
Stop
();
#endif
}
void
max_temp_error
(
uint8_t
e
)
{
disable_heater
();
_temp_error
(
e
,
MSG_MAXTEMP_EXTRUDER_OFF
,
MSG_ERR_MAXTEMP
);
}
void
min_temp_error
(
uint8_t
e
)
{
disable_heater
();
_temp_error
(
e
,
MSG_MINTEMP_EXTRUDER_OFF
,
MSG_ERR_MINTEMP
);
}
void
bed_max_temp_error
(
void
)
{
#if HAS_HEATER_BED
WRITE_HEATER_BED
(
0
);
#endif
_temp_error
(
-
1
,
MSG_MAXTEMP_BED_OFF
,
MSG_ERR_MAXTEMP_BED
);
}
void
manage_heater
()
{
void
manage_heater
()
{
if
(
!
temp_meas_ready
)
return
;
if
(
!
temp_meas_ready
)
return
;
...
@@ -623,14 +653,7 @@ void manage_heater() {
...
@@ -623,14 +653,7 @@ void manage_heater() {
#ifdef TEMP_SENSOR_1_AS_REDUNDANT
#ifdef TEMP_SENSOR_1_AS_REDUNDANT
if
(
fabs
(
current_temperature
[
0
]
-
redundant_temperature
)
>
MAX_REDUNDANT_TEMP_SENSOR_DIFF
)
{
if
(
fabs
(
current_temperature
[
0
]
-
redundant_temperature
)
>
MAX_REDUNDANT_TEMP_SENSOR_DIFF
)
{
disable_heater
();
disable_heater
();
if
(
IsStopped
()
==
false
)
{
_temp_error
(
-
1
,
MSG_EXTRUDER_SWITCHED_OFF
,
MSG_ERR_REDUNDANT_TEMP
);
SERIAL_ERROR_START
;
SERIAL_ERRORLNPGM
(
MSG_EXTRUDER_SWITCHED_OFF
);
LCD_ALERTMESSAGEPGM
(
MSG_ERR_REDUNDANT_TEMP
);
// translatable
}
#ifndef BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
Stop
();
#endif
}
}
#endif //TEMP_SENSOR_1_AS_REDUNDANT
#endif //TEMP_SENSOR_1_AS_REDUNDANT
...
@@ -1136,46 +1159,6 @@ void disable_heater() {
...
@@ -1136,46 +1159,6 @@ void disable_heater() {
#endif
#endif
}
}
void
max_temp_error
(
uint8_t
e
)
{
disable_heater
();
if
(
IsStopped
()
==
false
)
{
SERIAL_ERROR_START
;
SERIAL_ERRORLN
((
int
)
e
);
SERIAL_ERRORLNPGM
(
MSG_MAXTEMP_EXTRUDER_OFF
);
LCD_ALERTMESSAGEPGM
(
MSG_ERR_MAXTEMP
);
// translatable
}
#ifndef BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
Stop
();
#endif
}
void
min_temp_error
(
uint8_t
e
)
{
disable_heater
();
if
(
IsStopped
()
==
false
)
{
SERIAL_ERROR_START
;
SERIAL_ERRORLN
((
int
)
e
);
SERIAL_ERRORLNPGM
(
MSG_MINTEMP_EXTRUDER_OFF
);
LCD_ALERTMESSAGEPGM
(
MSG_ERR_MINTEMP
);
// translatable
}
#ifndef BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
Stop
();
#endif
}
void
bed_max_temp_error
(
void
)
{
#if HAS_HEATER_BED
WRITE_HEATER_BED
(
0
);
#endif
if
(
IsStopped
()
==
false
)
{
SERIAL_ERROR_START
;
SERIAL_ERRORLNPGM
(
MSG_MAXTEMP_BED_OFF
);
LCD_ALERTMESSAGEPGM
(
MSG_ERR_MAXTEMP_BED
);
// translatable
}
#ifndef BOGUS_TEMPERATURE_FAILSAFE_OVERRIDE
Stop
();
#endif
}
#ifdef HEATER_0_USES_MAX6675
#ifdef HEATER_0_USES_MAX6675
#define MAX6675_HEAT_INTERVAL 250
#define MAX6675_HEAT_INTERVAL 250
long
max6675_previous_millis
=
MAX6675_HEAT_INTERVAL
;
long
max6675_previous_millis
=
MAX6675_HEAT_INTERVAL
;
...
...
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment