Skip to content

Commit

Permalink
Add support for Daum realtime devices (#2952)
Browse files Browse the repository at this point in the history
* train: add support for serial daum devices

Add support for daum devices connected via serial port.
Such device could be:
   - Daum Vital
   - Daum ergo_bike series
       * ergo_bike_2002
       * ergo_bike 4004 TRS
       * ergo_bike cardio
       * ergo_bike vita
       * ergo_bike fitness
The only device I own is a Daum Vital, therfore this is the only device
that is known to work correctly.

The default behaviour is to send the load to the device only once to
allow the user to interact with the device. The profile field is used
to pass a _force_ flag in form of a string containing the word _force_.
Doing so will cause the implementation to send the load to the device
every _poll interval_ (default 1s), except the training is paused.

Signed-off-by: Florian Nairz <nairz.florian@gmail.com>

* train: daum: fix unsigned/signed compare mismatch and add return value
  • Loading branch information
thebaron06 authored and liversedge committed Nov 5, 2018
1 parent b5ed04b commit edb0444
Show file tree
Hide file tree
Showing 10 changed files with 700 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Train/AddDeviceWizard.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ DeviceScanner::quickScan(bool deep) // scan quickly or if true scan forever, as
case DEV_MONARK : wizard->controller = new MonarkController(NULL, NULL); break;
case DEV_KETTLER : wizard->controller = new KettlerController(NULL, NULL); break;
case DEV_KETTLER_RACER : wizard->controller = new KettlerRacerController (NULL, NULL); break;
case DEV_DAUM : wizard->controller = new DaumController(NULL, NULL); break;
#endif
#ifdef GC_HAVE_LIBUSB
case DEV_FORTIUS : wizard->controller = new FortiusController(NULL, NULL); break;
Expand Down Expand Up @@ -455,6 +456,7 @@ AddSearch::nextId() const
case DEV_MONARK : return 60; break; // confirm and add
case DEV_KETTLER : return 60; break; // confirm and add
case DEV_KETTLER_RACER : return 60; break; // confirm and add
case DEV_DAUM : return 60; break; // confirm and add
case DEV_FORTIUS : return 30; break; // confirm and add
case DEV_IMAGIC : return 35; break; // confirm and add
}
Expand Down
1 change: 1 addition & 0 deletions src/Train/AddDeviceWizard.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
#include "MonarkController.h"
#include "KettlerController.h"
#include "KettlerRacerController.h"
#include "DaumController.h"
#endif
#include "ANTlocalController.h"
#include "ANTChannel.h"
Expand Down
Loading

0 comments on commit edb0444

Please sign in to comment.