Deluge Firmware 1.3.0
Build date: 2025.04.16
Loading...
Searching...
No Matches
flash_storage.h
1/*
2 * Copyright © 2015-2023 Synthstrom Audible Limited
3 *
4 * This file is part of The Synthstrom Audible Deluge Firmware.
5 *
6 * The Synthstrom Audible Deluge Firmware is free software: you can redistribute it and/or modify it under the
7 * terms of the GNU General Public License as published by the Free Software Foundation,
8 * either version 3 of the License, or (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
11 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12 * See the GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along with this program.
15 * If not, see <https://www.gnu.org/licenses/>.
16 */
17
18#pragma once
19
20#include "definitions_cxx.hpp"
21#include "model/scale/preset_scales.h"
22#include <bitset>
23#include <cstdint>
24#include <span>
25
26#define PREVIEW_OFF 0
27#define PREVIEW_ONLY_WHILE_NOT_PLAYING 1
28#define PREVIEW_ON 2
29
30namespace FlashStorage {
31
32extern uint8_t defaultScale;
33extern bool audioClipRecordMargins;
34extern KeyboardLayout keyboardLayout;
35extern uint8_t
36 recordQuantizeLevel; // Assumes insideWorldTickMagnitude==1, which is not default anymore, so adjust accordingly
37extern uint8_t sampleBrowserPreviewMode;
38extern uint8_t defaultVelocity;
39extern int8_t defaultMagnitude;
40extern bool settingsBeenRead;
41extern uint8_t defaultBendRange[2];
42
43extern SessionLayoutType defaultSessionLayout;
44extern KeyboardLayoutType defaultKeyboardLayout;
45
46extern bool keyboardFunctionsVelocityGlide;
47extern bool keyboardFunctionsModwheelGlide;
48
49extern FavouritesDefaultLayout defaultFavouritesLayout;
50
51extern bool gridEmptyPadsUnarm;
52extern bool gridEmptyPadsCreateRec;
53extern bool gridAllowGreenSelection;
54extern GridDefaultActiveMode defaultGridActiveMode;
55
56extern uint8_t defaultMetronomeVolume;
57
58extern bool automationInterpolate;
59extern bool automationClear;
60extern bool automationShift;
61extern bool automationNudgeNote;
62extern bool automationDisableAuditionPadShortcuts;
63
64extern StartupSongMode defaultStartupSongMode;
65extern uint8_t defaultPadBrightness;
66extern SampleRepeatMode defaultSliceMode;
67extern bool highCPUUsageIndicator;
68extern uint8_t defaultHoldTime;
69extern int32_t holdTime;
70
71extern uint8_t defaultSwingInterval;
72
73extern std::bitset<NUM_PRESET_SCALES> defaultDisabledPresetScales;
74
75extern bool accessibilityShortcuts;
76extern bool accessibilityMenuHighlighting;
77
78extern OutputType defaultNewClipType;
79extern bool defaultUseLastClipType;
80
81extern ThresholdRecordingMode defaultThresholdRecordingMode;
82
83extern GlobalMIDICommand defaultLoopRecordingCommand;
84
85extern bool defaultAlternativeSelectEncoderBehaviour;
86
87void readSettings();
88void writeSettings();
89void resetSettings();
90void resetMidiFollowSettings();
91void resetAutomationSettings();
92
93} // namespace FlashStorage