Audio: KILL THE CHIRP -- ConfigureActivePress backed real (idle -1) on Sensor+Myomers (task #50)
The obnoxious always-on clicking was the cockpit CONFIGURE-MODE ticker: an
authored looped sequence gated by an AudioIntegerTrigger with threshold -1 on
<subsystem>.ConfigureActivePress (the held-configure-button index; -1 = none).
The attribute was one of the inert-pad redirects -- the pad reads 0 = "button 0
held forever" -> the ticker Start-fired at load and pulsed 2.7/s eternally.
Found via [sendcfg]/[seqstart] traces: the first seq start immediately follows
the trigcfg(thresh=-1, onID=Start) construction on the pad address.
Fix: real int configureActivePress = -1 APPENDED to Sensor ("Avionics") and
Myomers, registered in their attribute tables. Both classes are byte-exact
factory allocs, so the sizeof locks AND the placement-new alloc constants are
bumped TOGETHER (Sensor 0x328->0x32C, Myomers 0x358->0x35C) -- the tripwire
caught a mid-layout insert (seekVoltage@0x330 shift) and a fixed-alloc overrun
before they shipped; member moved to the true tail. Wiring the live value
(EnterConfiguration/ExitConfiguration sets/clears the index) restores the
authored hold-to-configure tick later; idle -1 is the correct silent state.
VERIFIED: ProgramButton01 plays ZERO times (was the 2.7/s chirp);
ConfigureActivePress binds real (vtbl=FFFFFFFF = the -1); FootFallInt at 0.98
gain; stable.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
847b9b85cd
commit
be626c71ce
@@ -117,7 +117,8 @@ const Sensor::IndexEntry
|
||||
{
|
||||
ATTRIBUTE_ENTRY(Sensor, RadarPercent, radarPercent), // @0x31C (map capabilities ratio)
|
||||
ATTRIBUTE_ENTRY(Sensor, SelfTest, selfTest),
|
||||
ATTRIBUTE_ENTRY(Sensor, BadVoltage, badVoltage)
|
||||
ATTRIBUTE_ENTRY(Sensor, BadVoltage, badVoltage),
|
||||
ATTRIBUTE_ENTRY(Sensor, ConfigureActivePress, configureActivePress) // audio configure-ticker gate
|
||||
};
|
||||
|
||||
Sensor::AttributeIndexSet
|
||||
@@ -162,6 +163,7 @@ Sensor::Sensor(
|
||||
radarPercent = RadarBaseline; // @0x31C = 1.0f
|
||||
selfTest = False; // @0x320 = 0
|
||||
badVoltage = False; // @0x324 = 0
|
||||
configureActivePress = -1; // APPENDED: no configure button held (audio ticker OFF)
|
||||
|
||||
// this[0x28] |= 0x8 -- flag "has an active per-frame Performance".
|
||||
SetHasPerformanceFlag(); // param_1[10] |= 8
|
||||
@@ -410,7 +412,7 @@ struct SensorLayoutCheck
|
||||
static_assert(offsetof(Sensor, radarPercent) == 0x31C, "Sensor::radarPercent @0x31C (attr 0x12)");
|
||||
static_assert(offsetof(Sensor, selfTest) == 0x320, "Sensor::selfTest @0x320");
|
||||
static_assert(offsetof(Sensor, badVoltage) == 0x324, "Sensor::badVoltage @0x324");
|
||||
static_assert(sizeof(Sensor) == 0x328, "sizeof(Sensor) 0x328 (factory alloc, byte-exact)");
|
||||
static_assert(sizeof(Sensor) == 0x32C, "sizeof(Sensor) 0x328 binary + 4 appended (alloc bumped in CreateSensorSubsystem)");
|
||||
};
|
||||
|
||||
|
||||
@@ -424,6 +426,7 @@ struct SensorLayoutCheck
|
||||
//===========================================================================//
|
||||
Subsystem *CreateSensorSubsystem(Mech *owner, int id, void *seg)
|
||||
{
|
||||
return (Subsystem *) new (Memory::Allocate(0x328))
|
||||
// 0x32C = the 0x328 binary object + 4 appended (configureActivePress; sizeof lock bumped too)
|
||||
return (Subsystem *) new (Memory::Allocate(0x32C))
|
||||
Sensor(owner, id, (Sensor::SubsystemResource *)seg);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user