shithub: choc

Download patch

ref: 54c2e6d4e513cd74fa35e05f9de840c4a8647b8d
parent: 7c377fc88a3fbb7f69b91a15dc414c8965624a89
author: Nuke.YKT <alexeytf2@gmail.com>
date: Thu May 28 22:12:23 EDT 2015

One result checking is enought to detect OPL3.

--- a/opl/opl.c
+++ b/opl/opl.c
@@ -321,7 +321,7 @@
     {
         result1 = OPL_ReadPort(OPL_REGISTER_PORT);
         result2 = OPL_ReadPort(OPL_REGISTER_PORT_OPL3);
-        if (result1 == 0x00 && result2 == 0xff)
+        if (result1 == 0x00)
         {
             return 2;
         }