Arduino programmable smart Watch

Anything not related to STM32
racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Fri Oct 14, 2016 8:08 am

RogerClark wrote:
racemaniac wrote:My first watch arrived, i think it's got really tiny torx screws >_<.
i've got small heads, but not that small, so the next mission is to find a screwdriver for it >_<.
I hope it won't cost more than the watch :p
I bought this from a local supplier.

http://www.ebay.com/itm/25in1-Precision ... SwX~dWtHcg
My local supplier has an electronics screwdriver set that goes down to T4 torx screws (and tons of other heads) for about 25€, i'll go have a look if its small enough to fit on the watch, if not i'll have to wait for the set i ordered from aliexpress for 3€ XD

And one of my ID100's arrived, but i think it's broken >_<. The watch only responds to the button when it's connected to the charger (and it then shows the battery is full), and once i disconnect it from the charger, the button does nothing >_<. And i've tried to make bluetooth connection with the watch, but that also fails, i can't even see it in the available devices on my phone...

User avatar
RogerClark
Posts: 7137
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Arduino programmable smart Watch

Post by RogerClark » Fri Oct 14, 2016 10:07 am

racemaniac wrote: And one of my ID100's arrived, but i think it's broken >_<. The watch only responds to the button when it's connected to the charger (and it then shows the battery is full), and once i disconnect it from the charger, the button does nothing >_<. And i've tried to make bluetooth connection with the watch, but that also fails, i can't even see it in the available devices on my phone...
Umm

All the watches I have received were flat when they arrived but after a short charge, they did hold their charge and I ran one for at least 24 hours on the battery even though the watch was taking about 1mA all the time because I've not figured out how to put the OLED into its absolute lowest power setting (apart from to completely reset it)

When you say you can't see it from your phone... Do you have Android or iOS ? These devices do not appear like a Bluetooth speaker etc, they are BLE.

If you have an iOS device download "LightBlue explorer" https://itunes.apple.com/us/app/lightbl ... 28110?mt=8

On Android, I'm not sure what would detect BLE, possibly https://play.google.com/store/apps/deta ... rks.locate This works for iBeacons, and may detect the watch as an iBeacon

i.e its possible that the problem is just a loose connection to the battery inside the device (well a wire would have to not be soldered)

Re: Torx

I managed to get a set on eBay from a local supplier which wasnt at all expensive and arrived in a few days, its a shame you can't get one from a local eBay supplier.
Alternatively, look on AliExpress and find a cheap set, where the supplier will send by e-Packet for a small additional charge e.g. a few dollars.

I find e-Packet's arrive in about 1 week from China to Australia, but I don't know if the same applies to all countries

racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Fri Oct 14, 2016 10:25 am

RogerClark wrote:
racemaniac wrote: And one of my ID100's arrived, but i think it's broken >_<. The watch only responds to the button when it's connected to the charger (and it then shows the battery is full), and once i disconnect it from the charger, the button does nothing >_<. And i've tried to make bluetooth connection with the watch, but that also fails, i can't even see it in the available devices on my phone...
Umm

All the watches I have received were flat when they arrived but after a short charge, they did hold their charge and I ran one for at least 24 hours on the battery even though the watch was taking about 1mA all the time because I've not figured out how to put the OLED into its absolute lowest power setting (apart from to completely reset it)

When you say you can't see it from your phone... Do you have Android or iOS ? These devices do not appear like a Bluetooth speaker etc, they are BLE.

If you have an iOS device download "LightBlue explorer" https://itunes.apple.com/us/app/lightbl ... 28110?mt=8

On Android, I'm not sure what would detect BLE, possibly https://play.google.com/store/apps/deta ... rks.locate This works for iBeacons, and may detect the watch as an iBeacon

i.e its possible that the problem is just a loose connection to the battery inside the device (well a wire would have to not be soldered)

Re: Torx

I managed to get a set on eBay from a local supplier which wasnt at all expensive and arrived in a few days, its a shame you can't get one from a local eBay supplier.
Alternatively, look on AliExpress and find a cheap set, where the supplier will send by e-Packet for a small additional charge e.g. a few dollars.

