Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
avrcte
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
leger
avrcte
Commits
ff029629
Commit
ff029629
authored
3 years ago
by
Jean-Benoist Leger
Browse files
Options
Downloads
Patches
Plain Diff
defaillances temperatures autorisées
parent
62269d49
No related branches found
Branches containing commit
Tags
v1.7
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
conf.py
+1
-0
1 addition, 0 deletions
conf.py
orders.c
+10
-4
10 additions, 4 deletions
orders.c
orders.h
+3
-1
3 additions, 1 deletion
orders.h
status.h
+1
-0
1 addition, 0 deletions
status.h
with
15 additions
and
5 deletions
conf.py
+
1
−
0
View file @
ff029629
...
...
@@ -45,6 +45,7 @@ BUS = {
THERMO_PERIOD
=
5
THERMO_MEDIAN_FILTER_LEN
=
13
THERMO_FACTOR_FILTRE
=
1
-
math
.
exp
(
-
5
/
60
)
THERMO_FAIL_NUMBER
=
120
ACTION_TIMER_MAIN
=
"
TCC0
"
...
...
This diff is collapsed.
Click to expand it.
orders.c
+
10
−
4
View file @
ff029629
...
...
@@ -53,19 +53,25 @@ void do_orders()
}
if
(
status_thermo
>
0
)
{
status
.
fail
|=
STATUS_FAIL_T
;
if
(
status
.
fail_get_T
>=
THERMO_FAIL_NUMBER
)
status
.
fail
|=
STATUS_FAIL_T
;
else
status
.
fail_get_T
++
;
}
else
{
status
.
fail_get_T
=
0
;
status
.
fail
&=
~
STATUS_FAIL_T
;
status
.
temperature_insta
=
temp
;
if
(
median_filter_thermometer_filled
)
median_filter_thermometer_update
(
temp
);
else
if
(
!
median_filter_thermometer_filled
)
{
median_filter_thermometer_fill
(
temp
);
status
.
temperature
.
v1
=
status
.
temperature
.
v2
=
.
0625
*
temp
;
}
}
if
(
median_filter_thermometer_filled
)
{
median_filter_thermometer_update
(
status
.
temperature_insta
);
float
Tinstamf
=
.
0625
*
median_filter_thermometer_read
();
update_filtre2
(
&
(
status
.
temperature
),
THERMO_FACTOR_FILTRE
,
Tinstamf
);
...
...
This diff is collapsed.
Click to expand it.
orders.h
+
3
−
1
View file @
ff029629
...
...
@@ -22,9 +22,11 @@ void do_orders();
/*[[[cog
import conf
cog.out(f"#define THERMO_FACTOR_FILTRE {conf.THERMO_FACTOR_FILTRE:e}")
cog.out(f"#define THERMO_FACTOR_FILTRE {conf.THERMO_FACTOR_FILTRE:e}\n")
cog.out(f"#define THERMO_FAIL_NUMBER {conf.THERMO_FAIL_NUMBER:d}\n")
]]] */
#define THERMO_FACTOR_FILTRE 7.995559e-02
#define THERMO_FAIL_NUMBER 120
//[[[end]]]
#endif
This diff is collapsed.
Click to expand it.
status.h
+
1
−
0
View file @
ff029629
...
...
@@ -18,6 +18,7 @@ typedef struct status_struct
float
consigne_adj
;
float
accu_integrateur
;
uint8_t
fail
;
uint16_t
fail_get_T
;
}
status_t
;
extern
status_t
status
;
...
...
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