10/18/2020 at 13:40 •
Today I added a new applet to the NFC chip and thought that it may be nice to cover the software part of the project.
Let's talk about what we need to program the chip. Hardware wise it's simple: a ACR122U - NFC Reader/Writer is the simplest writer to use for this task. It's also fairly inexpensive.
Then there's software. We'll need:
- The ACR122U drivers
- GlobalPlatformPro for loading and managing JavaCard applets on the chip
- The NFC Tools Android app.
Regarding applets I'll cover loading the two I'm using right now:
- The already mentioned Gauss Key Card from darconeous which make the watch act as a Tesla key
- JavaCard NDEF Applet which makes the chip act as an NFC NDEF Tag. I'll use it to store a link to my Hackaday.io projects page.
Applets installation instructions
Step 0: Install ACR122U drivers
Step 1: Install GlobalPlatformPro. You can simply download pre-built binaries form their release page.
Step 2: Install Gauss Key Card applet.
Download the pre-built .cap files from the Gauss Key Card project page and load the file onto the chip using GlobalPlatformPro
java -jar gp.jar -install GaussKeyCard.cap
Step 3: Install JavaCard NDEF full applet
Clone the project repository which contains also the pre-built .cap files.
git clone https://github.com/OpenJavaCard/openjavacard-ndef.git
Once cloned load the full variant of the applet which will let you write the content once. Note: the command to upload the applet differs slightly from the official documentation because of a recent change in the behaviour of GlobalPlatformPro create/applet command.
java -jar gp.jar \ -create D2760000850101 \ -params 810200F182020800 \ -install build/javacard/javacard-ndef-full.cap -default
Step 4: Write the NDEF applet content using NFC tools
Step 5: Pair your watch to your Tesla following the official instructions.
Overall the process is fairly simple and throughly documented. The two applets I mentioned are just a few exemples of what the JavaCard standard can offer. Here's a curated list of interesting JavaCard applications that can be loaded on the Tesla Key Watch.
10/03/2020 at 19:32 •
Today I was finally able to complete the first prototype for my frontplate antenna.
A few days ago I bought these engraving bits for my CNC and put them in good use for the frontplate design:
I wasn't expecting much, not having every tried to engrave acrylic with these kind of bits, but I was pleasantly surprised by the results
We could argue that the "T" didn't came out so great but I'll keep it as is.
Time for the final assembly...
I used some 2mm thick double sided tape to glue the frontplate and the connection seems to be good enough. A big plus for me is the fact that the tape is completely invisible from the outside.
And now some final shots.
All in all I'm super happy with the results:
- The connection with the car is great. Much better than the previous version.
- I was able to get back the buzzer without sacrificing the key car functionality.
- The watch is really cool to look at. Much better than I would have hoped for.
- Being the antenna in the front and not needing the additional space on the back, the watch is much more comfortable to wear.
The only downside for now is the fact that the watch is not water proof anymore. Nothing some glue can't fix though... But it's for a later version.
Some more improvements that came to mind:
- The chip I used is not in good shape regarding aesthetics. I'm planning to buy some new cards for better-looking chips.
- The frontplate was kinda rushed, I need to take the time and cut a new one on the CNC for a better look.
- Darconeous added some more functionalities (NDEF Business Card, use with Yubico Authenticator for generating OATH codes...) to its ring and I would like to do the same with my watch.
Overall I had a lot of fun with this project, I hope I'll find the time to keep improving it.
09/27/2020 at 11:14 •
Today I designed the new frontplate, taking into account the new bit I bought which is 2 mm in diameter.
I also realized that I have a few engraving bits laying around that I could use for making this frontplate sexier. Here's the idea:
Am I getting overly ambitious? Yes. Will I try this anyway? Hell yes.
Whish me luck!
09/26/2020 at 17:09 •
I was finally able to get my hands on some 2mm thick acrylic and test the production process of the antenna I thought.
Let's start with the 2mm thick acrylic frontplate.
This looks AWESOME! (Since I was at it I alsso modded the screen for a darker look).
The matte look left from the CNC machining is really cool and I love it. I'm trying to leave it as is.
Regarding the production process I designed and 3d printed a guide that can be broken up into parts after winding up the antenna.
This way I was able to buld the antenna on the guide in a much more comfortable way and, once finished tuning the resonant frequency, I was able to break the guide into parts and tranfer the antenna on the frontplate without damaging it.
I then wanted to try fixing everything up using some UV curable resin. That was a bad idea...
I lost the matte look on the top half of the frontplate and it now looks like its foggy. Furthermore some resin creeped on the screen ruining its transparency.
Finally I decided to stop using the resin altoghether and keeping things simple: I will now design the new frontplate without the hole for the chip. It will be just a recess in the acrylic. This way, if things go wrong, I will be able to rescue the chip.
Last thing to do is decide how to mount the frontplate to the Casio chassis. I have two options:
- 2mm thick double sided tape (already bought for this purpose).
- T-7000 glue
The second seems more fit for the purpose at this point. I'll have to try thing out.
09/13/2020 at 13:35 •
The UV curable resin front glass was a dead end...
After trying to obtain a glass-like effect multiple times and failing I abandoned this path. I couldn't get a totally clear look, no matter how I hard I tried. Here's the best looking one so far:
Then it hit me... the original front plate is made of acrylic. If only I had access to something that can cut acrylic...
Oh wait, I do! My dear Shapeoko!
It took me an embarassingly long time to figure out I could CNC this part out of acrylic. To try things out I cut it out of a 3 mm thick sheet I had lying around and the result is amazing!
It looks AMAZING! Apart from the awkward thickness. Keep in mind that in the pic above it wasn't seated properly so it look thicker than in reality.
I plan to use a 2 mm thick acrylic sheet for this which shouldn't get so obnoxious. We'll see...
Now I need to try and build the antenna out of this and see what it looks like. Depending on that I'll figure out if it'll need some paint. I already experimented a bit with nail polish and resin to see if there's any bad reaction with the acrylic and things should be good.
Final note: Here's what happens if you forget to use the proper mill for acrylic...
09/08/2020 at 17:02 •
While I was waiting for the necessary instruments for the front plate (2mm thick double sided tape and UV torch light) I ordered a resin printed backplate thinking it would solve the little scratching feeling from the FDM printed one (I know I could have gone with the sending route but hey, I wanted to try a resin printer for once :D).
Not having a resin SLA printer I used an online service to print it. Albeit not being 100% satisfied by the looks, the print actually delivers on the smooth factor. No more scratchy feeling and super comfortable to wear.
I think that this idea cannot go further then this so I'll focus on the frontplate antenna for now. Speaking of which...
I was able to build a working antenna using 0.1 mm thick enameled wire... and it was actually easier than using the 0.25 mm thick one! Unfortunately I'm having trouble in building the glass for the screen using the UV curable resin due to the high temperatures it reaches while curing under the sun. To this end I bought a UV torch light from Amazon hoping it will solve the issue...
09/04/2020 at 20:15 •
I was able to go through a first prototype of the new version and I'm pretty happy with the results.
Aesthetically I love it (still need to dial in the resin curing process), I've lost the stealth factor but this thing is super cool to look at. Even more so when the real chip will be in place. Unfortunately the thing is really hard to build too: I was able to cram this amount of copper wire before running out of vertical space and unfortunately this wasn't enough to get reasonably close to 13.56MHz. Furthermore getting the wire in place required an unreasonable amount of nail polish.
I'll try to find some more space by thinning the faceplate (I don't want to get too high since it's already 1mm thicker than the original one) and I still have my secret weapon:
0.1 mm thick enameled wire.
It'll drive me crazy but could be a solution.
09/02/2020 at 17:37 •
So... I got an idea for improving the watch mod.
The original idea by N-O-D-E was to put the antenna behind the frontplate using a PCB antenna, which is great but leave me no room for resonant frequency tuning. What if I can tune the antenna anyway?
The idea is the following: what if we can build an antenna using the above part as a guide and as the front plate? Showing off the back of the chip (which is awesome) and leaving all the room needed for the tuning?
But Mattia, you say, how do you protect the watch now that we have a big gaping hole in front of the screen?
UV curable resin.
This will cure perfectly clear and fill all the needed gaps, with the added benefit of making the frontplate and the antenna a whole thing.
But Mattia, you say, how do you glue this new frontplate to the watch?
2mm wide double-sided tape usually used in smartphone repair (again thanks to N-O-D-E for the idea).
This new design should solve almost all the shortcomings of the old version:
- Buzzer gets back in place
- No scratches from the 3d print
- Improved range because the antenna is not behind all that metal
Let's see if it can actually be done...
08/30/2020 at 13:34 •
The first step in building the antenna is to wrap the wire around the guide. I used 0.25 mm thick enameled wire for this and then glued it together with some nail polish.
The nail polish will stick together the wires and make it possible to later remove (with some caution) the antenna from the 3D printed part. You need to be sure to add enough loop of wires for the resonant frequency to be way lower than 13.56 MHz. How do you know when to stop you ask? Experience.I got the hang of it after a few tries. Always add a few loops more than what you think you'll need.
After the nail polish was dry, I scraped off the first layer of enamel from the antenna ends and soldered the chip on.
After checking that the resonant frequency was low enough (9 MHz for me at this point) I moved the antenna to the modified F-91W backplate for the fine tuning.
And now for the hard part: fine tuning the resonant frequency. The PCB and the thin metal casing inside the F-91W will modify the resonant frequency of the antenna A LOT! I then needed to test the resonant frequency while the chassis was mounted on the watch.
Fun fact: even the screws of the watch modify the resonant frequency! I learned it the hard way.
The fine tuning goes like this:
- Start by a lower frequency than the target one (13.56 MHz)
- Remove a loop
- Is it lower? Go to step 2. Is it higher? Go to step 4.
- If necessary add some copper tape directly to the antenna to lower the resonant frequency a little.
Here's the final results for my watch
Apparently a higher (13.7MHz) than normal resonant frequency is what the Tesla Model 3 likes the most.
08/30/2020 at 13:12 •
First thing I designed was the new F-91W chassis
Obviously it took me a few tries to make the new chassis fit properly.
Well... maybe more than "a few".
This process was made way easier thanks to N-O-D-E sharing his project files.
Then, to make my life easier, I started printing a few instruments for building the antenna. The first thing I designed was a guide for the wire to be wrapped around.
Then I needed a loop antenna for my NanoVNA for the antenna matching stage.