MENTOL-STM32 based SmartWatch

FurkanCetin
Sat Sep 19, 2015 11:27 pm
Image

Introduction

Edit: The project has been named as MENTOL

I have been dreaming a smart watch project. I decided to start prototyping and actually this is my first project with STM32. I liked STM32F103 boards very much! It’s just enough with 72mHz crystal, 3.3V voltage, 128kb flash, lots of IO pins, RTC capability, low power consumption, low amount of peripheral components, ready libraries …

I already have 3 kinds of STM32F103 development boards. I have built a prototyping system and started programming. My plan is to share everything with the community to get benefit and to encourage others to build one. I am going to publish all of the photos, videos and other files day by day. You can follow more photos and videos on my webpage (In Turkish for now). Below the page are some details:

Image

Display Screen
I have considered 2.2 inch LCD with ILI9340 driver(since a library is ready) but it is really big for a watch.
LCD screens with ST7735 driver comes in two dimensions; 1.8 inch and 1.44 inch with resolution of 128×160 and 128×128 respectively. I prefered to use 1.44′ (the red pill, you know) which will lead me for a more compact design but a better looking watch at the end.

I have managed to run it (Yes, took days) by searching, combining and merging codes from already built libraries (community owes to Adafruit and Henning Karlsen for lcd stuff they generously published). I have learnt many things about SPI and It is very fast refreshing with DMA support! Right now, I have a carefully written clear sketch without library system (since I have one lcd, no Class and Object system is needed). By other words, all functions are embeded in .ino file. It’s great to have a long code when you know what is where and how it handles the job behind the scene!

I don’t have a touchscreen for now. I am planning to use 3 buttons as common for the first product.

Other Details

– Backlight of the LCD will be set by PWM. Needs some components on PCB. Currently using IRF540N which will be changed in future with a power saver transistor.

CC2541 BLE module will be used on the watch. It is very compact module with many advantages. Smartphone software development will be focused later on.

– An RGB Led will be used just behind the LCD! It shines great! Its a power saver way of giving alerts and feedbacks to user instead of turning the lcd on while it looks very futuristic. I loved it! I’m planning to use the one Lillypad set has instead of something like WS2812.

– SMD package of a LDR (probably TEMT6000) will be used to sense the light intensity behing the lcd. Yeah, it works great for adjusting the backlight of the watch according to environment before it’s turned on. I saw the method on Pebble watch, it works!

– 250mAh LiPo battery just fits on the half of the lcd panel. The rest of the panel will be used for PCB. The PCB is going to have components on its both sides. However, lipo charging chips are not going to be inside the watch due to the small area. Instead, I will design a charging dock station and 2 pins of battery will be used to charge it. (more details will come!)

– Very small battery is required ,I think, for RTC. Or I will connect it to LiPo which will be enough for keeping the RTC alive even it has very low voltage (Am I wrong with that?)

– An IMU module will be integrated inside either a good one like MPU6050 or a simpler one like ADXL335(it would be great to use Tap Tap gesture!)

– Heart Rate sensor, Hand gesture sensor (like APDS-9960), Vibrating motor, Mini Buzzer, Lipo Level measuring chip, Amper sensor, temperature sensor and more can be considered to include in the project!

Guys, I am so curious about what you think about this thing I am building. I have analysed many DIY smart watches however I can’t fully estimate how many feature I can add on it. Even without any smartness, I can use it just as a watch at the end! I just want to build… 8-)


ahull
Sun Sep 20, 2015 12:06 am
For what its worth, here are my thoughts on the RTC. The RTC can be powered from the same battery as the watch, however if the main watch battery is disconnected, you will loose the time and date. If this is a problem, you may need a small secondary battery, however I suspect this is not necessary as you can, if necessary set the date every time you connect to the computer. Furthermore the RTC as far as I recall, will operate down to a much lower minimum voltage than the ARM core, so you will tend to put the device back on charge before the RTC voltage drops too low to retain the time and date.

