Generalize and simplify 'triggered when stowed test`

The `PROBE_IS_TRIGGERED_WHEN_STOWED_TEST` is able to detect if a probe is
successfully deployed/stowed.
It was part of the Allen Key probes code only.
Now the function is generally available.

Currently this test is compulsory for Allen Key probes to not alter the used behaviour
If you want to add the test for an other type of probe simply add
```
#define PROBE_IS_TRIGGERED_WHEN_STOWED_TEST
```
to your config.
This commit is contained in:
AnHardt
2016-07-06 03:56:17 +02:00
parent 5126cce7fd
commit 8555816a11
2 changed files with 56 additions and 47 deletions

View File

@ -753,6 +753,10 @@
#define HAS_BED_PROBE (PROBE_SELECTED && PROBE_PIN_CONFIGURED)
#if ENABLED(Z_PROBE_ALLEN_KEY)
#define PROBE_IS_TRIGGERED_WHEN_STOWED_TEST
#endif
/**
* Bed Probe dependencies
*/