tomaitheous wrote:
Concerning the length counter halt flag, does enabling it mid count disable the channel sound(output) or just the counter and the sound keeps playing(infinitely)? I assume it's the latter
All the halt flag does is stop the length counter from decrementing when it's clocked. Whether or not the channel is silenced depends on the value of the counter itself (zero=silence, nonzero=active), the halt flag is irrelevent.
Clearing the halt flag (enabling length counting) just means the length counter will start counting down and silence the channel once it reaches zero.
Quote:
, so does the volume envelope immediately kick in?
The current output volume is always applied unless the length counter is zero (in which case output is forced to zero/silence).
Quote:
Also, if the counter is at 00 or the halt disable flag is set, and the game code clears the flag(or updates LLLLL) - when does the channel go active? On the next tick of the frame sequencer or immediately?
The halt flag doesn't impact the counter's contents like this. It just prevents it from counting down. Whether or not the halt flag is set or clear... the channel becomes active and audible immediately after the next $4003/7 write (since that updates LLLLL, which reloads the length counter, making it nonzero)
The only time the channel would remain silenced after a write to $4003/7 is if the channel is disabled via $4015 (or if the channel's output volume is 0)