Current Quest - DIY NFC Lock UK

All done and ordered. Made it black

5 Likes

heres a sneak peak of the SoftAP uid manager, i just need to add a little checkbox to the bottom that reverses the mechanism and locking direction ( my frontdoor locks clockwise, and by back door locks anticlock wise,maybe a test check box too, that cycles the motor back and forth…)

2 Likes

from a security/attack surface perspective, this softap is only accessible by holding down the softap button and resetting the lock, it must be connected to, and it takes a password. unless successfully accessed within 60 seconds, it reverts to lock mode and the AP disappears

3 Likes

what a fuss that was… jlcpcb flagged my pcb as multiple designs and wanted to charge me 30 bucks for a 4 buck pcb,(dispite printeing the prototype without issue.) so after a long chat, they didnt like the mouse bites, then they told me the connecting tabs needed to be at least 10mm ( dispite the tab guide being 5mm in the mousebite guide, so i moved things about, droped the parts that are not actually needed,

as you can see the toggle levers are still 5mm, and they didnt flag that this time, i must of just had an arsey auditor working that day. ill just score and snap them my self. so now those are cooking its time to implement the code changes

here is the design just in case you wanna diy it. here is our current todo list, On the softap. test motor and reverse direction check boxes need to be added maybe a password changer, the rc522 compatibility plus reader autodetect. the uart amendments , and replace the a0 toggle values to 0/1 of the relivent gpios. :slightly_smiling_face: happy new year

5 Likes

While breadboarding i have come to learn that gpio 9 is attached to the bootloader. Pulling this low on start up breaks shit. (This is how we activate the softap…)So i swaped pins 9 and 10 and that seemed to work for a while. Then i updated my arduino software/librarys. Now my softap activation seems to cause a looping brown out like symptoms. Donfire seems to thinks" basically they added some checks in a new esp32 update to add support for something (amazon matter compatibility), but the libraries fail that check. " So today ill try a different versions of the esp32 core. In other news saw this great diy lock on facebook. So i thought i would share. - defo gona steal one or 2 of those features
Redirecting...

1 Like

Which esp32 are you using? There are a ton of pins to avoid

1 Like

Esp32 c3 supermini. Ive now adjusted the pin out so it all works tidy on the breadboard. I only swapped 3 pins. (One was just moving the buzzer off the onboard led pin. ) then i just swaped pins 9 and 10 . Which is softap button and stepper dir pin. All works now. Pcb has been amended.

1 Like

Yestiday the pogos arived from china. Apon analysis. It didnt match the jlcpcb foot print ( holes were too close to geather (0.5mm) so i also amended that. And extended the pogo pads so i can solder it on with an iron.

Also added a qr code to the git. Look how well it fits around the vias. Some would say i planned it…

4 Likes

ok hardware is all done now, i think, im sure something will need looking at again when it comes to assembly. now its pure code for the next week , fixed the softap brownout issue, just by down grading to version 3.0.7 of esp32 core. heres the features we plan to add next…

Add compatibility for RC522… and a autodetect, so it knows…
add a ‘‘reverse direction’’ checkbox (doors lock in different directions)
add a '‘Cycle motor’ check box to the softap UI (for testing/installation)
add a password manager so user can change the default password
maybe add a scan tag button in the uid add section.
then spend remaining points on adding bells and whistles to the softap UI.

if you have any suggestions or any skills in code and your saying to yourself, ‘‘that doesnt sound hard’’ please get involved, i have no clue what im doing and even chat gpt is struggling lmao

4 Likes

basecode.txt (13.5 KB)
autodetect.txt (3.9 KB)

2 Likes

Ohh it’s a supermini, I have had wifi issues with one too a while back.

Try this fix and see if if helps?

we havent had any wifi issues yet, but ill hold onto this just in case we do the, my issues is , i want what i cant create lol. but we are getting there… im currently debugging a merged code

1 Like

okdokie, DonFire gave me a code to test the rc522 compatibility and the reader autodetect shinanigins, so i made some necessary rc522 library change, ran code, everything seems to work fine on the pn532, however its not the same for the rc522, i get literally nothing on the serial monitor when the rc522 is plugged in and when no reader is pluged in, no softap, not even line 281 - Serial.print(F(“Start of program”)); so i tested the hardware anyway to make sure i didnt mess anything up, ran an example code that works. Not sure how to fix it.

I had lots of negative experiences with the rc522 and I think I even messaged you the pn532 is a better option

1 Like

I agree… i curently have a rc522 running on the front door and a pn532 on the back door. Hense why i wanted to add both to the code. I must admit that the rc522 mini that im using has a more desired form factor as its the same size as the handle when in its case.

Ive had no trouble with these in the 4 years ive been playing with arduinos. Granted the pn532 can “do” more . And has a better read range. But the rc522 preforms adequately in this use case.

While im here i mite as well drop an update. Currently upgrading to the mrc522v2 library. Apparently it works better with the esp32 or something. None the less i have an example code running on the hardware. We just need to add this to the main code. And fix the auto detect.

Pcbs will be here by the end of the week. They have errors on them so cant be used. However i get to check it the hard ware holes are in the correct place. So its not a total loss. Ill make any amendments and re order them .

My buddy is lathing the couplings some time this week( waiting on a lathe tool from the post man)

2 Likes

Just a thought, did you consider building in a repeater?
Hammys gerber files would likely help you out, as im sure he would also if needed.

You do seem happy with the performance regardless, this is just a late in the game “feature creep”, but since you will be putting in another pcb order…

better said now, than not at all though…

1 Like

For projects like this i would gladly provide anything that may help for the cost of shipping.

4 Likes

Define repeater?

Let me answer in the form of a thread

and web link

2 Likes