Added calibration setpoints
git-svn-id: https://svn.vbchaos.nl/svn/hsb/trunk@417 05563f52-14a8-4384-a975-3d1654cca0fa
This commit is contained in:
@@ -11,9 +11,9 @@
|
||||
// Email: support@microkey.nl
|
||||
// Web: www.microkey.nl
|
||||
// -----------------------------------------------------------------------------
|
||||
/// $Revision: $
|
||||
/// $Author: $
|
||||
/// $Date: $
|
||||
/// $Revision$
|
||||
/// $Author$
|
||||
/// $Date$
|
||||
// (c) 2017 Micro-Key bv
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
@@ -72,9 +72,10 @@ struct PINStorageClass
|
||||
// -----------------------------------------------------------------------------
|
||||
// File-scope variables
|
||||
// -----------------------------------------------------------------------------
|
||||
static struct CachedStorage deviceParameters = {.initialized = false};
|
||||
|
||||
static struct DeviceParameters _dParam = {.initialized = false};
|
||||
struct DeviceParameters* const dParam = &_dParam;
|
||||
static struct DeviceParameters _dParam = {.initialized = false, .parametersStorage = &deviceParameters};
|
||||
struct DeviceParameters* const dParam = &_dParam;
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
// Function declarations
|
||||
@@ -86,23 +87,12 @@ static void DeviceParameters_verifyCRCs(void);
|
||||
// Function definitions
|
||||
// -----------------------------------------------------------------------------
|
||||
|
||||
ErrorStatus DeviceParameters_construct(struct CachedStorage* parametersStorage, struct MemoryDevice* memoryDevice)
|
||||
ErrorStatus DeviceParameters_construct(struct MemoryDevice* memoryDevice)
|
||||
{
|
||||
ErrorStatus returnValue = SUCCESS;
|
||||
|
||||
if (!dParam->initialized)
|
||||
{
|
||||
if (returnValue == SUCCESS)
|
||||
{
|
||||
if (parametersStorage != NULL)
|
||||
{
|
||||
dParam->parametersStorage = parametersStorage;
|
||||
}
|
||||
else
|
||||
{
|
||||
returnValue = ERROR;
|
||||
}
|
||||
}
|
||||
|
||||
if (returnValue == SUCCESS)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user