FurkanCetin
Sun Sep 20, 2015 4:27 am
Thanks ahull for your toughts, it worths lot for me. I think there is no need for a coin cell in such compact design.
Lipo also won’t be replaceable.

zoomx
Mon Sep 21, 2015 12:47 pm
I don’t like smart watch but building one is great!

I will follow you, google translator is great.

I have the same board, some LCDs and one OLED unfortunately only one color.


FurkanCetin
Tue Sep 22, 2015 3:44 am
Grazie zoomx, Non posso scrivo tutti in Italiano ;)

I will prepare a better page in English with more project details. Whoow, I prepared GitHub repository and uploaded almost everything including PCB Designs, 3D Models of parts, Rendered images and the whole code!

https://github.com/CetinFurkan

Check it when you have a time!
Thanks for all followers!

Image


zoomx
Tue Sep 22, 2015 6:29 am
FurkanCetin wrote:Grazie zoomx, Non posso scrivo tutti in Italiano ;)

FurkanCetin
Tue Sep 22, 2015 7:17 am
Previously I have considered to use 1.8′ ST7735 (a little bigger than 1.44′) and also ILI9341 with 2.2′ screen size. ILI9341 has 320×240 resolution in 2.2′ screen which makes it one of the most dense tft screen that is used commonly with Arduino. (some ILI9341 has also bigger screens sizes but they are obviously not suitable for a smart watch)

You can check my code, change Parameters.h file and initialization code. The rest of the code is almost same.


madias
Tue Sep 22, 2015 7:43 am
Nice project! Well done!
About TFT: Dont forget the ILI9163C (128×160) which is well supported in STM32duino (SPI with DMA transfer). A really beautiful fast and small display!

FurkanCetin
Tue Sep 22, 2015 8:39 am
Nice project! Well done!
Thanks madias!

I have found 2 different type of ST7735 LCD Panels; 1.44′ with 128×128 px resolution and a larger one with 1.8′ 128×160 px resolution.
As madias mentioned, there are ILI9163C LCD Panels with exactly same specifications of those two.

However, I noticed there are ILI9163C Lcd panels with TOUCHSCREEN. I must order some right now! :twisted:

http://www.alibaba.com/product-detail/F … 88267.html
http://www.alibaba.com/product-detail/m … 81322.html
http://www.alibaba.com/product-detail/I … 91523.html


madias
Tue Sep 22, 2015 8:58 am
Most of the ILI9341 with touch use the XPT2046 controller (just a small smd chip on the panel).
I use the standard STM32_adafruit ILI9341 library and the Utouch library, see my post (second or third) : http://www.stm32duino.com/viewtopic.php … ilit=touch

FurkanCetin
Tue Sep 22, 2015 2:23 pm
Thanks madias! I will consider it when my touch screens arrive. I still plan to use a touchscreen after first production of the prototype with three buttons.

I updated my personal webpage and created a page for my project. Here is the link for English version:
http://www.furkancetin.com/mentol-smart-watch.html

By the way, this is my design for now:
Image


mrburnette
Tue Sep 22, 2015 8:48 pm
Very impressive!

Ray


martinayotte
Tue Sep 22, 2015 9:19 pm
Yes ! Congrat !

What kind of CAD software are you using ?


FurkanCetin
Wed Sep 23, 2015 2:26 am
I am good at Solidworks and Unigraphics NX (Since I am mechanical eng. major).

However I like low poly modelling with Model Creator software made for Game Maker. I used to do modelling and create 3D games.


martinayotte
Wed Sep 23, 2015 2:42 am
Thanks !
I will take a look when I get chance.

strawberrymaker
Wed Sep 23, 2015 6:03 pm
Oh man, basically what im tinkering on for months ^^

