Previous Thread
Next Thread
Print Thread
Page 5 of 7 1 2 3 4 5 6 7
Joined: Feb 2007
Posts: 507
C
Senior Member
Offline
Senior Member
C
Joined: Feb 2007
Posts: 507
Open MP : https://www.openmp.org

It's an compiler extension. I don't like it. It has the usual cheap win appeal but if e.g. you go GPU it really get's awful. nvcc is a lot nicer, more transparent and in the end better to understand. Well, in the end you abstract different backends by templates, anyhow.

Joined: Jun 2003
Posts: 58
C
Member
OP Offline
Member
C
Joined: Jun 2003
Posts: 58
Originally Posted by couriersud
Open MP : https://www.openmp.org

It's an compiler extension. I don't like it. It has the usual cheap win appeal but if e.g. you go GPU it really get's awful. nvcc is a lot nicer, more transparent and in the end better to understand. Well, in the end you abstract different backends by templates, anyhow.

Ah, that (OpenMP). Which from checking the makefile I assume isn't built in anyway unless OPENMP is enabled for the build.

Joined: Feb 2007
Posts: 507
C
Senior Member
Offline
Senior Member
C
Joined: Feb 2007
Posts: 507
Originally Posted by Colin Howell

Ah, that (OpenMP). Which from checking the makefile I assume isn't built in anyway unless OPENMP is enabled for the build.


Yes, for certain builds, though can't remember which, it caused issues. Using c++ threads should be sufficient for the purpose as well, just need to find the time.

Joined: Jun 2003
Posts: 58
C
Member
OP Offline
Member
C
Joined: Jun 2003
Posts: 58
OK, an update. At this point I'm about ready to cut a branch, commit, and submit a pull request. The driver works, though I still have some issues with it.

I'm now using an appropriate Zener with a normally-distributed noise voltage source added as the basis for the noise generator: the ad-hoc random current generator is gone.

I also abandoned the low-gain hack of the op-amp after I discovered that getting the oscillators to run at the right frequency and voltage range with that op-amp hack was no easier than with the standard op-amp model with normal gain: I was only getting increased numerical stability because the lower gain kept the oscillator running in a narrower voltage range. Instead I went back to the method of putting a frontier on the Schmitt trigger op-amp's output, which seems to remove the numerical stability problem. Some slight tweaking of the Schmitt trigger op-amp's resistors corrects any change in frequency and voltage range. I no longer adjust the oscillator capacitors.

I removed one of the op-amps in the final amplification stage, since it was effectively unused. Its only purpose in the real circuit is to invert the other op-amp's output so that the final power amps can get opposing signals in order to drive the speaker "push-pull" style.

I took out the reduced accuracy and tolerance parameters for the solver. They didn't improve speed much and reduced sound quality.

Unthrottled performance with static solvers is still around 170%-220% of full speed on my machine, depending on sound workload.

The sound seems higher in treble and lower in bass than what I hear in the few videos of real 280-ZZZAP machines I can find, and the "skid" sound is less distinct than on those machines. Oh well. That may be a difference in the machine's audio "front end" (is that the correct term?). There also may be some differences in component values between the schematic I used and real PCBs. It would be nice to compare with real PCB photos, but I can't find any.

This driver should also be able to support Laguna Racer and Super Speed Race, but there are some component value differences (and circuit differences for Super Speed Race). I don't know how best to handle that: duplicating the whole netlist with components changed seems clumsy. Is there a way to parameterize or have conditional code in a netlist?

Joined: Jun 2003
Posts: 58
C
Member
OP Offline
Member
C
Joined: Jun 2003
Posts: 58
Further brief update: commits made and pull request now submitted.

Joined: Mar 2001
Posts: 16,613
R
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,613
BTW, the thump when you crash is actually pretty bassy on decent headphones. I imagine in the cabinet it's amplified a lot more.

Joined: Mar 2001
Posts: 16,613
R
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,613
Just saw this reference video: https://www.youtube.com/watch?v=0RA-42dPnPk

The main thing I hear different is that the skid is a lot louder on the real cabinet than in MAME right now.

Joined: Jun 2003
Posts: 58
C
Member
OP Offline
Member
C
Joined: Jun 2003
Posts: 58
Yeah, that was one of the things I noted. Tried to make sure the noise effects were as loud as possible without distortion, but there doesn't seem to be any more headroom for that as the circuit is currently set up. One of the reasons I'd like to check against real PCBs.

Joined: Jun 2003
Posts: 58
C
Member
OP Offline
Member
C
Joined: Jun 2003
Posts: 58
OK, I am now certain I made 280-ZZZAP's noise *far* too weak.

All that time messing around with Gun Fight again, which also uses a zener-diode noise generator, taught me quite a bit about how noise is generated with a "zener" (really an avalanche diode) and roughly how strong you can expect that noise to be for a given zener current. Gun Fight runs around 2 microamps of current through its zener and probably gets a few millivolts of noise from that. 280-ZZZAP runs about 25 microamps of current through its zener and so should probably get tens of millivolts of noise The noise figure I used for 280-ZZZAP is 10 *microvolts*, three orders of magnitude too low.

In 280-ZZZAP the zener noise is amplified by an LM3900 Norton op-amp, not by a simple transistor-based common-emitter amplifier as in Gun Fight. I mistakenly assumed that the noise generated was intended to be relatively undistorted by that op-amp, and based on that I figured an upper limit on the strength of the noise. The truth appears to be the opposite: the noise is expected to *completely saturate* the op-amp, which converts it into a rail-to-rail, quasi-digital noise signal. In retrospect, this makes a lot more sense, given that zener (avalanche) diodes are extremely variable in the strength of their noise, even within the same batch. This saturated op-amp setup must have been a way of getting a more controlled, predictable noise signal regardless of the particular zener's qualities. (Eventually, people switched to the even more predictable linear-feedback shift register type of digital "noise" generator.) Once the saturated rail-to-rail noise is generated, the subsequent filters convert it into the desired forms for sounds.

With the zener's noise cranked up into the millivolts range, the skid noise becomes quite prominent, and there's much more low-frequency rumble on the crash, not just the extreme bass "thump". The post-crash noise is still a peculiar screech, but that's true on real machines too—it's hard to figure out what the designer was thinking with that one.

Joined: Mar 2001
Posts: 16,613
R
Very Senior Member
Offline
Very Senior Member
R
Joined: Mar 2001
Posts: 16,613
Neat. Can't wait to hear it.

Page 5 of 7 1 2 3 4 5 6 7

Link Copied to Clipboard
Who's Online Now
1 members (r09), 36 guests, and 3 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics8,836
Posts116,222
Members4,921
Most Online890
Jan 17th, 2020
Powered by UBB.threads™ PHP Forum Software 7.7.5