Jeroen Domburg [Mon, 31 Oct 2016 03:04:28 +0000 (11:04 +0800)]
Merge branch 'feature/crosscore_int' into 'master'
Add cross-core int to accelerate task being awoken from another CPU.
This adds a per-CPU interrupt that can be used to poke the CPU to go do something. In this case all that is implemented is a request to yield the current task, used in case a CPU unblocks a task that runs on another CPU. This gets rid of the limitation that inter-CPU communication using queues, muxes etc can take up to a FreeRTOS tick to happen.
Specs!
Sending an in in a queue of length 1 (essentially a semaphore) as quickly as possible (just a small delay in the sender, to make sure the receiver task gets swapped out) for 10 seconds. Number indicates the amount of ints transferred
Ivan Grokhotkov [Fri, 28 Oct 2016 08:21:34 +0000 (16:21 +0800)]
Merge branch 'bugfix/int-wdt-fix' into 'master'
Fix the things that broke when adding the new WDTs
Seemingly, I broke a bunch of things when adding the interrupt WDTs and moved the panic handler to the esp32 directory. This fixes that, as well as the issue where flashing would trigger the int wdt. It also bodges in a fix for a merge artifact breaking the halt-on-first-thread-when-openocd-is-connected; that fix should be refined later.
Wu Jian Gang [Fri, 28 Oct 2016 07:38:57 +0000 (15:38 +0800)]
Merge branch 'feature/support_max_16_sockets' into 'master'
lwip: support max 16 sockets
Since the customers need more sockets in their application, support max 16 sockets,
in other words, the total socket number of UDP/TCP/RAW sockets should not exceed 16.
Liu Zhi Fu [Fri, 28 Oct 2016 04:03:51 +0000 (12:03 +0800)]
lwip: support max 16 sockets
Since the customers need more sockets in their application, support max 16 sockets,
in other words, the total socket number of UDP/TCP/RAW sockets should not exceed 16.
Ivan Grokhotkov [Fri, 21 Oct 2016 10:44:57 +0000 (18:44 +0800)]
spi_flash: implement partition API, drop trivial wrappers
This implements esp_partition_read, esp_partition_write, esp_partition_erase_range, esp_partition_mmap.
Also removed getters which didn't add much sugar after all.
Ivan Grokhotkov [Fri, 21 Oct 2016 09:28:50 +0000 (17:28 +0800)]
spi_flash: change argument types
spi_flash_read and spi_flash_write currently have a limitation that source and destination must be word-aligned.
This can be fixed by adding code paths for various unaligned scenarios, but function signatures also need to be adjusted.
As a first step (since we are pre-1.0 and can still change function signatures) alignment checks are added, and pointer types are relaxed to uint8_t.
Later we will add handling of unaligned operations.
This change also introduces spi_flash_erase_range and spi_flash_get_chip_size functions.
We probably need something like spi_flash_chip_size_detect which will detect actual chip size.
This is to allow single application binary to be used on a variety of boards and modules.
Ivan Grokhotkov [Thu, 27 Oct 2016 09:47:45 +0000 (17:47 +0800)]
Merge branch 'feature/vfs' into 'master'
Virtual filesystem APIs
This changeset adds virtual filesystem APIs. As an example, UART devices are mapped to `/dev/uart/x`.
Also fixes an issue with per-task FILE descriptors.
Ivan Grokhotkov [Wed, 26 Oct 2016 06:05:56 +0000 (14:05 +0800)]
vfs and newlib: small fixes
- spaces->tabs in tasks.c
- update vfs_uart.c to use per-UART locks
- add license to vfs_uart.c
- allocate separate streams for stdout, stdin, stderr, so that they can be independently reassigned
- fix build system test failure
- use posix off_t instead of newlib internal _off_t
Ivan Grokhotkov [Tue, 25 Oct 2016 14:12:07 +0000 (22:12 +0800)]
vfs and newlib: small fixes
- spaces->tabs in tasks.c
- update vfs_uart.c to use per-UART locks
- add license to vfs_uart.c
- allocate separate streams for stdout, stdin, stderr, so that they can be independently reassigned
- fix build system test failure
Ivan Grokhotkov [Thu, 27 Oct 2016 09:09:35 +0000 (17:09 +0800)]
Merge branch 'feature/wdts' into 'master'
Feature/wdts
This adds two watchdogs to esp-idf:
- An interrupt watchdog. Kicks in if the FreeRTOS timer interupt on either the PRO_CPU or (when configured) the APP CPU isn't called for a configurable time. Panics, displaying which CPU caused the problem and the registers that may lead to the offending code.
- A task watchdog. A task has to feed it every once in a while. If not, it will print the name of the offending tasks, as well as the tasks currently running on both CPUs, and optionally panic.
Also adds a panic reason to the panic call, as well as fixes the panic code a bit.
Jeroen Domburg [Thu, 27 Oct 2016 08:07:47 +0000 (16:07 +0800)]
Add checks for tasks woken up on other CPUs where needed, make xYieldPending and xPendingReadyList per-processor, add configurable ISR stack size to Kconfig, in general fix the entire wake-up-task-on-other-cpu-by-interrupt implementation
Ivan Grokhotkov [Thu, 27 Oct 2016 05:44:31 +0000 (13:44 +0800)]
Merge branch 'feature/freertos_static_buffers' into 'master'
Backport the static allocation feature from FreeRTOS V9.0.0
This feature allows to use static buffers (or from a pool of memory which is not
controlled by FreeRTOS).
In order to reduce the impact of the changes, the static feature has only been added
to the queus (and in consequence to the semaphores and the mutexes) and the tasks.
The Timer task is always dynamically allocated and also the idle task(s), which in the
case of the ESP-IDF is ok, since we always need to have dynamic allocation enabled.
Original PR on Github: https://github.com/espressif/esp-idf/pull/21
Wu Jian Gang [Thu, 27 Oct 2016 03:33:56 +0000 (11:33 +0800)]
Merge branch 'feature/add_api_to_get_ap_info' into 'master'
esp32: add esp_wifi_sta_get_ap_info
The customers need to get information about AP that associated with ESP32 station,
these information includes RSSI, channel number etc, so add this new API
Liu Zhi Fu [Thu, 27 Oct 2016 02:42:01 +0000 (10:42 +0800)]
esp32: add esp_wifi_sta_get_ap_info
The customers need to get information about AP that associated with ESP32 station,
these information includes RSSI, channel number etc, so add this new API
liuzhifu [Wed, 26 Oct 2016 12:02:39 +0000 (20:02 +0800)]
esp32/tcpip_adapter: rework according to review comments
1. Modify sta to station in comments
2. Modify esp_wifi_get_ap_num to esp_wifi_scan_get_ap_num
3. Modify esp_wifi_get_ap_list to esp_wifi_scan_get_ap_records
liuzhifu [Wed, 26 Oct 2016 06:09:54 +0000 (14:09 +0800)]
components esp32/lwip: modify code according to review comments
1. Modify comments for esp_wifi_internal_tx
2. Fix delay time error in esp32_tx_flow_ctrl which is found in code review,
modify _wait_delay init value from 0 to 1