Skip to content

Commit

Permalink
Merge branch 'devel'
Browse files Browse the repository at this point in the history
  • Loading branch information
vertexmachina committed Nov 9, 2017
2 parents e4e4a8a + 2f39063 commit 72520a9
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 16 deletions.
16 changes: 8 additions & 8 deletions api/include/vehicles/kia_soul_ev.h
Expand Up @@ -122,53 +122,53 @@ typedef struct
* @brief Minimum allowed voltage for the low spoof signal voltage. [volts]
*
*/
#define BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MIN ( 0.303 )
#define BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MIN ( 0.333 )

/*
* @brief Maximum allowed voltage for the low spoof signal voltage. [volts]
*
*/
#define BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MAX ( 1.40 )
#define BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MAX ( 1.12 )

/**
* @brief Minimum allowed voltage for the high spoof signal voltage. [volts]
*
*/
#define BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MIN ( 0.635 )
#define BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MIN ( 0.698 )

/**
* @brief Maximum allowed voltage for the high spoof signal voltage. [volts]
*
*/
#define BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MAX ( 2.87 )
#define BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MAX ( 2.29 )

/*
* @brief Minimum allowed value for the low spoof signal value. [steps]
*
* Equal to \ref BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MIN * \ref STEPS_PER_VOLT.
*/
#define BRAKE_SPOOF_LOW_SIGNAL_RANGE_MIN ( 249 )
#define BRAKE_SPOOF_LOW_SIGNAL_RANGE_MIN ( 273 )

/*
* @brief Minimum allowed value for the low spoof signal value. [steps]
*
* Equal to \ref BRAKE_SPOOF_LOW_SIGNAL_VOLTAGE_MAX * \ref STEPS_PER_VOLT.
*/
#define BRAKE_SPOOF_LOW_SIGNAL_RANGE_MAX ( 1146 )
#define BRAKE_SPOOF_LOW_SIGNAL_RANGE_MAX ( 917 )

/*
* @brief Minimum allowed value for the low spoof signal value. [steps]
*
* Equal to \ref BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MIN * \ref STEPS_PER_VOLT.
*/
#define BRAKE_SPOOF_HIGH_SIGNAL_RANGE_MIN ( 521 )
#define BRAKE_SPOOF_HIGH_SIGNAL_RANGE_MIN ( 572 )

/*
* @brief Minimum allowed value for the low spoof signal value. [steps]
*
* Equal to \ref BRAKE_SPOOF_HIGH_SIGNAL_VOLTAGE_MAX * \ref STEPS_PER_VOLT.
*/
#define BRAKE_SPOOF_HIGH_SIGNAL_RANGE_MAX ( 2351 )
#define BRAKE_SPOOF_HIGH_SIGNAL_RANGE_MAX ( 1876 )

/*
* @brief Calculation to convert a brake position to a low spoof voltage.
Expand Down
Expand Up @@ -39,12 +39,12 @@ Feature: Receiving commands

Examples:
| high | low |
| 2300 | 250 |
| 2000 | 300 |
| 1876 | 273 |
| 1800 | 300 |
| 1500 | 500 |
| 1000 | 750 |
| 750 | 1000 |
| 550 | 1100 |
| 750 | 900 |
| 572 | 917 |


Scenario Outline: Spoof value sent from application outside valid range
Expand All @@ -57,7 +57,7 @@ Feature: Receiving commands

Examples:
| high | low | high_clamped | low_clamped |
| 4000 | 0 | 2351 | 249 |
| 3500 | 500 | 2351 | 500 |
| 500 | 3500 | 521 | 1146 |
| 0 | 4000 | 521 | 1146 |
| 4000 | 0 | 1876 | 273 |
| 3500 | 500 | 1876 | 500 |
| 500 | 3500 | 572 | 917 |
| 0 | 4000 | 572 | 917 |
21 changes: 21 additions & 0 deletions firmware/common/testing/framework/cucumber-cpp/LICENSE.txt
@@ -0,0 +1,21 @@
The MIT License

Copyright (c) 2010 Paolo Ambrosio

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

0 comments on commit 72520a9

Please sign in to comment.