Limits patch for E-field sensor

Hilfe und Informationen zur Firmware der SPECTRAN NF- Serie
Firmware related help and information for the SPECTRAN NF- series

Limits patch for E-field sensor

Postby Moderator » Thursday 3. January 2013, 13:07

I patched programme 150 to have TCO and ICNIRP to run with the e-field sensor.
I wasn't sure if you appreciate seeing code modified from your firmware in a public forum. I happily share what I've done. I replaced the programme 150 with the code below, it compares against TCO03 and ICNIRP levels (as in the manual) for the e-field and magnetic sensor. One should patch the programme for the key 'right' to allow only two profiles as well.


Code: Select all
     LOADSET PEAK1FREQ
    STOREVAR 03h
    LOADSET SPECDISP
    JUMPNZ LABEL-1
    LOADSET PEAK1POW
    LOADSET PEAK1FREQ
    ACALL PROG-0
    LOADSET PEAK2POW
    LOADSET PEAK2FREQ
    ACALL PROG-0
    MAX
    LOADSET PEAK3POW
    LOADSET PEAK3FREQ
    ACALL PROG-0
    MAX
    DUP
    PPIXBAR 02h
    LDCONST 100
    MUL
    PPIXDBL 00h, 0100h, "###.##"
    LOADVAR 01h
    LDSHCO 01h
    JUMPEQ LABEL-2
    PPIXTEXT 00h, 0000h, "TCO03"
    JUMP LABEL-1
    LABEL-2:
    PPIXTEXT 00h, 0000h, "ICNIRP"
    LABEL-1:
    STOP
    PROG-0:
    STOREVAR 02h
    LOADVAR 02h
    LOADVAR 01h
    LDSHCO 01h
    JUMPEQ LABEL-3
    LDSHCO 02h
    JUMPGE LABEL-4
    LOADSET PULSEMODE
    LDSHCO 06h
    JUMPGE LABEL-5
    LDCONST 0.000000200
    JUMP LABEL-6
    LABEL-5:
    LDCONST 10
    JUMP LABEL-6
    LABEL-4:
    LOADSET PULSEMODE
    LDSHCO 06h
    JUMPGE LABEL-7
    LDCONST 0.000000025
    JUMP LABEL-6
    LABEL-7:
    LDCONST 1
    JUMP LABEL-6
    LABEL-3:
    LOADSET PULSEMODE
    LDSHCO 06h
    JUMPGE LABEL-8
    LDSHCO 96h
    JUMPGE LABEL-9
    LOADVAR 02h
    LDCONST 0.8
    JUMPGE LABEL-10
    LOADVAR 02h
    LDCONST 0.008
    JUMPGE LABEL-11
    LOADVAR 02h
    LDCONST 0.001
    JUMPGE LABEL-12
    LDCONST 0.040
    JUMP LABEL-6
    LABEL-12:
    LDCONST 0.000000040
    LOADVAR 02h
    SQUARE
    DIV
    JUMP LABEL-6
    LABEL-11:
    LDCONST 0.000005
    LOADVAR 02h
    DIV
    JUMP LABEL-6
    LABEL-10:
    LDCONST 0.000006250
    JUMP LABEL-6
    LABEL-9:
    LDCONST 0.000920
    LOADVAR 02h
    DIV
    JUMP LABEL-6
    LABEL-8:
    LDCONST 1000
    JUMPGE LABEL-13
    LOADVAR 02h
    LDCONST 3
    JUMPGE LABEL-14
    LOADVAR 02h
    LDCONST 0.025
    JUMPGE LABEL-15
    LDCONST 10000
    JUMP LABEL-6
    LABEL-15:
    LDCONST 250
    LOADVAR 02h
    DIV
    JUMP LABEL-6
    LABEL-14:
    LDCONST 87
    JUMP LABEL-6
    LABEL-13:
    LDCONST 87
    LOADVAR 02h
    SQRT
    DIV
    JUMP LABEL-6
    LABEL-6:
    DIV
    RET
    STOP


Original thread see viewtopic.php?f=31&t=176&start=0&hilit=electric
Moderator
 
Posts: 1036
Joined: Tuesday 20. April 2010, 13:24
Location: Aaronia AG

Return to NF

Who is online

Users browsing this forum: No registered users and 2 guests

cron