Arduino programmable smart Watch

Anything not related to STM32
User avatar
RogerClark
Posts: 6342
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: Arduino programmable smart Watch

Post by RogerClark » Sun Nov 27, 2016 9:34 am

They can be programmed via DFU, but only via a mobile app (either Android or iOS)

AFIK. Nordic have their own custom DFU implementation, which is supported by their App (on both Android and iOS)

However getting the binaries onto the phone and then manually running the App each time and selecting the file to upload etc etc etc, is not a very smooth development process.

I did ask Nordic if there was any publicly available code for another nRF51 to act as DFU master, but there isn't. But I think Nordic sell a product which may do this (for about $100).
Its technically possible to write a nRF51 to nRF51 uploader but it would take a reasonable amount of error e.g to be able to have one nRF51 connected via USB Serial to a PC and get it to send DFU data to another nRF51 via BLE.

BTW. I think there is some sort of Serial bootloader as well, rather than DFU, but that doesnt really help that much as there isnt any nRF51 maser code for that either AFIK

I did look at using a cheap CSR BLE dongle on Windows to connect to the nRF51, but Microsoft doesnt support BLE on Windows 7 (which I'm using), and even when I tried it on Windows 10, I didnt get very far.

So I'm sticking with uploading via direct connection.

BTW. I know one person (Goran) who drilled some holes and used some IC socket pins through the side of a watch so he can program it, while its in its case. But I've still got both of my watches in pieces on the bench, as I'm struggling to find time to look at them.

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

Re: Arduino programmable smart Watch

Post by RogerClark » Wed Dec 07, 2016 7:09 am

Just a quick follow-up from my post about the "A16" nRF52 based smart watch.

http://www.ebay.com/itm/182341391730

Well, its a con !

I received 2 of them today and manage to get one of them apart, despite it being glued together

But I found it does not contain the nRF52 but uses a Dialog processor :cry:

So that was a complete waste of $30, as I bought 2 of them thinking that they would be an excellent platform because they contained the nRF52 which has STM32L4 like performance and low power consumption.

Unfortunately as the package they came in had tracking the vendor knows I received them, and although I have complained that they are not as advertised, I suspect they will try to get me to send them back, which would cost at least half the purchase price, so would definitely not be worth the hassle.

User avatar
neo2121
Posts: 15
Joined: Tue Aug 02, 2016 2:35 pm
Location: Bucharest, Romania
Contact:

Re: Arduino programmable smart Watch

Post by neo2121 » Tue Jan 03, 2017 4:21 pm

I've been playing around with the BLE Nano (same chip as this) from RBL using Roger's new nrf51822 core (tried both repos). Just like the original RBL core I keep getting this error whenever SPI is involved:

Code: Select all

(...)Adafruit_SharpMem_SPI.cpp:92:5: error: expected unqualified-id before '.' token
  SPI.begin();
     ^
Any idea why this is happening? Is SPI implemented somehow differently because of the old mbed stuff? I asked about it on the RBL support forum a year ago and no replies.. You'd think they have something as simple as SPI working before selling these things.

I also want to thank you all for the work you've all been doing. My ID107 HR has been working so well I didn't have the heart to take it to bits till now (even though that's what I bought it for initially), I just wear it everyday as my watch. I'm trying to port my STM32 smartwatch project to it.

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

Re: Arduino programmable smart Watch

Post by RogerClark » Tue Jan 03, 2017 7:36 pm

From what I remember the RBL nRF51 core uses the mbed code for SPI, so that its name is different.
I have a feeling its name has something do with it being the SPI Master, but I cant recall the exact syntax.
I am sure there are examples of SPI using the RBL core somewhere.

User avatar
neo2121
Posts: 15
Joined: Tue Aug 02, 2016 2:35 pm
Location: Bucharest, Romania
Contact:

Re: Arduino programmable smart Watch

Post by neo2121 » Tue Jan 03, 2017 10:53 pm

Well, two hours later and I got it to compile, haven't tested on the board yet, will report back.

It's not just a matter of replacing 'SPI' with 'SPI_Master' in the code (and libraries). There are certain functions that are common to the arduino SPI libraries (and the STM32 one) that aren't in the RBL one. So far I've found these compatibility problems:
- SPIClass::beginTransaction() - doesn't exist at all
- SPIClass::endTransaction() - doesn't exist at all
- the class 'SPISettings' doesn't exist at all, this usually stores SPI settings for use with other functions
- SPIClass::setBitOrder() is named 'SPIClass::setBitORDER()' - wrong case

Maybe someone that knows a bit more than me can have a go at cleaning it up and name it 'SPI' like usual. It doesn't look like it would take long. I could botch it together myself (like I have), but I have below average knowledge about C++ and no idea how SPI works on the low level. It's a real pain to have to change a ton of libraries to get SPI working :(

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

Re: Arduino programmable smart Watch

Post by RogerClark » Wed Jan 04, 2017 12:58 am

It may be worth looking at Sandeep Mistry's new "Arduino nRF5" repo

https://github.com/sandeepmistry/arduino-nRF5

I think his SPI implementation is more standard than the RBL version

User avatar
neo2121
Posts: 15
Joined: Tue Aug 02, 2016 2:35 pm
Location: Bucharest, Romania
Contact:

Re: Arduino programmable smart Watch

Post by neo2121 » Wed Jan 04, 2017 8:07 am

Excellent! This should work fine. Thank you

goran.mahovlic
Posts: 35
Joined: Fri May 26, 2017 9:01 pm

Re: Arduino programmable smart Watch

Post by goran.mahovlic » Fri May 26, 2017 9:15 pm

Hi to all,
Today I have managed to marge latest sandeepmistry with Roger patches, ant test on ID107HR.
It seams that most things are working with S130 v2 softcore.
I have fixed OLED lib and display is working.
I have tested I2C scan with original library and I can find accelerometer.
I did not manage to get response with original KX004 library but it compiles well.
My simple KX004 is not working, so we still need some debugging.
Button is working, but did not get vibrations from watch (it could be broken).
I can push my newest libs to your repo or make just samples repo (but we have so many repos that even me do not know what is ok...)

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

Re: Arduino programmable smart Watch

Post by RogerClark » Fri May 26, 2017 9:25 pm

Thanks goran

I perhaps we should chat in gitter about the best place for your files.

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

Re: Arduino programmable smart Watch

Post by RogerClark » Fri Jun 16, 2017 9:42 am

I received a new watch in the post today.

Its hopefully got the nRF52832 in it, as its an ID107 Plus.

But I won't know for sure until I can get it apart, and it seems to be glued together.

I have ordered some other watches claiming to have nRF52's in them but had a completely different processor (made by Dialog), so fingers crossed these do really contain the nRF52.

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 1 guest