Pass array size to class constructor

In your header, you have defined the arrays to have 0 elements. What you then do in the constructor can not change the size of those arrays. You need to use malloc and pointers, instead:

In the header:

    uint16_t *ringState;
    uint16_t *lastRingState;

In the source code, in the constructor:

ringState = (uint16_t *)malloc(sizeof(uint16_t) * numRings);
lastRingState = (uint16_t *)malloc(sizeof(uint16_t) * numRings);

After allocating the memory, you can access the memory as though it was an array (since it is), just like you are now doing.