I have declared files structure as below. Compiler says undefined reference to `SystemStorage::initialize(int, int, int). I truly have no idea why :?
systemStorage.h
#ifndef SYSTEM_STORAGE_H
#define SYSTEM_STORAGE_H
namespace SystemStorage {
void initialize(int light_sensor, int led, int sampling);
}
#endif
systemStorage.cpp
#include "systemStorage.h"
namespace SystemStorage{
void initialize(int light_sensor, int led, int sampling){
//instructions to do ...
}
}
Main file:
#include "functions/systemStorage.h"
void setup() {
SystemStorage::initialize(1, 2, 3);
}