Merge remote-tracking branch 'upstream/dev' into dev

pull/9/head
Dirk Niggemann 5 years ago
commit 51166cbd62
  1. 9
      Disp_Plus.h
  2. 9
      MicroDexed.ino
  3. 44
      UI.hpp
  4. 2
      config.h
  5. 65
      doc/sysex-format_controller-setup.txt
  6. 72
      doc/voice_data.txt

@ -26,7 +26,9 @@
#ifndef DISP_PLUS_H_INCLUDED
#define DISP_PLUS_H_INCLUDED
#define STRING_BUFFER_SIZE 21
#include "config.h"
#define STRING_BUFFER_SIZE LCD_cols+1
template <class T>
class Disp_Plus : public T
@ -59,8 +61,9 @@ class Disp_Plus : public T
if (fill_zero == true)
memset(tmp, '0', field_size);
else
memset(tmp, 0x20, field_size - 1); // blank
memset(tmp, 0x20, field_size); // blank
tmp[field_size+1]='\0';
if (l > field_size)
l = field_size;

@ -191,14 +191,14 @@ void setup()
pinMode(U8X8_CS_PIN, OUTPUT);
#endif
delay(220); // necessary, because before this time no serial output is done :(
#ifdef ENABLE_LCD_UI
setup_ui();
#else
Serial.println(F("NO LCD DISPLAY ENABLED!"));
#endif
delay(220); // necessary, because before this time no serial output is done :(
Serial.println(F("MicroDexed based on https://github.com/asb2m10/dexed"));
Serial.println(F("(c)2018,2019 H. Wirtz <wirtz@parasitstudio.de>"));
Serial.println(F("https://codeberg.org/dcoredump/MicroDexed"));
@ -343,7 +343,8 @@ void setup()
// INIT DELAY
delay1.delay(0, mapfloat(configuration.delay_time, DELAY_TIME_MIN, DELAY_TIME_MAX, 0.0, float(DELAY_TIME_MAX)));
// delay_fb_mixer is the feedback-adding mixer
delay_fb_mixer.gain(0, 1.0 - (mapfloat(configuration.delay_feedback, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0))); // original signal
//delay_fb_mixer.gain(0, 1.0 - (mapfloat(configuration.delay_feedback, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0))); // original signal
delay_fb_mixer.gain(0, 1.0); // original signal
delay_fb_mixer.gain(1, mapfloat(configuration.delay_feedback, DELAY_FEEDBACK_MIN, DELAY_FEEDBACK_MAX, 0.0, 1.0)); // amount of feedback
master_mixer_r.gain(2, mapfloat(configuration.delay_level, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0));
master_mixer_l.gain(2, mapfloat(configuration.delay_level, DELAY_LEVEL_MIN, DELAY_LEVEL_MAX, 0.0, 1.0));
@ -361,7 +362,7 @@ void setup()
modulator.begin(WAVEFORM_TRIANGLE);
}
modulator.phase(0);
modulator.amplitude(mapfloat(configuration.chorus_level, CHORUS_LEVEL_MIN, CHORUS_LEVEL_MAX, 0.0, 1.0));
modulator.amplitude(mapfloat(configuration.chorus_depth, CHORUS_DEPTH_MIN, CHORUS_DEPTH_MAX, 0.0, 1.0));
modulator.offset(0.0);
#if MOD_FILTER_OUTPUT == MOD_BUTTERWORTH_FILTER_OUTPUT
// Butterworth filter, 12 db/octave

