GitXplorerGitXplorer
m

gpnvm

public
0 stars
0 forks
0 issues

Commits

List of commits on branch master.
Unverified
2360610006c474e936a0137fc8eb1b41898ffd8f

README: lists md syntax

mmleeman committed 6 years ago
Unverified
97737b649c87dbf761da1fba3c7d6f5faf64d40f

gpnvm: add TODOs

mmleeman committed 6 years ago
Unverified
c082297ac0fdddfb41cfa1ed6e8252d185174d70

meson: add meson build file iso static Makefile

mmleeman committed 6 years ago
Unverified
69154e6600f2986aa9943e8548c464cc7d9652a6

gpnvm: comment code

mmleeman committed 6 years ago
Unverified
02a22a09278a4f3c672533640ca2e9cdfec25649

gpnvm: start adding documentation

mmleeman committed 6 years ago
Unverified
774b52936f5bb913271c830be2025c16d8133951

README: update description

mmleeman committed 6 years ago

README

The README file for this repository.

Introduction

This is a small exercise to show your skill and style in embedded C programming.

Exercise

The exercise exists in the implementation of a non-volatile memory storage component. This component should be able to backup and restore values corresponding to a unique attribute identifier. For the simplicity of the exercise the underlying non-volatile memory (eeprom, flash, ...) can be modelled as a file.

Component Specification

Implement the basic implementation of this component based on following API description:

typedef unsigned char UInt8;
typedef UInt8 gpNvm_AttrId;
typedef UInt8 gpNvm_Result;

gpNvm_Result gpNvm_GetAttribute(gpNvm_AttrId, pLength, UInt8* pValue);
gpNvm_Result gpNvm_SetAttribute(gpNvm_AttrId, attrId, UInt8* attrId, UInt8 length, UInt8* pValue);

Make sure the implementation supports different datatypes for pValue

Some examples:

  • Basic datatypes like UInt8 , UInt32 ,...
  • An array of UInt8
  • Structs like for instance:
#define MAX_LENGTH 20
typedef struct {
UInt8
id;
UInt32 options;
UInt8 length;
UInt8 data[MAX_LENGTH];
} gpTestData_t;
  • Extend the basic implementation so it discovers corruptions in the underlying storage.
  • Extend the basic implementation so it can recover from corruptions in the underlying storage.
  • Extend the your solution with an unit test.

Build Status