aboutsummaryrefslogtreecommitdiff
path: root/src/survive_driver_dummy.c
diff options
context:
space:
mode:
authorJustin Berger <jdavidberger@gmail.com>2018-06-27 04:22:22 +0000
committerJustin Berger <jdavidberger@gmail.com>2018-06-27 04:22:22 +0000
commitcf36bd58b8c9d1c23ccfe1a52beafe376ba02e6b (patch)
treebae72f9ebe6937dbbabb7beec3115028a15743b0 /src/survive_driver_dummy.c
parent902bbde43fb6e000140da0da56c05f2d4af1df5f (diff)
parente68b69a9a14aeb70988c52666e60502fe6f049ab (diff)
downloadlibsurvive-cf36bd58b8c9d1c23ccfe1a52beafe376ba02e6b.tar.gz
libsurvive-cf36bd58b8c9d1c23ccfe1a52beafe376ba02e6b.tar.bz2
Merge remote-tracking branch 'origin/master' into fix_wired_tracker
Diffstat (limited to 'src/survive_driver_dummy.c')
-rw-r--r--src/survive_driver_dummy.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/survive_driver_dummy.c b/src/survive_driver_dummy.c
index 01d0482..e305b33 100644
--- a/src/survive_driver_dummy.c
+++ b/src/survive_driver_dummy.c
@@ -8,7 +8,7 @@
#include "survive_config.h"
#include "os_generic.h"
-STATIC_CONFIG_ITEM_I( DUMMY_DRIVER_ENABLE, "dummy-driver-enable", "Load a dummy driver for testing.", 0 );
+STATIC_CONFIG_ITEM( DUMMY_DRIVER_ENABLE, "dummy-driver-enable", 'i', "Load a dummy driver for testing.", 0 );
struct SurviveDriverDummy {
SurviveContext * ctx;
@@ -55,7 +55,8 @@ int dummy_haptic( SurviveObject * so, uint8_t reserved, uint16_t pulseHigh, uint
int DriverRegDummy(SurviveContext *ctx)
{
- if( !GCONFIGI(DUMMY_DRIVER_ENABLE) ) return 0;
+ int enable = survive_configi( ctx, "dummy-driver-enable", SC_GET, 9 );
+ if( !enable ) return 0;
SurviveDriverDummy *sp = calloc(1, sizeof(SurviveDriverDummy));
sp->ctx = ctx;