@ -1181,7 +1181,7 @@ void UI_func_delay_feedback(uint8_t param)
lcd_display_int(configuration.delay_feedback, 3, true, true, false);
delay_fb_mixer.gain(1, configuration.delay_feedback / 100.0 ); // amount of feedback
delay_fb_mixer.gain(0, 1.0 - configuration.delay_feedback / 100.0); // original signal
//delay_fb_mixer.gain(0, 1.0 - configuration.delay_feedback / 200.0); // original signal
}
if (LCDML.FUNC_close()) // ****** STABLE END *********
@ -1779,35 +1779,43 @@ void lcd_display_int(int16_t var, uint8_t size, bool zeros, bool brackets, bool
lcd.print(F(" "));
}
for (int8_t i = size - 1 ; i >= 0; i--)
if (var == 0 && zeros == false)
{
p = int(pow(10, i));
tmp = int(var / p);
if (tmp == 0)
for (int8_t i = size - 1 ; i > 0; i--)
lcd.print(F(" "));
lcd.print(F("0"));
}
else
{
for (int8_t i = size - 1 ; i >= 0; i--)
{
if (zeros == true)
lcd.print(F("0"));
else
p = int(pow(10, i));
tmp = int(var / p);
if (tmp == 0)
{
if (non_zero_found == true)
if (zeros == true)
lcd.print(F("0"));
else
lcd.print(F(" "));
{
if (non_zero_found == true)
lcd.print(F("0"));
else
lcd.print(F(" "));
}
}
else
{
non_zero_found = true;
lcd.print(tmp);
}
var -= (tmp * p);
}
else
{
non_zero_found = true;
lcd.print(tmp);
}
var -= (tmp * p);
}
if (brackets == true)
lcd.print(F("]"));
}
void lcd_display_float(float var, uint8_t size_number, uint8_t size_fraction, bool zeros, bool brackets, bool sign)
{
float fraction;

@ -48,7 +48,7 @@
//*************************************************************************************************
//* MIDI HARDWARE SETTINGS
//*************************************************************************************************
//#define MIDI_DEVICE_DIN Serial1
#define MIDI_DEVICE_DIN Serial1
#define MIDI_DEVICE_USB 1
#define MIDI_DEVICE_USB_HOST 1

@ -0,0 +1,65 @@
EXTENDED SYSEX FORMAT FOR MICRODEXED
====================================
SYSEX Message Controller-Set
----------------------------
11110000 F0 Status byte - start sysex
0iiiiiii 43 ID # (i=67; Yamaha)
0sssnnnn 00 Sub-status (s=0) & channel number (n=0; ch 1)
0fffffff 00 format number (f=75; 1 controller-set)
0bbbbbbb 01 byte count MS byte
0bbbbbbb 1B byte count LS byte (b=155; 1 voice)
0ddddddd ** data byte 1 controller-set
| | |
0ddddddd ** data byte 4096 (there are 128 bytes / voice)
0eeeeeee ** checksum (masked 2's comp. of sum of 4096 bytes)
11110111 F7 Status - end sysex
Data Structure: Single Controller-Set Dump
------------------------------------------
Parameter
Number Parameter Value Range
--------- --------- -----------
0 MONO/POLY MODE CHANGE 0-1 O=POLY
1 PITCH BEND RANGE 0-12
2 " " STEP 0-12
3 PORTAMENTO MODE 0-1 0=RETAIN 1=FOLLOW
4 " GLISS 0-1
5 " TIME 0-99
6 MOD WHEEL RANGE 0-99
7 " " ASSIGN 0-7 b0: pitch, b1:amp, b2: EG bias
8 FOOT CONTROL RANGE 0-99
9 " " ASSIGN 0-7 "
10 BREATH CONT RANGE 0-99
11 " " ASSIGN 0-7 "
12 AFTERTOUCH RANGE 0-99
13 " ASSIGN 0-7 "
14 OP1_ENABLE 0-1
15 OP2_ENABLE 0-1
16 OP3_ENABLE 0-1
17 OP4_ENABLE 0-1
18 OP5_ENABLE 0-1
19 OP6_ENABLE 0-1
20 MAX_NOTES 0-32
21 LOUDNESS 0-100
22 PANORAMA 0-40 (20 is middle)
23 STERO/MONO 0-3 (0=stereo, 1=mono, 2=mono-r, 3=mono-l)
24 REVERB-ROOMSIZE 0-100
25 REVERB-DAMPING 0-100
26 REVERB-LEVEL 0-100
27 CHORUS-FREQUENCY 0-100 (multiplied by 1/10 Hz)
28 CHORUS-WAVEFORM 0-1 (0=triangle, 1=sine)
29 CHORUS-DEPTH 0-100
30 CHORUS-LEVEL 0-100
31 DELAY-TIME 0-60 (multiplied by 10ms)
32 DELAY-FEEDBACK 0-100
33 DELAY-LEVEL 0-100
34 FILTER-CUTOFF 0-100
35 FILTER-RESONANCE 0-100
26 MIDI-CHANNEL 0-16 (0=OMNI)
37 POLYPHONY 0-32 (depends on CPU and FX)
38 DEXED-ENGINE 0-2 (1=modern, 2=Mark1, 2=OPL)

@ -1,72 +0,0 @@
F:
Data Structure: Bulk Dump Packed Format
---------------------------------------
OK, now the tricky bit. For a bulk dump the 155 voice parameters for each
voice are packed into 32 consecutive 128 byte chunks as follows ...
byte bit #
# 6 5 4 3 2 1 0 param A range param B range
---- --- --- --- --- --- --- --- ------------ ----- ------------ -----
0 R1 OP6 EG R1 0-99
1 R2 OP6 EG R2 0-99
2 R3 OP6 EG R3 0-99
3 R4 OP6 EG R4 0-99
4 L1 OP6 EG L1 0-99
5 L2 OP6 EG L2 0-99
6 L3 OP6 EG L3 0-99
7 L4 OP6 EG L4 0-99
8 BP LEV SCL BRK PT 0-99
9 LD SCL LEFT DEPTH 0-99
10 RD SCL RGHT DEPTH 0-99
11 0 0 0 | RC | LC | SCL LEFT CURVE 0-3 SCL RGHT CURVE 0-3
12 | DET | RS | OSC DETUNE 0-14 OSC RATE SCALE 0-7
13 0 0 | KVS | AMS | KEY VEL SENS 0-7 AMP MOD SENS 0-3
14 OL OP6 OUTPUT LEV 0-99
15 0 | FC | M | FREQ COARSE 0-31 OSC MODE 0-1
16 FF FREQ FINE 0-99
17 \
| > these 17 bytes for OSC 5
33 /
34 \
| > these 17 bytes for OSC 4
50 /
51 \
| > these 17 bytes for OSC 3
67 /
68 \
| > these 17 bytes for OSC 2
84 /
85 \
| > these 17 bytes for OSC 1
101 /
byte bit #
# 6 5 4 3 2 1 0 param A range param B range
---- --- --- --- --- --- --- --- ------------ ----- ------------ -----
102 PR1 PITCH EG R1 0-99
103 PR2 PITCH EG R2 0-99
104 PR3 PITCH EG R3 0-99
105 PR4 PITCH EG R4 0-99
106 PL1 PITCH EG L1 0-99
107 PL2 PITCH EG L2 0-99
108 PL3 PITCH EG L3 0-99
109 PL4 PITCH EG L4 0-99
110 0 0 | ALG | ALGORITHM 0-31
111 0 0 0 |OKS| FB | OSC KEY SYNC 0-1 FEEDBACK 0-7
112 LFS LFO SPEED 0-99
113 LFD LFO DELAY 0-99
114 LPMD LF PT MOD DEP 0-99
115 LAMD LF AM MOD DEP 0-99
116 | LPMS | LFW |LKS| LF PT MOD SNS 0-7 WAVE 0-5, SYNC 0-1
117 TRNSP TRANSPOSE 0-48
118 NAME CHAR 1 VOICE NAME 1 ASCII
119 NAME CHAR 2 VOICE NAME 2 ASCII
120 NAME CHAR 3 VOICE NAME 3 ASCII
121 NAME CHAR 4 VOICE NAME 4 ASCII
122 NAME CHAR 5 VOICE NAME 5 ASCII
123 NAME CHAR 6 VOICE NAME 6 ASCII
124 NAME CHAR 7 VOICE NAME 7 ASCII
125 NAME CHAR 8 VOICE NAME 8 ASCII
126 NAME CHAR 9 VOICE NAME 9 ASCII
127 NAME CHAR 10 VOICE NAME 10 ASCII
Loading…
Cancel
Save