~toykeeper/flashlight-firmware/fsm

« back to all changes in this revision

Viewing changes to ToyKeeper/spaghetti-monster/anduril/config-default.h

  • Committer: Selene ToyKeeper
  • Date: 2023-11-02 17:05:02 UTC
  • mfrom: (483.12.159 multi-channel)
  • mto: This revision was merged to the branch mainline in revision 491.
  • Revision ID: bzr@toykeeper.net-20231102170502-sinkm18qjxlorsxa
merged multi-channel branch with a major refactor and half a year of updates

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * config-default.h: Default configuration for Anduril.
3
 
 *
4
 
 * Copyright (C) 2017 Selene Scriven
5
 
 *
6
 
 * This program is free software: you can redistribute it and/or modify
7
 
 * it under the terms of the GNU General Public License as published by
8
 
 * the Free Software Foundation, either version 3 of the License, or
9
 
 * (at your option) any later version.
10
 
 *
11
 
 * This program is distributed in the hope that it will be useful,
12
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14
 
 * GNU General Public License for more details.
15
 
 *
16
 
 * You should have received a copy of the GNU General Public License
17
 
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
18
 
 */
 
1
// config-default.h: Default configuration for Anduril.
 
2
// Copyright (C) 2017-2023 Selene ToyKeeper
 
3
// SPDX-License-Identifier: GPL-3.0-or-later
19
4
 
20
 
#ifndef CONFIG_DEFAULT_H
21
 
#define CONFIG_DEFAULT_H
 
5
#pragma once
22
6
 
23
7
/*
24
8
 * This file specifies the default settings for Anduril.
36
20
 
37
21
// overheat protection
38
22
#define USE_THERMAL_REGULATION
 
23
#if (ATTINY==85) || (ATTINY==1634)
 
24
// sloppy temperature sensor needs bigger error margin
39
25
#define DEFAULT_THERM_CEIL 45  // try not to get hotter than this (in C)
 
26
#else
 
27
// more accurate temperature sensor can regulate higher safely
 
28
#define DEFAULT_THERM_CEIL 50  // try not to get hotter than this (in C)
 
29
#endif
40
30
// Comment out to disable automatic calibration on factory reset
41
31
//   - If so, be sure to set THERM_CAL_OFFSET to the correct calibration offset
42
32
//   - Calibration can still be overridden in temperature check mode
195
185
// if the aux LEDs oscillate between "full battery" and "empty battery"
196
186
// while in "voltage" mode, enable this to reduce the amplitude of
197
187
// those oscillations
198
 
//#define USE_LOWPASS_WHILE_ASLEEP
199
 
 
200
 
#endif
 
188
#if (ATTINY==1616) || (ATTINY==1634)
 
189
#define USE_LOWPASS_WHILE_ASLEEP
 
190
#endif
 
191
 
 
192
// if there's tint ramping, allow user to set it smooth or stepped
 
193
#define USE_STEPPED_TINT_RAMPING
 
194
#define DEFAULT_TINT_RAMP_STYLE 0  // smooth
 
195
 
 
196
// Use "smooth steps" to soften on/off and step changes
 
197
// on MCUs with enough room for extra stuff like this
 
198
#if (ATTINY==1616) || (ATTINY==1634)
 
199
#define USE_SMOOTH_STEPS
 
200
#endif
 
201
// 0 = none, 1 = smooth, 2+ = undefined
 
202
#define DEFAULT_SMOOTH_STEPS_STYLE  1
 
203
 
 
204
// by default, allow user to set the channel for each strobe-group mode
 
205
// (but allow disabling this feature per build)
 
206
#define USE_CHANNEL_PER_STROBE
 
207