Help with coding a rfid

So I’d like to code a rfid but not in the conventional way I’ve seen in most cases.
So what id like to code is basically a system that Would sound an alarm when the tag is removed from the reader.
I’m not sure how to go about this I’ve had a go fiddling with a few different codes but can’t seem to get anywhere If anyone would mind helping I’d appreciate it a lot

As Your code looks like being a secret, not posted, it's impossible to assist You.
Number one is to make sure that there is a reliable detection of the rfid. Does that work?

Railroader:
As Your code looks like being a secret, not posted, it's impossible to assist You.
Number one is to make sure that there is a reliable detection of the rfid. Does that work?

I currently don’t have any working code I’m look at existing code and the rfid reader arduino code and I’m trying to figure it out

The current crop of inexpensive RFID readers only tell you when a new tag is read. I am unaware of any method to detect that the tag has been removed.

Is the existing code also secret as You don't post it? Do You think we all use crystal balls?
Should I use my Tarot cards?

Following this guys tutorial and I was going to try and edit that code to suit but I can’t get the original to work after doing all his steps I keep getting the error expected ‘;’ before ‘{‘ token
I’ve followed the method perfectly and I’ve been over it several times now

SteveMann:
The current crop of inexpensive RFID readers only tell you when a new tag is read. I am unaware of any method to detect that the tag has been removed.

I thought if I had it reading it on a loop it would essentially work the same way?

This is my code so far but like I said it won't work even though there doesn't seem to be anything wrong with it, I'm probably missing something simple though.

rfid_default_keys.ino (6.09 KB)

Please post code the way told in topics like "How to use the Forum", using code tags. My tablet has no IDE so downloading is impossible.
The compiler error You tell about is due to a missing character, or one too much character, somewhere.
No code generating compiler error can be considered "not working" as there is no download done.

You can refer to this tutorial" RFID/NFC triggers relay. You can change the relay code by buzzer code.

IoT_hobbyist:
You can refer to this tutorial" RFID/NFC triggers relay. You can change the relay code by buzzer code.

That’s a good suggestion, I’ve been looking into it and the relay I have is the right one but without the board I’ve tried using a transistor and a diode to replicate it but it’s not working so I’ve ordered one with a board hopefully I get somewhere with this.
Any idea if the relay will alllow a buzzer to stay on constantly after it’s detected then off when it doesn’t?

Post a wiring for the relay setup.

Here’s a link to a video of my relay and circuit the relay is clicking but the led or anything I add isn’t lighting up Ann’s here’s the relay circuit I’m using

That last pic didn’t load in so here’s a link
https://i.ytimg.com/vi/EnhSJ-Nq14Q/hqdefault.jp

I’ve figured it out I needed extra power going through the high voltage part of the circuit, I’ve added a buzzer and it’s pretty much working as it should but after a few seconds of the fob being present the buzzer sounds again and it has to be taken away and put on it again to activate it, had anyone got any idea how I could code the reader to keep researching for a fob and only sound the buzzer if one isn’t found

Here’s my latest circuit working
As you can see it doesn’t stay off when the fob is still present

That link does not download here.
Please note reply #8 and #11.

surely you can open a web link on your tablet
it's not a download just a link to a video also the code I'm using is just the code in the link that was on post #9

i believe this guy had a similar issue to mine

If it helps You. I will not spend time on it.