mirror of
https://github.com/bobbimanners/Applecorn.git
synced 2024-12-26 17:29:33 +00:00
Ensoniq noise channel is now feature-complete.
This commit is contained in:
parent
ec02d0cc41
commit
56883335b5
BIN
applecorn.po
BIN
applecorn.po
Binary file not shown.
@ -732,7 +732,6 @@ ADSRPHASE STX OSCNUM
|
||||
:S1 TYA ; Change/step -> A
|
||||
CLC
|
||||
ADC CURRAMP,X ; Add change to current amp
|
||||
* BCS :CLAMP ; If overflow, clamp to target
|
||||
CMP :TARGET ; Compare with target
|
||||
BCS :CLAMP ; If target < sum, clamp to target
|
||||
BRA :UPDATE
|
||||
@ -743,7 +742,7 @@ ADSRPHASE STX OSCNUM
|
||||
:S2 TYA ; Change/step -> A
|
||||
CLC
|
||||
ADC CURRAMP,X ; Add change to current amp
|
||||
BCS :CLAMP ; If overflow, clamp to target
|
||||
BCS :CLAMP ; If overflow (-ve), clamp to target
|
||||
CMP :TARGET ; Compare with target
|
||||
BCC :CLAMP ; If target >= sum, clamp to target
|
||||
BRA :UPDATE
|
||||
|
@ -2,6 +2,7 @@
|
||||
* (c) Bobbi 2022 GPLv3
|
||||
*
|
||||
* Ensoniq DOC Driver for Apple IIGS.
|
||||
* Simulates Hitachi SN76489 sound generator chip found in BBC Micro.
|
||||
*
|
||||
|
||||
* Ensoniq control registers
|
||||
@ -145,7 +146,13 @@ ENSQNOTE PHA
|
||||
CPX #$00
|
||||
BEQ :NOISE ; Oscillator 0 is noise channel
|
||||
|
||||
PHA ; Stash orig freq
|
||||
CPX #$01 ; Oscillator 1 controls noise freq
|
||||
BNE :S0 ; Not 1? Skip
|
||||
CMP #$00 ; If frequency is zero ..
|
||||
BEQ :S0 ; .. skip
|
||||
STA :CH1NOTE ; Store frequency for noise gen
|
||||
|
||||
:S0 PHA ; Stash orig freq
|
||||
TAY
|
||||
LDA EFREQLOW,Y
|
||||
TAY ; Frequency value LS byte
|
||||
@ -232,6 +239,7 @@ ENSQNOTE PHA
|
||||
:NOISENOTE DB 149 ; BBC Micro note P=0 or 4
|
||||
DB 101 ; BBC Micro note P=1 or 5
|
||||
DB 53 ; BBC Micro note P=2 or 6
|
||||
:CH1NOTE DB 00 ; Note on channel 1
|
||||
|
||||
|
||||
* Adjust frequency of note already playing
|
||||
|
0
mame_applecorn
Normal file → Executable file
0
mame_applecorn
Normal file → Executable file
Loading…
Reference in New Issue
Block a user