summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
author m1macrophage <168948267+m1macrophage@users.noreply.github.com>2025-11-20 23:13:26 -0800
committer GitHub <noreply@github.com>2025-11-21 08:13:26 +0100
commitf84a02772f5d784255571dfbd2ec1bf82d7d9438 (patch)
tree3e3b5069f8a31c4df90927b98609fba4c4fa55ba
parent7fece3b95204171023fd5200fd92abb8d3e14d4b (diff)
sound/cem3394.cpp: Fixed "FREQENCY" typo and updated comments. (#14561)
-rw-r--r--src/devices/sound/cem3394.cpp8
-rw-r--r--src/devices/sound/cem3394.h6
-rw-r--r--src/mame/midway/sente6vb.cpp6
-rw-r--r--src/mame/sequential/sixtrak.cpp6
4 files changed, 14 insertions, 12 deletions
diff --git a/src/devices/sound/cem3394.cpp b/src/devices/sound/cem3394.cpp
index 342cd6353fd..6c28d5348bd 100644
--- a/src/devices/sound/cem3394.cpp
+++ b/src/devices/sound/cem3394.cpp
@@ -54,7 +54,7 @@ static constexpr double EXTERNAL_VOLUME = PULSE_VOLUME;
// pulse shaping parameters
-// can be enabled with set_limit_pw(true)
+// can be enabled with configure_limit_pw(true)
// examples:
// hat trick - skidding ice sounds too loud if minimum width is too big
// snake pit - melody during first level too soft if minimum width is too small
@@ -100,7 +100,7 @@ static constexpr double EXTERNAL_VOLUME = PULSE_VOLUME;
0.0 == no resonance
+2.5 == oscillation
- FILTER_FREQENCY
+ FILTER_FREQUENCY
-3.0 ... +4.0
-0.375 V/octave
0.0 == 1300Hz
@@ -610,7 +610,7 @@ void cem3394_device::set_voltage_internal(int input, double voltage)
break;
// filter frequency varies from -3.0 to +4.0, at 0.375V/octave
- case FILTER_FREQENCY:
+ case FILTER_FREQUENCY:
m_filter_frequency = m_filter_zero_freq * pow(2.0, -voltage * (1.0 / 0.375));
LOGMASKED(LOG_CONTROL_CHANGES, "FLT_FREQ=%6.3fV -> freq=%f\n", voltage, m_filter_frequency);
break;
@@ -712,7 +712,7 @@ double cem3394_device::get_parameter(int input)
else
return voltage * (1.0 / 2.5);
- case FILTER_FREQENCY:
+ case FILTER_FREQUENCY:
return m_filter_zero_freq * pow(2.0, -voltage * (1.0 / 0.375));
}
return 0.0;
diff --git a/src/devices/sound/cem3394.h b/src/devices/sound/cem3394.h
index d7e5920c53d..fd6d147cdbb 100644
--- a/src/devices/sound/cem3394.h
+++ b/src/devices/sound/cem3394.h
@@ -10,6 +10,8 @@ class cem3394_device : public device_t, public device_sound_interface
{
public:
// inputs
+ // Each of these CV inputs can either be specified with `set_voltage()`, or
+ // provided via a sound stream.
enum
{
AUDIO_INPUT = 0, // not valid for set_voltage()
@@ -19,7 +21,7 @@ public:
PULSE_WIDTH,
MIXER_BALANCE,
FILTER_RESONANCE,
- FILTER_FREQENCY,
+ FILTER_FREQUENCY,
FINAL_GAIN,
INPUT_COUNT
};
@@ -57,7 +59,7 @@ public:
// PULSE_WIDTH: width fraction, from 0.0 to 1.0
// MIXER_BALANCE: balance, from -1.0 to 1.0
// FILTER_RESONANCE: resonance, from 0.0 to 1.0
- // FILTER_FREQENCY: frequency, in Hz
+ // FILTER_FREQUENCY: frequency, in Hz
// FINAL_GAIN: gain, in dB
// Requesting a parameter associated with a streaming input will force a
// stream update.
diff --git a/src/mame/midway/sente6vb.cpp b/src/mame/midway/sente6vb.cpp
index f2e92670933..3b46a1d7e25 100644
--- a/src/mame/midway/sente6vb.cpp
+++ b/src/mame/midway/sente6vb.cpp
@@ -295,7 +295,7 @@ void sente6vb_device::update_counter_0_timer()
// if the filter resonance is high, then they're calibrating the filter frequency
if (m_cem_device[i]->get_parameter(cem3394_device::FILTER_RESONANCE) > 0.9)
- tempfreq = m_cem_device[i]->get_parameter(cem3394_device::FILTER_FREQENCY);
+ tempfreq = m_cem_device[i]->get_parameter(cem3394_device::FILTER_FREQUENCY);
// otherwise, they're calibrating the VCO frequency
else
@@ -392,7 +392,7 @@ void sente6vb_device::chip_select_w(uint8_t data)
cem3394_device::VCO_FREQUENCY,
cem3394_device::FINAL_GAIN,
cem3394_device::FILTER_RESONANCE,
- cem3394_device::FILTER_FREQENCY,
+ cem3394_device::FILTER_FREQUENCY,
cem3394_device::MIXER_BALANCE,
cem3394_device::MODULATION_AMOUNT,
cem3394_device::PULSE_WIDTH,
@@ -424,7 +424,7 @@ void sente6vb_device::chip_select_w(uint8_t data)
"VCO_FREQUENCY",
"FINAL_GAIN",
"FILTER_RESONANCE",
- "FILTER_FREQENCY",
+ "FILTER_FREQUENCY",
"MIXER_BALANCE",
"MODULATION_AMOUNT",
"PULSE_WIDTH",
diff --git a/src/mame/sequential/sixtrak.cpp b/src/mame/sequential/sixtrak.cpp
index 16551e55403..dd8bbe3c60b 100644
--- a/src/mame/sequential/sixtrak.cpp
+++ b/src/mame/sequential/sixtrak.cpp
@@ -384,7 +384,7 @@ void sixtrak_state::update_cvs()
cem3394_device::VCO_FREQUENCY,
cem3394_device::FINAL_GAIN,
cem3394_device::FILTER_RESONANCE,
- cem3394_device::FILTER_FREQENCY,
+ cem3394_device::FILTER_FREQUENCY,
cem3394_device::MIXER_BALANCE,
cem3394_device::MODULATION_AMOUNT,
cem3394_device::PULSE_WIDTH,
@@ -609,7 +609,7 @@ void sixtrak_state::update_tuning_timer()
bool tuning_filter = false;
if (voice->get_parameter(cem3394_device::FILTER_RESONANCE) > 0.9)
{
- freq = voice->get_parameter(cem3394_device::FILTER_FREQENCY);
+ freq = voice->get_parameter(cem3394_device::FILTER_FREQUENCY);
tuning_filter = true;
}
else
@@ -901,7 +901,7 @@ void sixtrak_state::sixtrak_common(machine_config &config, device_sound_interfac
m_gain_rc[i]->add_route(0, m_voices[i], 1.0, cem3394_device::FINAL_GAIN);
VA_RC_EG(config, m_freq_rc[i]).set_r(RES_M(1));
- m_freq_rc[i]->add_route(0, m_voices[i], 1.0, cem3394_device::FILTER_FREQENCY);
+ m_freq_rc[i]->add_route(0, m_voices[i], 1.0, cem3394_device::FILTER_FREQUENCY);
CEM3394(config, m_voices[i]);
const double c_vco = C_VCO + C_VCO * C_VCO_JITTER[i] * 0.025; // +/- 2.5%.