Just a thought on the Display: im trying to use the 1.5″ oled with ssd1351 Driver (http://www.adafruit.com/product/1431) and it seems to be pretty good :)

~Straw


FurkanCetin
Wed Sep 23, 2015 6:41 pm
Hi Straw,

I have considered that little thing but I have realized that;
…small boost converter (required for providing 12V to the OLED)

:shock: I thought using this OLED could be
– more power consuming (because of this boost up converter to 12V but I may be wrong)
– more expensive (like 13$ vs 3$)
– requiring some components which would take some area on my small PCB (ST7735 needs none!)

I will be glad if you make a similar prototype platform of mine and contribute to code with changes for SSD1351.
My code is so far very easy to understand and upgrade. I am sure you can handle.

Also this e-ink screen is suitable for future:
http://www.adafruit.com/products/1393

Furkan


strawberrymaker
Wed Sep 23, 2015 7:16 pm
Yeah that power thing isnt really that great, but i really like the contrast on it (because its black? :D) Also its bit smaller.

In terms of e-ink, i would really love to see something similar used in the pebble time (which is also rokin’ an stm32f4 inside) but that will take some time i guess, as colors are bit better that monochrome IMO.

~Straw


madias
Wed Sep 23, 2015 7:16 pm
I own two of the TI-Launchpad Sharp Display “Booster Packs” (got them for half price, in times, where TI-direct doesn’t wanted $$$-money for shipping)
These are really interesting displays (super wide viewing angle) with extrem low power consumption. They are available for 19.99USD (I don’t know the actual shipping costs!) —> https://store.ti.com/430boost-sharp96.aspx and http://www.ti.com/tool/430boost-sharp96

FurkanCetin
Thu Sep 24, 2015 7:53 am
Thanks guys,

I think, I should continue with 1.4′ ST7735 display for now and focus on the general design. It is very easy to move to another screen later.
Second prototype probably will include ILI9341 with touchscreen. However anyone can work with alternative screens with my code.

Until now, coding is going very neat and fast. I recommend you to check the current firmware on GitHub.
I am very satisfied with the speed of STM32, refreshing screen at monster speed!

Test results and screen videos will come soon!
Furkan


strawberrymaker
Thu Sep 24, 2015 1:54 pm
Just a quick question. Is there any difference in terms of circuitry between the st7735 and the ili9163? Or is there any difference in the two controllers you know or is it just because you already know it?

~Straw


FurkanCetin
Thu Sep 24, 2015 4:56 pm
Just double checked it, there is no difference on circuitry between the ST7735 and the ILI9163. The flex cables of both LCD includes pads to be directly connected to microcontroller. You had better to add two capacitor (100n of 1uF is ok), one is between LED+ and LED-, and another between Gnd and VCC. If you want to control backlight brightness of LCD’s led, you need a transistor (I have chosen the IRF540N)

I have listed all of the possibilities of LCD modules that I can use. I have found ST7735 is so commonly used, easy to find, cheap and library ready. ILI9163 has almost same but it has a little bigger white frame around it!


FurkanCetin
Sat Sep 26, 2015 12:19 am
Hi followers

I have just finished performance test video. You can check it on my webpage: http://www.furkancetin.com/mentol-smart-watch.html

Thanks
Furkan


strawberrymaker
Sun Sep 27, 2015 9:25 am
That looks great :)

Btw, are you using Adafruit_GFX or Adafruit_GFX_AS?

~Straw


FurkanCetin
Sun Sep 27, 2015 10:37 am
None! :) They are very similar but Adafruit_GFX_AS is STM32 compatible, I think.

I have picked functions and embedded in my code for efficiency and being neat. I don’t take any piece of code without understanding how it works. Some of functions I picked are below:

– drawBitmap() from UTFT (the website has a utility to convert images into arrays and this function is very efficient!)
– drawLine() from Adafruit_GFX (neat and very generalized)
– colorWheel() from Adafruit_NeoPixel (good when blending colors from one to another)
– drawText() from UTFT (again the website has many fonts and a font maker utility!)

Moreover, I have implemented a bunch of lines for detecting Button states, Animated Particles, drawing Numbers by using lines (instead of a font), moving menus…


FurkanCetin
Mon Sep 28, 2015 10:52 am
Hi guys,

