[ubuntu-uk] Reverse engineering data files

Paul Sladen ubuntu at paul.sladen.org
Wed Nov 26 12:29:47 UTC 2014

On Wed, 26 Nov 2014, Gareth France wrote:
> > f2 80 05   f3 4e 08   f6 80 49 00 08   f8 80 00  (Washing machine)
> > f2 80 06   f3 4e 08   f6 80 01 00 08   f8 80 00  (Fridge)
> ID	Earth	Insulation	Load	Leakage	Continuity	Descript
> D7785	0.05	>99.99		0.05	0.73	(No result)	Washing Machine
> D7786	0.06	>99.99		0.05	0.1	(No result)	Fridge

I recall this thread started with the premise of obtaining extra
detail ("...several features which are only downloadable in their
custom format").  I don't think we should be surprised when we do
find that extra precision is available in the file, beyond
the rounded/simplified values shown on the display/report output.

Reviewing the specification for another Seaward PAT tester suggests
that the Earth Insulation measuring range is going to be in the range:

  Seaward SuperNova Plus - Pat Testing Equipment
  Range 40mΩ - 19.99mΩ  <---------------
  Resolution 0.01Ω
  Accuracy +/- 5% of reading, +/- 2 digits upto 5.00Ω 

Therefore we can expect that the sampled value is likely
somewhere between 40 and 1999 units.  And indeed we find:

  0x4e08 (19976 decimal)

So it would be reasonable to conclude that the test equipment measures
and stores a value between 0 and 19999 kOhms, and that the measured
value is simplified (for display purposes only) to a percentage.

> Also in there may be visual test pass/fail,

In the sample provided D7782, D7783 were both failed with broken
strain reliefs; these two records show '0x02' while the rest show
'0x01' at the expected position (so this is the visual pass/fail).

> (25A, 10A, 100ma) but this is probably stored in that large string.

I don't have domain-specific knowledge about how test-parameter
strings are configured, but they clearly follow a pattern:

  "K8B7000021 S121111111"
  "K3C7000021 S121111111"
  "I1C7003061 S121111111"

  "H172008021 S121111111"
  "H1C2008021 S121111111"
  "I010000022 S121111111"

To establish the mapping for (25A, 10A, 100ma) only requires
performing the three tests (without changing anything else) and
posting the results! [1]


[1] (I can't do this as I don't have the device...)

More information about the ubuntu-uk mailing list