Author:
Yi-Hui Chou B06901012, Luo-Yun Rong B06901073
Department:
3rd year, Electrical Engineering Department, National Taiwan University
Advisor:
Professor Sheng-De Wang
- A motion Recorder for day and night
- Implement on STM32L475 and STM32L476+IKS01A2
- Use wifi and uart to transmit data
Wearable devices are everywhere, so we want to create an intelligent wearable to record a person's activity, including moving, sleeping, exercising, and so on, so as to manage his or her health.
We have two modes in this project, day mode and night mode.
- Day mode
Update motion detection, with 8 motions in total (stationary, standing, sitting, lying, walking, fast walking, jogging, biking)
- Night mode
If asleep, detect turnover.
If not asleep, detect the user's activity, which is same with Day mode.
- STM32l476 nucleo + IKS01A2
There are lots of sensors in IKS01A2. In this project, LSM6DSL accelerometer and LPS22HB pressure sensor are used. IKS01A2 would collect data, and nucleo would do the calculation and analyze a user's status.
- STM32l475 disco
Use UART4 port to receive messages from nucleo, and decode them. Afterwards, disco would send messages to PC server using socket.
- PC server
Upon receiving messages from disco, PC server would record the time and the message to a log file, and display the result on screen using SDL library.
- Day mode
We successfully detect motions like stationary, walking, fast walking, jogging, sitting. Moreover, it goes smoothly when pressing a button to switch mode.
- Night mode
We successfully detect motions when a user is not asleep and we also detect turn over immediately. Moreover, when STM32 nucleo is stationary for more than 6 minutes, the status turns from no sleeping to lying and then to sleeping, which pretty makes sense.
- clone all the repo
- go to SDL official website to download SDL library
- compile display.cpp
g++ display.cpp -lSDL2 -o display | tee logfile
- In terminal, execute ./display, and click start to start listening