Here is a new video of the final version of the software. I decided to go only with the SPACE Theme. It has now futuristic menus and bars.
I promise you a better looking GUI with animations when compared to other “Arduino with LCD” stuffs :ugeek:

You can see the video on the project’s page: http://www.furkancetin.com/mentol-smart-watch.html

Furkan


ahull
Mon Sep 28, 2015 3:46 pm
Very nice. I like the smooth animations. :D

RogerClark
Mon Sep 28, 2015 6:36 pm
very nice work

madias
Tue Sep 29, 2015 7:54 pm
Furakan, after being a member of this project (with more or less good inputs :) ) for nearly a year, I’m a little bit proud that people use this platform and are doing really cool stuff with it! So with other words: Cool project!

FurkanCetin
Tue Sep 29, 2015 8:46 pm
Thanks a lot. ;)

I was an Arduino-ist for many years. I have been looking for moving with smooth transition to a higher clocked and richer controller platform where I still would create projects in a fast and neat way.

I have some other projects to do later. But need to finish that guy first. It’s going fast, neat and great as planned!

I have seen some Arduino, PIC and Teensy based DIY smartwatch projects (Pebble uses STM32 but not considering him as DIY) Mine must be one of rare STM32 based watches.

Follow me for more ;)


Vassilis
Tue Sep 29, 2015 9:33 pm
Nice work Furkan!
Maybe an alternative solution is to use some OLED based LCD like this one.

The oled lcds have many advantages
– low power consumption
– more vivid colours
– the screen content is visible in daylight
and more

One disadvantage: higher price than the conventional TFT lcds we usually use.


zmemw16
Tue Sep 29, 2015 11:25 pm
http://www.ebay.com/itm/Serial-SPI-1-5- … 43caf93297

+$2.30 -$7.60 UPS fee

stephen


FurkanCetin
Wed Sep 30, 2015 12:24 pm
Thanks guys!

I consider that OLED displays, they really look great. Another disadvantage of them is that they need 12V booster on PCB it means extra cost, area and workload.

However, I will continue programming with ST7735. I am planning to create a cheap version (Many people are curious about the watch and ask for one! :) ) and another with OLED screen! ILI9341 lcd with touchscreen is another alternative to use.

By the way, I prepared a quick drawing of new name and logo. It will keep continue to develop in time…
Image


zoomx
Wed Sep 30, 2015 12:56 pm
FurkanCetin wrote: ILI9341 lcd with touchscreen is another alternative to use.

FurkanCetin
Mon Oct 05, 2015 2:18 pm
Hi guys

After being absent for a long time, I could just say that I have ordered 3 of 1.5′ lcd modules with touchscreen. I am designing the PCB accordingly.
I will definitely go with them for the first prototype (without buttons on side and no OLED for now)

I am also currently developing the software and Bluetooth connection. New updates with some video and photos will come hopefully.

No giving up!
Furkan


mrburnette
Mon Oct 05, 2015 7:10 pm
FurkanCetin wrote:Hi guys

After being absent for a long time, I could just say that I have ordered 3 of 1.5′ lcd modules with touchscreen. I am designing the PCB accordingly.
I will definitely go with them for the first prototype (without buttons on side and no OLED for now)

I am also currently developing the software and Bluetooth connection. New updates with some video and photos will come hopefully.

No giving up!
Furkan


ahull
Tue Oct 06, 2015 12:06 am
Cheapest I can see on ebay is $4.60 I think there are lots of consumer devices like these.. eating up the supply. That coupled with the slow down in the Chinese economy…

FurkanCetin
Tue Oct 06, 2015 10:22 am
I am much more interested in 1.5′ color OLED screens which are at least 15$ everywhere!
Touchscreen is a must for me. I am looking forward to getting them…

mrburnette
Tue Oct 06, 2015 12:31 pm
ahull wrote:Cheapest I can see on ebay is $4.60 I think there are lots of consumer devices like these.. eating up the supply. That coupled with the slow down in the Chinese economy…

