Show: Today's Messages :: Show Polls :: Message Navigator |
Atari Lynx Stereo support [message #2998] | Thu, 14 March 2013 09:41 | |||
| ||||
Even so there are only few games supporting Stereo output on the Lynx (model 2), I added support for the corresponding registers as well as output. See attached file for patches against to 9.28wip I tested with Xenophobe and Klax as well as some private test ROMs setting these registers. ADD: After testing some more ROMs, it turned out, the ATT register does not need to be inverted... the name is misleading. I fixed that and replaced the diffs. Check now with: Battle Wheels, Dirty Larry, Klax, Lemmings, RoadBlasters, Robo-Squash, Robotron 2084, Xenophobe, Remnant, Sokomania and Slideshows ... which support either stereo or attenuation plus i check a lot of the roms which dont if there sound still works, too.
(Size: 7.09KB, Downloaded 246 time(s)) Attachment: mikie.h.diff (Size: 0.42KB, Downloaded 244 time(s)) Attachment: system.cpp.diff (Size: 0.70KB, Downloaded 228 time(s)) [Updated on: Thu, 14 March 2013 22:26] http://lynxdev.atari.org | ||||
|
Re: Atari Lynx Stereo support [message #3280 is a reply to message #2998 ] | Sun, 15 December 2013 12:06 | |||
| ||||
Now the code has been adopted to latest WIP version. Thnak you. nevertheless, I found some deviations from hardware: Its only a small difference, but anyway. --- mednafen/src/lynx/mikie.cpp +++ mednafen-0.9.31/src/lynx/mikie.cpp @@ -1795,24 +1795,24 @@ teatime >>= 2; for(x = 0; x < 4; x++){ /// Assumption (seems there is no documentation for the Attenuation registers) - /// a) they are linear from $0 to $f - /// b) an attenuation of $0 is equal to channel OFF (bits in mSTEREO not set) - /// c) an attenuation of $f is equal to no attenuation (bits in PAN not set) - /// These assumptions can only checked with an oszilloscope... + /// a) they are linear from $0 to $f - checked! + /// b) an attenuation of $0 is equal to channel OFF (bits in mSTEREO not set) - checked! + /// c) an attenuation of $f is NOT equal to no attenuation (bits in PAN not set), $10 would be - checked! + /// These assumptions can only checked with an oszilloscope... - done /// the values stored in mSTEREO are bit-inverted ... /// mSTEREO was found to be set like that already (why?), but unused - + if(mSTEREO & (0x10 << x)) { if(mPAN & (0x10 << x)) - cur_lsample += (mAUDIO_OUTPUT[x]*(mAUDIO_ATTEN[x]&0xF0))/(15*16); + cur_lsample += (mAUDIO_OUTPUT[x]*(mAUDIO_ATTEN[x]&0xF0))/(16*16); /// NOT /15*16 see remark above else cur_lsample += mAUDIO_OUTPUT[x]; } if(mSTEREO & (0x01 << x)) { if(mPAN & (0x01 << x)) - cur_rsample += (mAUDIO_OUTPUT[x]*(mAUDIO_ATTEN[x]&0x0F))/15; + cur_rsample += (mAUDIO_OUTPUT[x]*(mAUDIO_ATTEN[x]&0x0F))/16; /// NOT /15 see remark above else cur_rsample += mAUDIO_OUTPUT[x]; } http://lynxdev.atari.org | ||||
|
Re: Atari Lynx Stereo support [message #3581 is a reply to message #2998 ] | Sat, 28 June 2014 05:05 | |||
| ||||
Bump. Seems the latest fixes did not make it into mednafen (checked 0.9.36). http://lynxdev.atari.org | ||||
|
Re: Atari Lynx Stereo support [message #3582 is a reply to message #2998 ] | Sat, 28 June 2014 09:27 | |||
| ||||
I forgot about it, it'll be in 0.9.37 or 0.9.36.3.
[Updated on: Sat, 28 June 2014 09:29] | ||||
|
Re: Atari Lynx Stereo support [message #3697 is a reply to message #2998 ] | Thu, 11 September 2014 11:56 | |||
| ||||
I included the fixes in 0.9.36.4. | ||||
|
Re: Atari Lynx Stereo support [message #3714 is a reply to message #3697 ] | Sun, 21 September 2014 06:55 | |||
| ||||
Thank you. Maybe now I can make a new attempt with the extended ROM access stuff or rewriting the messed up sound code ) http://lynxdev.atari.org | ||||
|
Previous Topic: | System (or game) specific .CFG |
Next Topic: | For Developers of Mednafen from Solyanka-Team |