summaryrefslogtreecommitdiffstats
path: root/pressure_control/firmware/valves.h
diff options
context:
space:
mode:
authorMichael Buesch <mb@bu3sch.de>2009-05-03 12:35:53 +0200
committerMichael Buesch <mb@bu3sch.de>2009-05-03 12:35:53 +0200
commitaa5604d118bc89e85c8230562080c034bfc9df17 (patch)
treeea99685ddc38ed4badad8fe6e17db162ffad6e01 /pressure_control/firmware/valves.h
parent44b0b0d80254064868c905b88826fda14010860c (diff)
downloadcnc-aa5604d118bc89e85c8230562080c034bfc9df17.tar.xz
cnc-aa5604d118bc89e85c8230562080c034bfc9df17.zip
pressure-control: Implement idle-release of valves through timer.
Signed-off-by: Michael Buesch <mb@bu3sch.de>
Diffstat (limited to 'pressure_control/firmware/valves.h')
-rw-r--r--pressure_control/firmware/valves.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/pressure_control/firmware/valves.h b/pressure_control/firmware/valves.h
index 0929682..1b50b3a 100644
--- a/pressure_control/firmware/valves.h
+++ b/pressure_control/firmware/valves.h
@@ -20,13 +20,16 @@ enum valve_state {
VALVE_STATE_14,
};
+#define VALVE_TOGGLE_MSEC 10
+
/* Wait for the valve to toggle from one position to another. */
static inline void valve_wait_toggle(void)
{
- mdelay(10);
+ mdelay(VALVE_TOGGLE_MSEC);
}
void valves_init(void);
+void valves_work(void);
void valves_emergency_state(void);
void valves_shutdown(void);
void valves_global_switch(uint8_t global_state);
bues.ch cgit interface