Platformio Error未命名类型

时间:2018-04-18 09:21:32

标签: platformio

我的代码很简单:

的main.cpp

#include <Arduino.h>
#include "config.h"

Config c;

void setup() {
    // put your setup code here, to run once:
}

void loop() {
    // put your main code here, to run repeatedly:
}

的config.h

#ifndef Config_h
#define Config_h

class Config{
  public:
    Config(){};
  };

#endif

config.cpp

#include "config.h"

当我尝试构建项目时,我收到以下错误:

  

src \ main.cpp:4:1:错误:&#39;配置&#39;没有命名类型

这里有什么问题?

1 个答案:

答案 0 :(得分:0)

我找到了解决方案config.h =&gt; myconfig.h

相关问题