FurkanCetin
Wed Nov 04, 2015 9:49 am
Hi everyone

Sorry for not writing for a long time. I have been working on new improvements. The most important one is that new LCD displays with touchscreen are finally arrived! I will share some photos soon hopefully.


FurkanCetin
Fri Nov 06, 2015 11:42 am
I had tested an 1.5′ OLED display and it was fantastic.

However, 1.44′ TFT LCD displays (using ILI9163C) with touchscreen panel is my favorite for now. I will test them and then continue my pcb design. There are some photos here:

Image


ahull
Fri Nov 06, 2015 12:55 pm
You may have mentioned this before, but where did you source the 1.4″ display with touch panel?

FurkanCetin
Mon Nov 09, 2015 2:09 pm
Hi Andy
I have searched for it and got in contact with Kingtech Displays from China. They have great variety of LCD displays if anyone is interested in.

zoomx
Tue Nov 10, 2015 8:45 am
You bought the panel and made the PCB adapter yourself?

FurkanCetin
Tue Nov 10, 2015 9:36 am
Yes zoomx. I found a 25pin connector socket (LCD Panel has 24 pin by the way) and soldered it on 100pin LQFP PCB board (fits exactly). I will hopefully try to run it today with the bluepill.

zmemw16
Tue Nov 10, 2015 6:31 pm
wow, that’s lateral and rather neat:D

zmemw16
Fri Nov 13, 2015 9:18 pm
my st7735 oled’s arrived from

http://www.ebay.co.uk/itm/131625218909? … EBIDX%3AIT

ordered 25/10/15; their packaging took me 5mins to get into, you could have launched an egg in it:-)

stephen


inaba_nl
Thu Jul 14, 2016 9:28 pm
hey,

just wondering why you chose that specific mcu?

for example, if you were going for a STM32L4 you’d save more power, smaller package (smallest: qfn32), 64k ram, 256k flash

for example, this can allow a offscreen framebuffer of 32k (128*128 bytes*2 (16bit)) example usages: antialias, alpha blending

anyhow, enough about my mcu preference xD

i really like your project! can’t wait till you make these in production, as i’d love to order some ;)

offtopic: seems like you’re more experienced than i am in the graphical design ^^;
this is like the best i can do: https://www.youtube.com/watch?v=JX3dZQy8–Y
(yes, it’s a freescale based system, and it uses a framebuffer :P)

but i really want to make the step to stm32 for my project, as it simply is more capable, and stm32f4 supports native external flash (same goes for ram), making it possible to get a similar thing as a pebble based system.

swo this project could be a good start for me :)

yours, ramon


strawberrymaker
Thu Jul 14, 2016 9:32 pm
Guess because the L4 isn’t supported by stm32duino?

inaba_nl
Thu Jul 14, 2016 10:23 pm
yeah, that’s a issue sadly.. :(

RogerClark
Thu Jul 14, 2016 10:52 pm
https://github.com/GrumpyOldPizza/arduino-STM32L4

RogerClark
Fri Sep 02, 2016 10:02 pm
For anyone interested in smart watches in general

I just ordered some of these http://www.ebay.com.au/itm/381730512549 as they seem to use the nRF51822 MCU which can be programmed using the Arduino IDE


Nazmul
Fri May 26, 2017 2:38 pm
I really surprised why only one specific smart watch. https://www.toptechgiant.com/cheap–smart-watch/ posted about top 10 smart watches.

RogerClark
Fri May 26, 2017 9:30 pm
Nazmul wrote:I really surprised why only one specific smart watch. https://www.toptechgiant.com/cheap-smart–watch posted about top 10 smart watches.

RogerClark
Fri May 26, 2017 10:16 pm
BTW. The term smart watch seems to be a big target for spammers, I have had multiple spam comments posted on my blog in response to my smartwatch posts.

But i have never had advertising spam directed at any other subject


Leave a Reply

Your email address will not be published. Required fields are marked *