Bladeren bron

Followup for persistent_store_api.h

Scott Lahteine 5 jaren geleden
bovenliggende
commit
6a8b906318

+ 29
- 0
Marlin/src/HAL/persistent_store_api.cpp Bestand weergeven

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 Bestand weergeven

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
 #include <stddef.h>
24
 #include <stddef.h>
5
 #include <stdint.h>
25
 #include <stdint.h>
16
 };
36
 };
17
 
37
 
18
 extern PersistentStore persistentStore;
38
 extern PersistentStore persistentStore;
19
-
20
-#endif // _PERSISTENT_STORE_H_

+ 0
- 1
Marlin/src/module/configuration_store.cpp Bestand weergeven

345
 
345
 
346
 #if ENABLED(EEPROM_SETTINGS)
346
 #if ENABLED(EEPROM_SETTINGS)
347
   #include "../HAL/persistent_store_api.h"
347
   #include "../HAL/persistent_store_api.h"
348
-  PersistentStore persistentStore;
349
 
348
 
350
   #define DUMMY_PID_VALUE 3000.0f
349
   #define DUMMY_PID_VALUE 3000.0f
351
   #define EEPROM_START() int eeprom_index = EEPROM_OFFSET; persistentStore.access_start()
350
   #define EEPROM_START() int eeprom_index = EEPROM_OFFSET; persistentStore.access_start()

Laden…
Annuleren
Opslaan