Second CPU for audio processing?

All information relating to the Alpha plus all the WIP threads etc.
User avatar
exxos
Site Admin
Site Admin
Posts: 23763
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Second CPU for audio processing?

Post by exxos »

sandord wrote: Tue Oct 02, 2018 10:34 pm It would be great if the second CPU would do mixing as well, only then the primary CPU will have nearly nothing to do. Sort of DMA-functionality where the second CPU plays 4 (or more) separate channels from memory at arbitrary frequencies (the frequency defines the note the specific note is played at). This would work better than the STE DMA, which only supports a handful of frequencies.
The second CPU could do anything.. I'm just trying to think of ways for keeping it all as simple as possible. Though of course we don't really want to add a second YM chip to do this stuff.. Its why I was thinking more towards DAC's (ones running on the second CPU so not DMA access stuff).

The second CPU could just output data to the dacs instead of the YM chip. Of course YM is only 8 bit.. so not much data passing there. CPU direct can do 16bit to dac.. 2x8bit data channels output direct to DAC's.. then output next 16bit to the second DAC channels (4 total). So it shouldn't need the YM chip.. In fact we probably only need 2x8bit dacs, just output audio channels one after another, or mix the data.. no idea.. though with the speed this new CPU be running at, it could have a lot more channels..

CPU would need to render all frequencies for each sample, We would have a lot more RAM to play with if it made things easier..but would need a programmer to do all this and tell me what is needed and whats possible to do.
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
sandord
Posts: 673
Joined: Mon Aug 13, 2018 10:08 pm
Location: The Netherlands
Contact:

Re: Second CPU for audio processing?

Post by sandord »

exxos wrote: Tue Oct 02, 2018 10:47 pm The second CPU could just output data to the dacs instead of the YM chip. Of course YM is only 8 bit.. so not much data passing there. CPU direct can do 16bit to dac.. 2x8bit data channels output direct to DAC's.. then output next 16bit to the second DAC channels (4 total). So it shouldn't need the YM
Why would you want more than 2 DAC channels? You're not thinking surround sound, are you? :lol:
User avatar
exxos
Site Admin
Site Admin
Posts: 23763
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Second CPU for audio processing?

Post by exxos »

sandord wrote: Tue Oct 02, 2018 10:52 pm Why would you want more than 2 DAC channels? You're not thinking surround sound, are you? :lol:
Nah, was thinking 4 channels for tracker needing 4 dacs, but they can be multiplexed so only need 2 dacs. Could even output 16bit per channel I guess.
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
sandord
Posts: 673
Joined: Mon Aug 13, 2018 10:08 pm
Location: The Netherlands
Contact:

Re: Second CPU for audio processing?

Post by sandord »

