Yulong [Thu, 25 May 2017 05:57:16 +0000 (01:57 -0400)]
Merge branch 'bugfix/btdm_set_invalid_rand_addr_error_12303' of ssh://gitlab.espressif.cn:27227/idf/esp-idf into bugfix/btdm_set_invalid_rand_addr_error_12303
Ivan Grokhotkov [Fri, 19 May 2017 03:56:45 +0000 (11:56 +0800)]
Merge branch 'feature/ci_test_config_autogen' into 'master'
CI: auto generate configs for test jobs
Currently CI test jobs are static configured by several pre-generated config files.
This approach have several disadvantages:
1. not flexible to select test cases to run, which is important feature of @bot
2. difficult to update test as we need to pre-generate quite a lot files
3. need to maintain extra config files in IDF
4. not flexible to support new test apps or chips, can't use some new features of test bench
Therefore we'll add assign_test stage between build and test, to generate configs for test jobs.
Angus Gratton [Wed, 17 May 2017 02:23:39 +0000 (10:23 +0800)]
Merge branch 'bugfix/freertos_larger_stacksize' into 'master'
Make internal stack size variables in FreeRTOS 32-bit instead of 16-bit
Stock FreeRTOS uses an uint16 to store stack sizes, making it impossible to allocate a stack >64K. This changes this into an uint32, allowing for larger stacks.
Ivan Grokhotkov [Tue, 16 May 2017 05:53:46 +0000 (13:53 +0800)]
Merge branch 'feature/ulp_adc_example' into 'master'
examples: add ULP ADC example
- Add example of ULP sampling an input using ADC1, waking up the system when ADC reading goes out of given window.
- Add a pair of convenience functions: to configure ADC1 for use with ULP, and to set ULP wakeup interval.
Kewal M Shah [Wed, 29 Mar 2017 08:39:35 +0000 (16:39 +0800)]
feature: add Motor Control PWM(mcpwm) driver
1. Name change from chopper to carrier, block diagram update, minor changes to example codes
2. mcpwm_reg.h changed, brought uniformity in comments, worked on suggestions, duty to accept float. Some name changes!
3. Minor readme changes and Indetation
4. Minor change: move mcpwm_reg.h and mcpwm_struct.h to new path
5. Minor change: addition of BLDC example code and Readme
6. Name changed from epwm to mcpwm
7. Improve the reg name in mcpwm_struct.h
8. Name change chopper>carrier, deadband>deadtime
Ivan Grokhotkov [Fri, 12 May 2017 06:53:18 +0000 (14:53 +0800)]
Merge branch 'bugfix/nvs_dynamic_key_names' into 'master'
nvs: remove search cache at page level
Since read cache was introduced at page level, search cache became
useless in terms of reducing the number of flash read operations.
In addition to that, search cache used an assumption that if pointers to
keys are identical, the keys are also identical, which was proven wrong
by applications which generate key names dynamically.
This change removes CachedFindInfo, and all its uses. This is done at
expense of a small extra number of CPU operations (looking up a value in
the read cache is slightly more expensive) but no extra flash read
operations.
Merge branch 'bugfix/enlarge_wifi_task_stack_size_and_hmac_tx_queue_size' into 'master'
esp32: update wifi lib to enlarge wifi task stack size
1. Enlarge wifi task stack size by 512Bytes to fix potential stack overflow issue
2. Modify wifi hmac tx queue size from 12 to 32 because we already limit the buffer number in ebuf
management module
Ivan Grokhotkov [Fri, 12 May 2017 04:18:08 +0000 (12:18 +0800)]
nvs: remove search cache at page level
Since read cache was introduced at page level, search cache became
useless in terms of reducing the number of flash read operations.
In addition to that, search cache used an assumption that if pointers to
keys are identical, the keys are also identical, which was proven wrong
by applications which generate key names dynamically.
This change removes CachedFindInfo, and all its uses. This is done at
expense of a small extra number of CPU operations (looking up a value in
the read cache is slightly more expensive) but no extra flash read
operations.
Liu Zhi Fu [Fri, 12 May 2017 01:36:41 +0000 (09:36 +0800)]
esp32: update wifi lib to enlarge wifi task stack size
1. Enlarge wifi task stack size by 512Bytes to fix potential stack overflow issue
2. Modify wifi hmac tx queue size from 12 to 32 because we already limit the buffer number in ebuf
management module
Merge branch 'bugfix/dualcore_dport' into 'master'
component/esp32 : fix dualcore bug
1. When dual core cpu run access DPORT register, must do protection.
2. If access DPORT register, must use DPORT_REG_READ/DPORT_REG_WRITE and DPORT_XXX register operation macro.
- Fix bug that advertising stop event produced while calling start_adv function
- Modify gatt server adv data and scan rsp data raw setting
- Add create attribute table error msg
- Delete redundant printf in previous commits
Tian Hao [Mon, 8 May 2017 12:03:04 +0000 (20:03 +0800)]
component/esp32 : fix dualcore bug
1. When dual core cpu run access DPORT register, must do protection.
2. If access DPORT register, must use DPORT_REG_READ/DPORT_REG_WRITE and DPORT_XXX register operation macro.
Jeroen Domburg [Mon, 8 May 2017 09:28:55 +0000 (17:28 +0800)]
Merge branch 'bugfix/spi_example' into 'master'
SPI: Various fixes (examples, mem leak, arg check)
- Fix SPI master example to use DMA-capable memory for display initialization. Fixes https://github.com/espressif/esp-idf/issues/551
- SPI master: Do not leak DMA descriptor pointer array on free
- SPI Master/Slave: Check if DMA'ed buffers actually live in DMA-capable memory
Ivan Grokhotkov [Mon, 8 May 2017 07:48:28 +0000 (15:48 +0800)]
Merge branch 'feature/save_esptool_flash_args' into 'master'
CI: save download config in CI build jobs:
IDF built app download config may change with some modification.
save the download configs for built APP in build stage.
then we can use the correct download config in test stage.
- Fix bug that advertising stop event produced while calling start_adv function
- Modify gatt server adv data and scan rsp data raw setting
- add create attribute table error msg
- Delete redundant printf in previous commits
He Yin Ling [Fri, 5 May 2017 12:20:09 +0000 (20:20 +0800)]
CI: remove CI configs and update test case files:
we'll auto assign cases to test jobs so we don't need those config
files. cases with different wifi modes will now be generated when
creating test case database, we need to remove them from YAML files.
Ivan Grokhotkov [Fri, 5 May 2017 09:03:17 +0000 (17:03 +0800)]
Merge branch 'bugfix/spiflash_fatfs_fixes_and_tests' into 'master'
FATFS fixes and tests
This MR includes a set of fixes related to FATFS, SDMMC, and wear levelling:
- `esp_vfs_fat_spiflash_mount` uses `FM_SFD` flag when creating the partition. The volume layout (given in `VolToPart` variable) was not compatible with SFD mode, so mkfs was failing. This fixes the volume layout to use "autodetect" for both volumes. Merges https://github.com/espressif/esp-idf/pull/559.
- fix `prepend_drive_to_path`function, which didn't prepend drive to path (while consuming 2k of stack space)
- fix stack overflow in vfs_fat_link function which allocated two 4kbyte `FIL` structures on the stack
- fix support for having two FATFS instances (in flash and SD) mounted at the same time
- unit tests written for FATFS on SDMMC are made common between SDMMC and WL implementations; FATFS unit tests on WL will run during CI
- fix inconsistent definition of PATH_MAX and ARG_MAX (TW12207, TW12104, https://github.com/espressif/esp-idf/issues/289)
component/bt: fix some bugs related to bluetooth sniff mode in controller
1. fix some bugs in bluetooth sniff mode in controller
2. export some symbols to esp32.rom.ld including functions and global variables in ROM code
3. update libbtdm.a which includes "IRAM_ATTR" addition or removal for some functions
Merge branch 'feature/enable_wifi_ebuf_sanity_check' into 'master'
esp32: update wifi lib to enable ebuf sanity check
The wifi ebuf sanity checking is disabled by default, this MR is to enable it by default. If we detect the last 4 Bytes of ebuf is not DEADBEEF, we assert the system, with the sanity checking, we can detect the ebuf memory corrupt easy.
Ivan Grokhotkov [Thu, 4 May 2017 08:48:44 +0000 (16:48 +0800)]
fatfs: run same fatfs tests for WL and SDMMC
This change moves actual test code into test_fatfs_common.c and
refactors setup/teardown code to be contained within separate functions.
For each SDMMC FATFS test, identical test is added which can run with
WL partition in flash.
Ivan Grokhotkov [Thu, 4 May 2017 06:49:33 +0000 (14:49 +0800)]
vfs_fat: allocate FIL structures on the heap in vfs_fat_link
vfs_fat_link opened two files to perform copy operation. File structures
were allocated on the stack. When _MAX_SS setting was increased in
ffconf.h due to wear levelling feature, the size of these structures
increased to ~4k each (~8k total). This exceeds stack size allocated for
tasks in most typical cases.
This change makes file structures dynamically allocated.
Ivan Grokhotkov [Thu, 4 May 2017 06:46:11 +0000 (14:46 +0800)]
vfs_fat: fix prepend_drive_to_path
Originally, prepend_drive_to_path was designed to be a macro, and it
modified local path variables to point to a temporary buffers.
When it was converted into a function, modification to path variables
were no longer visible outside of this function.
In addition to that, prepend_drive_to_path allocated 2k bytes on the
stack for temporary path buffers. This is replaced with path buffers
allocated as part of vfs_fat context object. Locking is added around
parts of code which use these temporary buffers.
Additionally, _lock member of vfs_fat_ctx_t was placed after the
variable-sized files array, which caused the first entry in the
array to be never used. This change fixes the order of members
and adds comments.