1
0
mirror of git://projects.qi-hardware.com/ben-wpan.git synced 2025-04-21 12:27:27 +03:00

atrf-path: added pass/fail indication (in the GUI, accept the result with P/F)

- atrf-path.c (do_sweeps): return a pass/fail/undecided value
- gui.h (gui), gui.c (gui): return a pass/fail/undecided value
- gui.c (gui): return pass/fail when P or F is pressed; exit
  unconditionally if Q is pressed
- atrf-path.c (main): according to the decision of "gui" or "do_sweeps",
  print "#PASS", "#FAIL", or nothing
This commit is contained in:
Werner Almesberger
2011-04-13 20:24:50 -03:00
parent fbc7aee55f
commit c86ce307e2
3 changed files with 86 additions and 12 deletions

View File

@@ -18,10 +18,18 @@
#include "sweep.h"
/*
* gui returns one of the following values:
*
* -1 fail
* 0 no decision taken
* 1 pass
*/
#ifdef HAVE_GFX
void gui(const struct sweep *sweep, int sweeps);
int gui(const struct sweep *sweep, int sweeps);
#else
#define gui(sweep, sweeps) abort()
#define gui(sweep, sweeps) ({ abort(); 0; })
#endif
#endif /* !GUI_H */