I find e-Packet's arrive in about 1 week from China to Australia, but I don't know if the same applies to all countries
thanks for the hint on finding ble devices :).
I've got a xiaomi miband 2 that i have working with my phone, don't remember exactly how i had it connected, it was also a struggle, but in the end it worked, with the ID100, i haven't gotten anywhere yet >_<.
And i've let the ID100 in its charger overnight, and it's still doing completely nothing at all when i disconnect it. It does however remember the time, so there must be some battery in there that's still keeping the time. but pusshing the button or moving it around doesn't do anything >_<.
And i haven't tried syncing the ID107's with my phone yet, but when pressing their button they nicely show their display, and they're nicely holding their charge, so i'm not worried about them. The ID100 is behaving strangely, unless first connecting to it once magically solves all issues, i'm starting to think it's a dud ....

User avatar
RogerClark
Posts: 7137
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Arduino programmable smart Watch

Post by RogerClark » Fri Oct 14, 2016 10:38 am

Its really hard to tell if its a dud - quite possibly.

I think the ID107 was compatible with the manufacturer's app called VeriFit (https://play.google.com/store/apps/deta ... yfit.multi )
I think its written on the box, but each watch seems to be different.

I think the app asks for some permissions that I wasnt that happy about, e.g. access to contacts, but I'm running a jail-broken android phone running a non-standard ROM, and I'm using the XPosed framework, so I can block individual apps doing things like accessing contacts etc, so it wasnt a big issue for me.

What phone do you have? Minimum iOS phone is the 4S when apple added BLE. I can't recall when it was added to Android, definitely a few years ago as my Android phone is at least 2 year old and was a fairly base model when I bought it

racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Fri Oct 14, 2016 11:15 am

RogerClark wrote:Its really hard to tell if its a dud - quite possibly.

I think the ID107 was compatible with the manufacturer's app called VeriFit (https://play.google.com/store/apps/deta ... yfit.multi )
I think its written on the box, but each watch seems to be different.

I think the app asks for some permissions that I wasnt that happy about, e.g. access to contacts, but I'm running a jail-broken android phone running a non-standard ROM, and I'm using the XPosed framework, so I can block individual apps doing things like accessing contacts etc, so it wasnt a big issue for me.

What phone do you have? Minimum iOS phone is the 4S when apple added BLE. I can't recall when it was added to Android, definitely a few years ago as my Android phone is at least 2 year old and was a fairly base model when I bought it
i've got a motorola moto E 2nd generation. it has got BLE, and android 6, so it should be able to connect :)
i'll do some more testing tonight :)

And concerning the screwdrivers, sometimes i love my luck. Passed by a Lidl store at noon, and they happen to sell a similar screwdriver kit i wanted to buy from my local electronics retailer, but for just 7€ XD. and it also goes down to a T4 torx bit, so lets see if it works or not :)
ofcourse i ended up spending 25€ anyway, because they had some other things i could use too XD.

racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Fri Oct 14, 2016 3:27 pm

Aha, finally figured out how that ID100 works. Unlike all the others i received so far, you have to turn it on at first by pressing its button for 5 seconds. And now it seems to be responding as expected :D.
Okay, have 3 smartwatches to play with now, let the weekend begin XD.

btw, has anyone tried other smartwatches with the nrf51822 yet? I believe this one also is nrf51822 based i think, and it's cheap, has a big screen, and that nice usb plug coming out of it (even though it probably only is for power). Maybe also an interesting candidate to hack?

User avatar
RogerClark
Posts: 7137
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Arduino programmable smart Watch

Post by RogerClark » Fri Oct 14, 2016 8:18 pm

There are about 10 watches that I am aware of, which use the nRF51, but unless it says nRF51 on the listing its virtually impossible to know if thats whats in a watch.

They seem to mainly come from one manufacturer in China, but the same manufacturer used to make the same watches with other MCUs. Which makes things even more complicated.

