OCZ NIA reverse engineering (full schematic) - Page 1
Forum section: electronics / projects

author: hammil
author_rank: Regular Contributor
timestamp: April 05, 2013, 12:30:53 am
content: Okay, so I've seen a few groups doing this sort of stuff, but none have, as far as I know, done it as.. completely as I would like. Therefore, I present an almost-full schematic of the OCZ NIA+, that's the newer one.For those who don't know, the NIA is essentially the cheapest commercial ECG device, originally designed for gaming. It was a commercial flop due to the limited functionality of the windows software (seriously, it's pretty shoddy) that made it difficult to be used to, well, control games.However, the hardware is actually very well built. Apart from a few mods that were added in later revisions, it's very well designed, with sophisticated analogue filtering, 24-bit digital conversion (even though the last 8 bits are well within the noise floor) and a completely isolated analogue frontend.http://imgur.com/TGvyorE,yDhDC43The only thing I don't have in my schematic are values for the ceramic capacitors. I've got a decent-ish multimeter, but I can't seem to get values for any of the capacitors in-circuit, and I don't want to just desolder them all.In terms of my long-term objectives.. Well, I have already decoded the usb protocol used, and made basic linux drivers for this thing. On the software side, I only need to figure out how the different brain functions are decoded - probably using FFTs or similar.On a hardware front, I'm curious as to how all the analogue processing works, since it's far more complex than anything I've seen beforeSo yeah... that's what I've got. See attached

author: Rufus
author_rank: Super Contributor
timestamp: April 05, 2013, 01:39:57 am
content: Quote from: hammil on April 05, 2013, 12:30:53 amIt doesn't look too complicated although it looks like there are a few mistakes still on your schematic.Front end is an instrumentation amp with a gain of 50 and U3 feeding back to keep the average output at half the ADC reference (effectively a high pass filter). I think the amp must be an AD8221 not 8211.U2B then amplifies the signal with a switchable gain of -1 or -10 with some high frequency roll off. I think U2 pins 5 and 10 should be ground and you have the channels crossed on U10. U2C looks like a 3 pole low pass filter and the output feeds the ADC. The ADC feeds data into a 24 bit shift register via ADUM1300 isolation and the PIC watches the shift reg load and reads it broadside. Looks like the ADC sample rate is 3.9kHz.So gain, filtering, 24bit digital conversion at 3.9kHz and I imagine the PIC spews data over USB for PC software to figure out what it means.

author: hammil
author_rank: Regular Contributor
timestamp: April 05, 2013, 01:57:48 am
content: Yeah, you're right about the amplifier - that was just a typo.Regarding the stuff with U2.. I double checked all that, and it appears to be correct. Pins 5 and 10 are definitely not grounded, or connected to any rails or references.You're right about the channels on U10... though how you knew that is beyond meWith the digital stuff, you're absolutely right of course. That's exactly what it does, but the ADC rate seems to be more in the range of 15-20KHz, judging from the USB data I analysed, which would make sense since it's an audio ADCThanks a lot for the help

author: Rufus
author_rank: Super Contributor
timestamp: April 05, 2013, 02:22:01 am
content: Quote from: hammil on April 05, 2013, 01:57:48 amThere is something not right around U2.I lost the data sheet on the ADC now but assuming MODE1 is ground (I doubt it is floating) I thought that made the sample rate clk/512 and the clock is 16MHz divided by 8 by U13 which makes 3.9kHz. 3 bytes per sample, stereo. Maybe the PIC sends both channels.

author: hammil
author_rank: Regular Contributor
timestamp: April 05, 2013, 02:49:55 pm
content: Aha.. found it. 5 and 10 on U2 are connected to pin 3 on U3, half the reference voltage, which would make sense.Regarding the various clocks... The system clock through the optocoupler is indeed 2MHz, and LRCK is indeed 3.9KHz.MODE1 is definitely floating... Eh, I guess it has an internal pull-down.

author: thmjpr
author_rank: Regular Contributor
timestamp: April 08, 2013, 04:02:54 am
content: Very nice, I can't add anything as I did not record capacitor values either, but attached is my original release version.Related patents if you haven't read them already:http://www.google.com/patents?id=lbgkAAAAEBAJ&dq=5692517http://www.google.com/patents?id=lrQOAAAAEBAJ&dq=6636763