add the md files from the docs repo to start updating them to v8

This commit is contained in:
Gabor Kiss-Vamosi
2021-04-12 18:19:04 +02:00
parent c587fc4d2a
commit 73f4264320
93 changed files with 7007 additions and 0 deletions

35
docs/porting/tick.md Normal file
View File

@@ -0,0 +1,35 @@
```eval_rst
.. include:: /header.rst
:github_url: |github_link_base|/porting/tick.md
```
# Tick interface
The LVGL needs a system tick to know the elapsed time for animation and other tasks.
You need to call the `lv_tick_inc(tick_period)` function periodically and tell the call period in milliseconds. For example, `lv_tick_inc(1)` for calling in every millisecond.
`lv_tick_inc` should be called in a higher priority routine than `lv_task_handler()` (e.g. in an interrupt) to precisely know the elapsed milliseconds even if the execution of `lv_task_handler` takes longer time.
With FreeRTOS `lv_tick_inc` can be called in `vApplicationTickHook`.
On Linux based operating system (e.g. on Raspberry Pi) `lv_tick_inc` can be called in a thread as below:
```c
void * tick_thread (void *args)
{
while(1) {
usleep(5*1000); /*Sleep for 5 millisecond*/
lv_tick_inc(5); /*Tell LVGL that 5 milliseconds were elapsed*/
}
}
```
## API
```eval_rst
.. doxygenfile:: lv_hal_tick.h
:project: lvgl
```