From 3a06c9e474b56716439805e1187b28312656a6bd Mon Sep 17 00:00:00 2001 From: couriersud Date: Sun, 7 Apr 2019 19:04:43 +0200 Subject: Fix kidniki schematics after review. The kungfu master schematics differ from the kidnik schematics in wiring D4, D5 and Q4 with other components. The manual corrections to the kungfu master schematics make sense and thus are used here. opamp XU1.B according to schematics has no feedback loop between output and inputs. The arrangement of components in the schematic however indicate that this is not the case and indeed a connection exists. This results in sounds at output XU1.14 to contain more detail. --- src/mame/audio/nl_kidniki.cpp | 46 ++++++++++++++++++++++++++++++++----------- 1 file changed, 34 insertions(+), 12 deletions(-) diff --git a/src/mame/audio/nl_kidniki.cpp b/src/mame/audio/nl_kidniki.cpp index 380059740d7..99d8c662709 100644 --- a/src/mame/audio/nl_kidniki.cpp +++ b/src/mame/audio/nl_kidniki.cpp @@ -8,12 +8,35 @@ #ifndef NLTOOL_VERSION #define USE_FRONTIERS 1 -#define USE_FIXED_STV 1 +#define USE_FIXED_STV 0 #else #define USE_FRONTIERS 0 #define USE_FIXED_STV 1 #endif +/* + * Schematic errors: + * + * The kungfu master schematics differ from the kidnik schematics in wiring + * D4, D5 and Q4 with other components. The manual corrections to the + * kungfu master schematics make sense and thus are used here. + * + * opamp XU1.B according to schematics has no feedback loop between output and + * inputs. The arrangement of components in the schematic however indicate that + * this is not the case and indeed a connection exists. This results in sounds + * at output XU1.14 to contain more detail. + * + * You can observe sounds at XU1.14 by doing + * + * NL_LOGS=XU1.14 ./mame64 kidniki + * nlwav -o x.wav log_XU1.14.log + * play x.wav + * + */ + +#define FIX_SCHEMATIC_ERRORS (1) + + /* ---------------------------------------------------------------------------- * Library section header START * ---------------------------------------------------------------------------*/ @@ -38,16 +61,9 @@ NETLIST_START(kidniki_schematics) // IGNORED O_AUDIO0: O_AUDIO0 49 0 // .END - /* - * Workaround: The simplified opamp model does not correctly - * model the internals of the inputs. - */ - - ANALOG_INPUT(VWORKAROUND, 2.061) - RES(RWORKAROUND, RES_K(27)) - NET_C(VWORKAROUND.Q, RWORKAROUND.1) - NET_C(XU1.6, RWORKAROUND.2) - +#if FIX_SCHEMATIC_ERRORS + NET_C(XU1.7, C40.1) +#endif CAP(C200, CAP_N(100)) CAP(C28, CAP_U(1)) CAP(C31, CAP_N(470)) @@ -105,7 +121,7 @@ NETLIST_START(kidniki_schematics) QBJT_EB(Q7, "2SC945") QBJT_EB(Q9, "2SC945") - LM324_DIP(XU1) + LM2902_DIP(XU1) LM358_DIP(XU2) MC14584B_DIP(XU3) @@ -141,6 +157,7 @@ NETLIST_START(kidniki_schematics) RES(R43, 470) RES(R44, RES_K(100)) RES(R45, RES_K(1)) + //RES(R45, RES_K(10000000)) RES(R46, RES_K(12)) RES(R48, 470) RES(R48_2, RES_K(100)) @@ -244,7 +261,12 @@ NETLIST_START(kidniki_schematics) NET_C(R55.2, R90.2, C33.2, R37.1, Q3.E) NET_C(R45.1, C44.2) NET_C(C44.1, R66.2, Q4.B) +#if FIX_SCHEMATIC_ERRORS + NET_C(Q4.C, D4.K, D5.K) + NET_C(C42.1, C43.1, R46.1, C35.2) +#else NET_C(Q4.C, C42.1, C43.1, R46.1, C35.2, D4.K, D5.K) +#endif NET_C(R70.2, R69.2, Q7.C) NET_C(R63.1, Q7.E) NET_C(R69.1, C49.2) -- cgit v1.2.3