exxos wrote: Wed Oct 03, 2018 12:15 am Nah, was thinking 4 channels for tracker needing 4 dacs, but they can be multiplexed so only need 2 dacs. Could even output 16bit per channel I guess.
Or we could mix an arbitrary number of 8 bit channels into a 16 bit output buffer and apply filtering to take further advantage of the 16 bits DAC (a low pass filter, like the Amiga has if I'm right). This would keep memory pressure down (by 50%) and we could do the filtering in software.

Another audio-driven idea would be using the second CPU to use a synthesis approach, kind of like chip mods work where only very small looped samples are used. The samples (basic waveforms) could easily fit into some small dedicated RAM (a few hundred bytes) and further reduce main memory load to zero. Of course this could work with larger RAM amounts as well but I somehow like the minimalistic approach. Well, that's just me I suppose :D

Basically, there could be 100s of applications, just like the Falcon's 56K which is really a multi purpose copro. Speaking of which... Nah :lol:
User avatar
exxos
Site Admin
Site Admin
Posts: 23763
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Second CPU for audio processing?

Post by exxos »

Yeah, I guess the software guys would have to think about it all, I can build the hardware , but I can't do the software. Of course doing stuff "better" is making more programming work.. I don't know how much is involved in creating updated tracker code.
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
sandord
Posts: 673
Joined: Mon Aug 13, 2018 10:08 pm
Location: The Netherlands
Contact:

Re: Second CPU for audio processing?

Post by sandord »

exxos wrote: Wed Oct 03, 2018 12:37 am Yeah, I guess the software guys would have to think about it all, I can build the hardware , but I can't do the software. Of course doing stuff "better" is making more programming work.. I don't know how much is involved in creating updated tracker code.
Given the existence of STE trackers/players, I would say that porting them won't be too much effort if the second CPU would emulate the STE DMA sound using the same hardware registers or at least the same behaviour. The second CPU would need a dedicated timer though that supports the STE DMA frequencies. Just a thought.
User avatar
exxos
Site Admin
Site Admin
Posts: 23763
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Second CPU for audio processing?

Post by exxos »

sandord wrote: Wed Oct 03, 2018 12:44 am Given the existence of STE trackers/players, I would say that porting them won't be too much effort if the second CPU would emulate the STE DMA sound using the same hardware registers or at least the same behaviour. The second CPU would need a dedicated timer though that supports the STE DMA frequencies. Just a thought.
I never thought about the STE trackers.. should be some I assume which output to the DAC's direct.. A PLD can control/emulate what is needed.
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
rpineau
Posts: 534
Joined: Thu Aug 17, 2017 6:08 pm
Location: USA
Contact:

Re: Second CPU for audio processing?

Post by rpineau »

It needs DMA from memory (integrated in the GSTMCU + GSTSHIFTER, GSTMCU does the DMA and generate sclk, sreq and /sload, SHIFTER does the 16 bit ST data bus to 2x8bit output using sclk, sreq, /sload on the input and /LD and /RD to the 374 latch for the 2 DACs 0802 ), interrupt to MFP (IO7 and TAI) for the end of buffer int, sound clock (from GSTMCU), LMC1992 (probably not needed as we don't need to mix anything) , DAC.

Hopefully I'm not missing any big part in there.
Working ones : MegaSTE (68020) / TT030 / Falcon with AB040 & Eclipse / 1040STF
Need testing : Falcon with CT2
User avatar
exxos
Site Admin
Site Admin
Posts: 23763
Joined: Wed Aug 16, 2017 11:19 pm
Location: UK
Contact:

Re: Second CPU for audio processing?

Post by exxos »

Probably all is needed is a load signal to some DAC latches. Saying that, I haven't looked in DAC's yet. Possible the clock is the sample latch internally, so really just need to treat that as more data enable signal. Code can probably output to same STE DAC address, it will be its own bus totally, so wouldn't any conflicts is main CPU used any DAC functions. In that case would need 4x8bit dacs to keep compatibility with old software also.
https://www.exxosforum.co.uk/atari/ All my hardware guides - mods - games - STOS
https://www.exxosforum.co.uk/atari/store2/ - All my hardware mods for sale - Please help support by making a purchase.
viewtopic.php?f=17&t=1585 Have you done the Mandatory Fixes ?
Just because a lot of people agree on something, doesn't make it a fact. ~exxos ~
People should find solutions to problems, not find problems with solutions.
User avatar
rpineau
Posts: 534
Joined: Thu Aug 17, 2017 6:08 pm
Location: USA
Contact:

Re: Second CPU for audio processing?

Post by rpineau »

There is only 2 DACs on the STE. Trackers mix the 4 tracks (or more) into 2 stereo tracs for the STE DACs and use the DMA to play the buffers (using buffer swapping for continuous playback). The sclk is used to drive the data latching on the shifter (16 bits) and then /LD and /RD are used to latch the data in the 374 for the DACs (2x 8bit).
So to keep things compatible with STE trackers you'll need a DMA (CPLD) at the same address (0x00FF8900-0x00FF8921) performing the same operation (running through the address to access RAM data to be latched to the DACs), an interrupt controller to trigger the interrupt when reaching end of buffer/record, and 2 DACs (stereo) and ha this runs at the same sampling frequency as the STE. Some tracker probably also access the microwire interface (access to LMC1992 mixer).
Working ones : MegaSTE (68020) / TT030 / Falcon with AB040 & Eclipse / 1040STF
Need testing : Falcon with CT2
Post Reply

Return to “ALPHA DEVELOPMENT INFO”