Wang Jia Lin [Thu, 29 Dec 2016 05:15:48 +0000 (13:15 +0800)]
Merge branch 'buffix/uart_frm_err_parity_err_mismatch' into 'master'
bugfix: uart event mismatch
Fix bug of uart frame error and parity error interrupt mismatch in driver code, which will cause the corresponding interrupt can not be cleared correctly, and will finally cause a interrupt watch dog.
Ivan Grokhotkov [Thu, 29 Dec 2016 04:36:04 +0000 (12:36 +0800)]
Merge branch 'feature/gpio_intr_function' into 'master'
GPIO driver: add per-pin interrupt handlers
1. add ISR handler apis so that users of different layers can hook their own isr handler on different GPIO.
Audio project has different software layers, they need different gpio isr handler for layer instead of processing all GPIO interrupts in one handler.
If this kind of calling a handler from isr is not proper, please kindly point out.
2. add gpio example code.
3. update gpio doc.
Wangjialin [Sat, 24 Dec 2016 12:45:57 +0000 (20:45 +0800)]
gpio_driver: add per-pin interrupt handlers
1. add ISR handler apis so that users of different layers can hook their own isr handler on different GPIO.
Audio project has different software layers, they need different gpio isr handler for layer instead of processing all GPIO interrupts in one handler.
If this kind of calling a handler from isr is not proper, please kindly point out.
2. add gpio example code.
3. improve gpio.rst
4. add readme for gpio example
Squashed commits:
[278e50f] update: GPIO
1. coding style, add a space between conditional or loop keyword and an opening paren.
2. modify some return value and doc
3. use printf in example code
Squashed commits:
[efb23bb] minor change of comment
Merge branch 'bugfix/tw9313_dual_core_issue' into 'master'
freertos: fix dual core issue
This commit try to fix dual issue tw9313 raised by QA
1. Put per-core data into critical session or interrupt disabled/enabled session
2. Idle task may have problem when it terminate the task in both core
shangke [Sun, 18 Dec 2016 13:18:37 +0000 (21:18 +0800)]
feature/ethernet_driver: update ethernet driver
1. The transmitting mode of the packets from LWIP to MAC is changed from synchronous to asynchronous.
2. The receive buf mode : support pointer mode and copy mode.
3. Add get phy status func used to config mac register.
Wangjialin [Thu, 22 Dec 2016 04:08:15 +0000 (12:08 +0800)]
bugfix: uart event mismatch
1. Fix bug of uart frame error and parity error interrupt mismatch in driver code, which will cause the corresponding interrupt can not be cleared correctly, and will finally cause a interrupt watch dog.
2. Add gpio pull-up for rx pin and cts pin.
Yinling [Thu, 24 Nov 2016 03:46:58 +0000 (11:46 +0800)]
generate test result and commit to CI-test-result:
1. config git user name before commit
2. continue committing test result for failed jobs
3. update test result repository path
4. change escape key word in branch name, use '___' to escape key word '/' in report file name
Liu Zhi Fu [Thu, 22 Dec 2016 02:17:39 +0000 (10:17 +0800)]
freertos: fix dual core issue
This commit fixes:
1. xTaskGetCurrentTaskHandle may return wrong TCB when current task switch to a different core
2. Idle task may have problem when it terminate the task in both core
Angus Gratton [Tue, 20 Dec 2016 22:54:33 +0000 (06:54 +0800)]
Merge branch 'bugfix/minor_fixes' into 'master'
Minor fixes from various sources
- Fix memory debugging code. Noticed by Tuan.
- intr_enable/disable should be in IRAM. Noticed by rojer
- Still old timer code in examples in doxygen comments. Noticed on the forum by jumjum123
- Timer example was broken. Noticed on the forum by jumjum123
Wangjialin [Wed, 23 Nov 2016 08:28:16 +0000 (16:28 +0800)]
driver: sigma-delta
1. add sigma-delta code and example.
2. add gpio output signal in io matrix.
Squashed commits:
[a25e7d4] minor changes for doc
[6a03a1e] minor changes on comments and doc.
[97dd9e4] Add doc.
update index.rst
change example index
Ivan Grokhotkov [Fri, 16 Dec 2016 12:25:38 +0000 (20:25 +0800)]
ulp: use timer to start ULP, fix I_ANDI bug, add tests
Starting the ULP using SENS_SAR_START_FORCE_REG doesn’t disable clock gating of RTC fast clock.
When SoC goes into deep sleep mode, RTC fast clock gets gated, so ULP can no longer run.
Instead, it has to be started using the timer (RTC_CNTL_ULP_CP_SLP_TIMER_EN bit).
When ULP is enabled by the timer, clock also gets enabled.
Ivan Grokhotkov [Fri, 16 Dec 2016 08:17:37 +0000 (16:17 +0800)]
Merge branch 'feature/extend_deep_sleep_apis' into 'master'
extend deep sleep APIs
This adds the following APIs to enable various wakeup sources:
- esp_deep_sleep_enable_timer_wakeup
- esp_deep_sleep_enable_ulp_wakeup
- esp_deep_sleep_enable_ext0_wakeup
- esp_deep_sleep_enable_ext1_wakeup
And an API to start deep sleep:
- esp_deep_sleep_start
Add an API to control which peripherals are kept enabled in deep sleep mode:
- esp_err_t esp_deep_sleep_pd_config
Also rolled an update of rtc_io header comments into this MR, as I had to add `slpie`, `slpsel`, and `hold` fields into `rtc_gpio_desc_t` struct.
Deep sleep unit tests don’t do anything useful in CI context because we don’t have a way to check reset behavior (time till reset, reason for reset) in CI environment, yet. Also for external wakeup we would need to control some ESP32 pins from the test environment.
Currently there is one known issue:
- RTC Fast memory may be isolated from the bus after deep sleep reset. We work around this by setting FORCE_NONISO flag in RTC power control register. This is non-optimal and we will keep looking for the reason why isolation gets enabled.
Ivan Grokhotkov [Fri, 16 Dec 2016 06:26:05 +0000 (14:26 +0800)]
deep sleep: set pin configuration right before entering deep sleep
This change allows setting pin configuration for EXT1 wakeup depending on the state of RTC_PERIPH power domain:
- if peripherals are enabled (due to another wakeup mode, or due to esp_deep_sleep_pd_config call), we can keep internal pullups/pulldowns enabled
- if peripherals are disabled, pullups and pulldowns need to be disabled as well
Also add comments about the purpose of registers being configured.
Ivan Grokhotkov [Wed, 14 Dec 2016 06:23:40 +0000 (14:23 +0800)]
deep sleep: RTC fast memory may be disconnected after deep sleep wakeup
This adds a workaround for a bug that following deep sleep wakeup, ISO (bus isolation) signal may be set for RTC fast memory.
We set FORCE_NOISO bit in RTC_CNTL_PWC_REG until we find out what is causing ISO signal to be set.
Ivan Grokhotkov [Mon, 12 Dec 2016 15:20:15 +0000 (23:20 +0800)]
deep sleep: add option to delay CPU startup
When ESP32 wakes up from deep sleep, flash is accessed an approximately 900us after power on.
Some flash chips need more time to become ready. This change adds a menuconfig option to add
some delay to the default deep sleep wake stub.
Ivan Grokhotkov [Thu, 8 Dec 2016 14:22:10 +0000 (22:22 +0800)]
deep sleep: implement wake up using ULP, EXT0, EXT1 sources
This adds the following APIs to enable various wakeup sources:
- esp_deep_sleep_enable_timer_wakeup
- esp_deep_sleep_enable_ulp_wakeup
- esp_deep_sleep_enable_ext0_wakeup
- esp_deep_sleep_enable_ext1_wakeup
And an API to start deep sleep:
- esp_deep_sleep_start
Liu Zhi Fu [Mon, 12 Dec 2016 02:00:24 +0000 (10:00 +0800)]
esp32: refactor to sniffer
1. TW8657, WIFI send the whole packet to smartconfig;
2. modify API annotation of smartconfig and sniffer;
3. export smartconfig APIs to programming guide;
Ivan Grokhotkov [Thu, 15 Dec 2016 08:28:29 +0000 (16:28 +0800)]
Merge branch 'bugfix/heap_alloc_no_iram' into 'master'
Restore ability to alloc IRAM, and more.
- Fix mem regions so allocating IRAM works again
- Optimize allocator slightly, uses 4 less bytes per malloc now
- Allow querying free heap memory space per memory type
Merge branch 'bugfix/btdm_bluedroid' into 'master'
Bugfix/btdm bluedroid
Cleanup all the warnings。
Fix GATT CLIENT cannot receive notfiy/indicate from GATT SERVER bug.
Originally, bluetooth have its own master branch(feature/btdm_bluedroid), all the bluetooth sub branch will merge to feature/btdm_bluedroid firstly. If feature/btdm_bluedroid is ready, it will request merge to master. But as Ivan/JG/Jack's requires, all the bluetooth bugfix or feature will request merge to master ASAP.
This MR contains "cleanup warning " and "some bug fix", after, every merge request only contain one thing.
Jeroen Domburg [Thu, 15 Dec 2016 07:15:32 +0000 (15:15 +0800)]
Merge branch 'bugfix/uart_examples_intr' into 'master'
Update uart examples in uart.h to new interrupt allocation scheme
Some of the examples in the UART header haven't been adjusted to the new interrupt scheme; this fixes that. Also runs dos2unix on the drivers tree; a fair few drivers used DOS-style line ends.