Shop OBEX P1 Docs P2 Docs Learn Events
RCTIME Question? — Parallax Forums

RCTIME Question?

MichelBMichelB Posts: 154
edited 2009-07-22 07:25 in BASIC Stamp
Hi all, in BASIC Stamp Manual and in Help of BASIC Stamp Editor v2.4.2 we can see:
time = -tau x (ln(Vfinal / Vinitial))
Time = -1 x 10E-3 x (ln(5.0v / 1.4v)) = 1.273 x 10E-3, Where the sign "-" gone?

Comments

  • Tracy AllenTracy Allen Posts: 6,662
    edited 2009-07-20 16:12
    ln(.) should have the smaller final value in the numerator and the larger final value in the denominator, and the ln(.) of a ratio less than one is a negative number, times the negative tau, is a positive result.

    Vfinal=1.4
    Vinitial=5
    ln(1.4/5) = ln(0.28) = -1.272965675813

    and
    -1E-3 * -1.272965675813 = +1.272965675813 E-3

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • MichelBMichelB Posts: 154
    edited 2009-07-21 07:35
    You are right dear Mr Allen, but the following line in the Help of BASIC Stamp Editor v2.4.2·"Time= ... (ln(5.0v / 1.4v))..." is wrong and must be "... (ln(1.4v / 5.0v))...". By the way I'll begin Applied Sensors and I want to know what lines from your App-notes must I add to have more precision with DS1620. Thank you and best regards.
  • Tracy AllenTracy Allen Posts: 6,662
    edited 2009-07-21 16:32
    Good catch on the mistake in the help file.

    I have an article on the high resolution mode of the DS1620 posted at www.emesys.com/OL2d1620.htm#DS1620-HR. Dallas Semi revised the DS1620 so that the counts per degree is now fixed at 16, rather than a higher but variable number. The code still works, with either the old or the new version of the chip.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Tracy Allen
    www.emesystems.com
  • MichelBMichelB Posts: 154
    edited 2009-07-21 17:08
    Thank you sir and best regards.
  • Steph LindsaySteph Lindsay Posts: 767
    edited 2009-07-21 17:25
    Thank you for reporting the error in the Help file, and good timing since I am working on an update for it. Sorry the error caused you trouble!

    -Stephanie Lindsay
    Editor, Parallax Inc.
  • MichelBMichelB Posts: 154
    edited 2009-07-22 07:25
    Your welcome Steph.

    Best regards.
Sign In or Register to comment.