Browse Source

Update makehist

git-svn-id: https://bucket.mit.edu/svn/nilm/zoom@9085 ddd99763-3ecb-0310-9145-efcb8ce7c51f
tags/zoom-1.0
nilm 12 years ago
parent
commit
3de3af7169
1 changed files with 7 additions and 7 deletions
  1. +7
    -7
      pc/data/20110106/makehist.m

+ 7
- 7
pc/data/20110106/makehist.m View File

@@ -1,13 +1,13 @@
# Make a histogram of the error (in milliamps)

#a=load("log-locked");
#len=size(a,1)
#keith=a(:,3);
#calib=a(1,4)
#dac=a(:,5);
#adc=a(:,6);
a=load("log2-locked");
len=size(a,1)
keith=a(:,3);
calib=a(1,4)
dac=a(:,5);
adc=a(:,6);
#lookup=load("../../../firmware/lookup.inc");
#meas=-(lookup(dac + 1)/64 - calib * adc);
meas=-(dac - calib * adc);
keith_amps = keith * 50; # 50 turns
p = polyfit(meas, keith_amps, 1)
meas_amps = meas * p(1) + p(2); # calibration fit


Loading…
Cancel
Save