Browse Source

Followup for persistent_store_api.h

Scott Lahteine 5 years ago
parent
commit
6a8b906318

+ 29
- 0
Marlin/src/HAL/persistent_store_api.cpp View File

@@ -0,0 +1,29 @@
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4
+ *
5
+ * Based on Sprinter and grbl.
6
+ * Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
+ * GNU General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License
19
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
20
+ *
21
+ */
22
+#include "../inc/MarlinConfigPre.h"
23
+
24
+#if ENABLED(EEPROM_SETTINGS)
25
+
26
+  #include "persistent_store_api.h"
27
+  PersistentStore persistentStore;
28
+
29
+#endif

+ 22
- 4
Marlin/src/HAL/persistent_store_api.h View File

@@ -1,5 +1,25 @@
1
-#ifndef _PERSISTENT_STORE_H_
2
-#define _PERSISTENT_STORE_H_
1
+/**
2
+ * Marlin 3D Printer Firmware
3
+ * Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
4
+ *
5
+ * Based on Sprinter and grbl.
6
+ * Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm
7
+ *
8
+ * This program is free software: you can redistribute it and/or modify
9
+ * it under the terms of the GNU General Public License as published by
10
+ * the Free Software Foundation, either version 3 of the License, or
11
+ * (at your option) any later version.
12
+ *
13
+ * This program is distributed in the hope that it will be useful,
14
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
+ * GNU General Public License for more details.
17
+ *
18
+ * You should have received a copy of the GNU General Public License
19
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>.
20
+ *
21
+ */
22
+#pragma once
3 23
 
4 24
 #include <stddef.h>
5 25
 #include <stdint.h>
@@ -16,5 +36,3 @@ public:
16 36
 };
17 37
 
18 38
 extern PersistentStore persistentStore;
19
-
20
-#endif // _PERSISTENT_STORE_H_

+ 0
- 1
Marlin/src/module/configuration_store.cpp View File

@@ -345,7 +345,6 @@ void MarlinSettings::postprocess() {
345 345
 
346 346
 #if ENABLED(EEPROM_SETTINGS)
347 347
   #include "../HAL/persistent_store_api.h"
348
-  PersistentStore persistentStore;
349 348
 
350 349
   #define DUMMY_PID_VALUE 3000.0f
351 350
   #define EEPROM_START() int eeprom_index = EEPROM_OFFSET; persistentStore.access_start()

Loading…
Cancel
Save