PageRenderTime 30ms CodeModel.GetById 22ms app.highlight 4ms RepoModel.GetById 1ms app.codeStats 0ms

/firmware/src/Extruder/EepromMap.cc

http://github.com/makerbot/G3Firmware
C++ | 34 lines | 12 code | 4 blank | 18 comment | 0 complexity | 86457ab2b51bd1e8d25cb82d1792d6b0 MD5 | raw file
 1/*
 2 * Copyright 2010 by Adam Mayer	 <adam@makerbot.com>
 3 *
 4 * This program is free software: you can redistribute it and/or modify
 5 * it under the terms of the GNU General Public License as published by
 6 * the Free Software Foundation, either version 3 of the License, or
 7 * (at your option) any later version.
 8 *
 9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program.  If not, see <http://www.gnu.org/licenses/>
16 */
17
18#include "EepromMap.hh"
19#include "Eeprom.hh"
20#include <avr/eeprom.h>
21
22namespace eeprom {
23
24void setDefaults() {
25        // Initialize eeprom map
26        // Default: Heaters 0 and 1 enabled, thermistor on both.
27        uint8_t features = eeprom::HEATER_0_PRESENT |
28                        eeprom::HEATER_0_THERMISTOR |
29                        eeprom::HEATER_1_PRESENT |
30                        eeprom::HEATER_1_THERMISTOR;
31        eeprom_write_byte((uint8_t*)eeprom::FEATURES,features);
32}
33
34} // namespace eeprom