I have 4 watches, but I found only 2 have nRF51's in them.

With the watch you linked to, I recall reading about it, and the USB connector was only for charging, which is a shame, as it may be possible to run VUSB on the nRF51 ( though I dont think anyone has actually done it)

I was thinking about buying one like that which has a landscape orientation screen, as the screen is physically bigger ( wider ) so I think it has double the number of pixels of the others.

But I dont think I will risk ordering from that page, I will find one ( albeit a few dollars more expensive) which lists the watch as containing the nRF51

racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Sun Oct 30, 2016 2:53 pm

RogerClark wrote:BTW.
Before you reflash it, there may be a way to read the existing firmware even if its locked.

Its an open secret, that I only found out a few days ago, that the "Protect All" system for read protecting the Flash and RAM has a simple exploit, which allows the Flash or RAM to be read out.

So.. Before you erase, it may be worth attempting to back up firmware.
BTW. I had already erased by watch ages ago, but managed to backup an IBeacon as a proof concept, but I know other people have issues backing up. So it looks like the loophole may not be foolproof.

Although this exploit is an open secret, as it has been even mentioned on the Nordic developer forum, I generally refrain from posting the exact details, so PM me if you want more information.
I used what you sent me, and i think it worked, i attached the result to this post :) (dump of an ID107).
It's a nice file of 256Kb (after a few attempts it finally just finished without getting into an error state).
I'm now going to start reprogramming this watch, if that dump isn't correct, i've got another ID107 lying here on which i can try it again :).
Attachments
ID107FW.zip
Extracted firmware
(149.34 KiB) Downloaded 22 times

racemaniac
Posts: 554
Joined: Sat Nov 07, 2015 9:09 am

Re: Arduino programmable smart Watch

Post by racemaniac » Sun Oct 30, 2016 7:08 pm

I've been trying to program my watch (an ID107) today.
But i haven't seen much result yet. I've been able to flash the S130 core from nordic via gdb and black magic probe, so that should be okay.
When powering the watch, i see a dfu device get enumerated over bluetooth, so at least something is running on there XD

But then uploading the smartwatch samples from your repo, doesn't do anything.
I also did a simple test in setting all ports to output & high or low, hoping to at least trigger the vibration motor of the watch, but that didn't do anything either -_-.
Now it's enough for today :). Any tips on where to continue from here roger?
First useful thing might be to see if the serial works, and if i get any info from there. But i'm not sure how to hook it up when using the black magic probe. I've got rx & tx pads on the smartwatch, where do i connect them to, in order to be able to see the serial communication coming from the smartwatch.

Another confusing thing is that you've got 2 nrf51822 arduino repos. I'm using the latest one : https://github.com/rogerclarkmelbourne/Arduino_nrf51822
(btw, it has a bug that the path to the linker files is wrong if you choose generic nrf51822 board. it still uses the path as it is with the original files by RBL)
I hope that's the right one?
this is the other one: https://github.com/rogerclarkmelbourne/nRF51822-Arduino

User avatar
RogerClark
Posts: 7137
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Arduino programmable smart Watch

Post by RogerClark » Sun Oct 30, 2016 8:39 pm

In terms using the smartwatch, the examples only worl with the first repo you linked to.

This is because those examples contain some function from mbed, and the old repo is a modified version of RedBearLabs repo, which its self is derived from mbed.

The second link is my fork of Sandeep Mistry's Arduino-nRF5 repo, which is a newer and better implemtation of an Arduino core for nRF51xxx and nRF52xxx devices, however at the moment, no one has had time to port the OLED display code etc to the new repo.

With the Blackmagic probe, the DFU device is to update the BMPs own internal firmware, its not used to upload to the target device.
You need to select the GDB com port, as the Com port in the IDE, otherwise it wont upload.

I normally open a separate terminal program to the other BMP com port, if I am using it for USB to serial ( or if I am using a separate USB to serial adaptor to view debug messages)

Also you need to pick the Smartwatch board, otherwise Serial will be on the wrong pins of the watch

Post Reply