Help with Maxim Ibutton "IF THEN ELSE" statements please


Closed Thread
Results 1 to 39 of 39

Hybrid View

  1. #1
    Join Date
    Oct 2005
    Location
    Sweden
    Posts
    3,624


    Did you find this post helpful? Yes | No

    Default Re: Help with Maxim Ibutton "IF THEN ELSE" statements please

    Hi,
    Tried the above and variants of it....It is now just going staight to the gosub routine (wrong) I suspect because with no Ibutton in place the "Serial Number" is after all wrong!!
    Well, if what you're saying is that you don't actually have an IButton connected then I think you've found the problem. Of course the numbers will be wrong, none of the IF statements will evaluate TRUE so the exection will fall thru to the GOSUB wrong statement.
    Help........!!!!
    This may sound like a totally crazy idea but you might try connecting an IButton and see if that possibly helps.

    :-)

    /Henrik.

  2. #2
    Join Date
    May 2012
    Location
    Merseyside, UK
    Posts
    237


    Did you find this post helpful? Yes | No

    Default Re: Help with Maxim Ibutton "IF THEN ELSE" statements please

    Hi Henrick

    Yes works fine with button....But!

    A lot of the time it needs to sit waiting for a button (looping till it sees one... then it jumps to sub routine if right button) "If" wrong button applied I need to jump out and go elsewhere !

    So yes a lot of waiting with no button.

  3. #3
    Join Date
    Jun 2009
    Location
    Sc*nthorpe, UK
    Posts
    333


    Did you find this post helpful? Yes | No

    Default Re: Help with Maxim Ibutton "IF THEN ELSE" statements please

    Andy,

    I get it now!

    You are validating ibuttons that are not always present. In fact most of the time there will not be an ibutton to read.

    You are saying you need to detect the presence of an ibutton and when detected check it's serial number and if correct take some action (open a lock for example) if incorrect take some other action (sound an alarm for example)

    Is this true?

  4. #4
    Join Date
    May 2012
    Location
    Merseyside, UK
    Posts
    237


    Did you find this post helpful? Yes | No

    Default Re: Help with Maxim Ibutton "IF THEN ELSE" statements please

    That is the Badger!

    Yes.

  5. #5
    Join Date
    Jun 2009
    Location
    Sc*nthorpe, UK
    Posts
    333


    Did you find this post helpful? Yes | No

    Default Re: Help with Maxim Ibutton "IF THEN ELSE" statements please

    Your program needs a loop that checks for the presence of an ibutton and if not present continue looping other wise jump out the loop into a serial number read/verify routine eventualy going back to the loop.

    Any ideas of how to test for an ibutton present?

Similar Threads

  1. Replies: 0
    Last Post: - 14th November 2013, 04:32
  2. Replies: 3
    Last Post: - 15th October 2012, 09:06
  3. Replies: 8
    Last Post: - 3rd March 2011, 23:20
  4. Replies: 5
    Last Post: - 28th February 2011, 16:33
  5. Replies: 1
    Last Post: - 16th February 2005, 21:05

Members who have read this thread : 0

You do not have permission to view the list of names.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts