Deluge Firmware 1.3.0
Build date: 2025.09.27
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
30enum class Polarity : uint8_t;
31namespace FlashStorage {
32
33extern uint8_t defaultScale;
34extern bool audioClipRecordMargins;
35extern KeyboardLayout keyboardLayout;
36extern uint8_t
37 recordQuantizeLevel; // Assumes insideWorldTickMagnitude==1, which is not default anymore, so adjust accordingly
38extern uint8_t sampleBrowserPreviewMode;
39extern uint8_t defaultVelocity;
40extern int8_t defaultMagnitude;
41extern bool settingsBeenRead;
42extern uint8_t defaultBendRange[2];
43
44extern SessionLayoutType defaultSessionLayout;
45extern KeyboardLayoutType defaultKeyboardLayout;
46
47extern bool keyboardFunctionsVelocityGlide;
48extern bool keyboardFunctionsModwheelGlide;
49
50extern FavouritesDefaultLayout defaultFavouritesLayout;
51
52extern bool gridEmptyPadsUnarm;
53extern bool gridEmptyPadsCreateRec;
54extern bool gridAllowGreenSelection;
55extern GridDefaultActiveMode defaultGridActiveMode;
56
57extern uint8_t defaultMetronomeVolume;
58
59extern bool automationInterpolate;
60extern bool automationClear;
61extern bool automationShift;
62extern bool automationNudgeNote;
63extern bool automationDisableAuditionPadShortcuts;
64
65extern StartupSongMode defaultStartupSongMode;
66extern uint8_t defaultPadBrightness;
67extern SampleRepeatMode defaultSliceMode;
68extern bool highCPUUsageIndicator;
69extern uint8_t defaultHoldTime;
70extern int32_t holdTime;
71
72extern uint8_t defaultSwingInterval;
73
74extern std::bitset<NUM_PRESET_SCALES> defaultDisabledPresetScales;
75
76extern bool accessibilityShortcuts;
77extern MenuHighlighting accessibilityMenuHighlighting;
78
79extern OutputType defaultNewClipType;
80extern bool defaultUseLastClipType;
81
82extern ThresholdRecordingMode defaultThresholdRecordingMode;
83
84extern Polarity defaultPatchCablePolarity;
85
86extern GlobalMIDICommand defaultLoopRecordingCommand;
87
88extern bool defaultUseSharps;
89
90void readSettings();
91void writeSettings();
92void resetSettings();
93void resetMidiFollowSettings();
94void resetAutomationSettings();
95
96} // namespace FlashStorage