RFID Reader Module
All,
·
I am trying to connect the read tag number to a variable that I can use in IF THEN statements.· I am not understanding very well how you can read from a table of known tags and go to different areas of your program.
·
Any ideas on how to do this?
·
Thanks
·
Tim
·
I am trying to connect the read tag number to a variable that I can use in IF THEN statements.· I am not understanding very well how you can read from a table of known tags and go to different areas of your program.
·
Any ideas on how to do this?
·
Thanks
·
Tim
Comments
Go into you PBASIC file and look for LOOKUP or LOOKDOWN, much better then a if..then..else statement!
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
-Learn somthing about everything, and Everthing about somthing-
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
Thanks for the help.
Tim
You can look at what i done
I am not sure if will help you any or not
This a project where i need a·different routine for different cards this was the soilder station timer controler at this
Post http://forums.parallax.com/showthread.php?p=595469
And at this Post is where i learned how to write the routine
http://forums.parallax.com/showthread.php?p=586138
Tag1··········· DATA··· "04158DD890"·························· ' valid tags
Tag2··········· DATA··· "04158DCE28"
Tag3··········· DATA··· "04158DCA62"
Name0·········· DATA··· "........STOP.........", CR, 0
Name1·········· DATA··· "Tag 1 (15· MIN· CARD)", CR, 0
Name2·········· DATA··· "Tag 2 (30· MIN· CARD)", CR, 0
Name3·········· DATA··· "Tag 3 (1·· HOUR CARD)", CR, 0
Tag_Found:
ON tagNum GOSUB Routine0,· Routine1, Routine2, Routine3
'
[noparse][[/noparse]Card's Subroutines ]
' To use differnet Card for differnet amount of Time
' Card # 0 is fot Unauthorized CARD
' Card # 1 is fot 15 Minutes and 00 Seconds
' Card # 2 is fot 30 Minutes and 00 Seconds
' Card # 3 is fot 59 Minutes and 59 Seconds
·'15 Minutes CARD Routine
·Routine1:
· mins=$00
· secs=$00
· GOSUB Set_Time
· HIGH· led·································································· ' Turn ON Relay
· DO
··· GOSUB Get_Time
··· IF mins=$15 AND secs=$00 THEN EXIT
·· DEBUG HOME, HEX2 mins, ":", HEX2 secs, CR
·· DEBUG CR, CR, "15 MIN CARD ", CR
· LOOP
· DEBUG CLS, CLS
· LOW· led···································································· ' Turn OFF Relay
· GOTO main
I hope this helps you with what you want to
Sam
Tim