Pages: 1 [2]   Go Down
Author Topic: Proximity help?  (Read 3937 times)
0 Members and 1 Guest are viewing this topic.
Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm wrong. The code works, but how do I simplify it so a noob like me can add some stuff?
Logged

Andrew K.

Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Like how would I make it say something like

if (tagID==tag code here){
  Serial.print("Accepted");
  do something else here;
}
else{
Serial.print("Denied")
}

etc
Logged

Andrew K.

Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh and it's 37 bits.
Logged

Andrew K.

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 212
Posts: 8975
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Oh and it's 37 bits.

The unsigned long is only going to hold the last 32 bits of the 37-bit value. That should probably still be enough to uniquely identify each tag.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Well the if statement I posted above didn't work. How do I find only one tag?
Logged

Andrew K.

Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Sweet! I hooked a relay up to my arduino, and when I scan the card, it clicks on the relay for 2 seconds!
Logged

Andrew K.

Global Moderator
UK
Offline Offline
Brattain Member
*****
Karma: 310
Posts: 26631
I don't think you connected the grounds, Dave.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Oh this is actually cool man..I liked it
Smells...spammy.
Logged

"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Massachusetts, USA
Offline Offline
Tesla Member
***
Karma: 212
Posts: 8975
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Oh this is actually cool man..I liked it
Smells...spammy.

At least it's subtle.  You have to go to the profile to find the link to the website.
Logged

Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

Minnesota!
Offline Offline
Sr. Member
****
Karma: 0
Posts: 388
My nickname on the forum used to be Soapy29.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I'm going to make a video and a website explaining how to make my setup. Might not be till next week, but I do have some Arduino videos on my Youtube channel: http://www.youtube.com/user/AKSoapy29
Logged

Andrew K.

Pages: 1 [2]   Go Up
Jump to: