From 98c57c9d87bbf6e7b3056800dd544f15066194fd Mon Sep 17 00:00:00 2001
From: jim <jim@ddd99763-3ecb-0310-9145-efcb8ce7c51f>
Date: Fri, 13 Jun 2008 19:48:51 +0000
Subject: [PATCH] update notes

git-svn-id: https://bucket.mit.edu/svn/nilm/zoom@6583 ddd99763-3ecb-0310-9145-efcb8ce7c51f
---
 notes-a6302.txt | 22 +++++++++++++++++++++-
 1 file changed, 21 insertions(+), 1 deletion(-)

diff --git a/notes-a6302.txt b/notes-a6302.txt
index f040456..0ed97f5 100644
--- a/notes-a6302.txt
+++ b/notes-a6302.txt
@@ -17,7 +17,27 @@ to scale the probe output.  Scale by (4.32) so that
   1mA at probe = 43.2mV at PIC
   37.5μA at probe = 1.62mV at PIC
 
-(PIC input) = clamp(0, 1.25V - (probe output * 4.32), 2.5V)
+(PIC input) = clamp(0, 1.25V - (probe current * 10 * 4.32), 2.5V)
 
 Clamp by putting a 1K in series with diodes to VSS/VDD.
 
+----------
+
+DAC range is ± 10 A.
+Probe range should be about 2^-14 as big, so ±610 μA
+which is 0.000610*10*4.32 = 26.35 mV.
+
+PIC measurements:
+  (1.25V + 26.35mV) / (2.50 / 2^12) = 2091
+  (1.25V - 26.35mV) / (2.50 / 2^12) = 2004
+
+--
+
+1 bit change at DAC is 1.2mA.
+At PIC, the voltage will change by (1.2mA * 10mV/mA * 4.32) = 0.518 mV
+This means changing 1 bit at the DAC should cause the PIC count to change by
+0.518 mV / (2.50 / 2^12) = 84.935
+
+To reset the PIC input to 2048, we therefore need to step the DAC by 
+((2048 - count) / 84.935)
+