Commit graph

700 commits

Author SHA1 Message Date
Ivan Grokhotkov
822a9981d8 Merge branch 'master' into feature/btdm_controller
* master:
  esp32/lib: update to f6d55836
2016-09-22 18:40:54 +08:00
Ivan Grokhotkov
c6e1d0b30a Kconfig: make WiFi and BT mutually exclusive
Also move memory map options from top-level Kconfig to esp32/Kconfig.
2016-09-22 18:36:23 +08:00
Ivan Grokhotkov
bc256cc36d components/bt: add library as submodule 2016-09-22 17:54:19 +08:00
Ivan Grokhotkov
db407074f1 components/bt: remove binary library 2016-09-22 17:52:07 +08:00
snake
993287af61 add btdm_controller 1st 2016-09-22 16:40:31 +08:00
Wu Jian Gang
28be72dbc7 esp32/lib: update to f6d55836
1. Fix reboot halt bug when 240MHz, TW7355
2. Disable long rate code
2016-09-22 16:30:34 +08:00
daniel
01d17dd5f9 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.
2016-09-22 13:41:21 +08:00
Wu Jian Gang
c35a9b8cda Merge branch 'bugfix/tw7054' into 'master'
esp32:tw7054 remove sta netif when sta disconnect from ap

When sta disconnect from ap, remove sta netif to let lwip to free all tcp pcbs

See merge request !101
2016-09-22 11:58:33 +08:00
liuzhifu
67e8b3bcaf tcpip_adapter: set sta ip to IP_ADDR_ANY when sta disconnect from ap
When sta is disconnected from AP, set sta ip to IP_ADDR_ANY to trigger lwip
to clean up all TCP/UDP pcbs.
2016-09-22 11:49:37 +08:00
Ivan Grokhotkov
226e64bd1e Merge branch 'driver_merge_tmp/fix_fifo_struct_header' into 'master'
use uint8_t for fifo struct in uart and i2c

use uint8_t for fifo struct in uart and i2c

See merge request !106
2016-09-22 11:39:16 +08:00
Ivan Grokhotkov
b59aa4a282 Merge branch 'driver_merge_tmp/merge_gpio' into 'master'
add gpio driver code



See merge request !93
2016-09-22 11:21:18 +08:00
Wangjialin
71fe8d9f15 Merge branch 'master' into driver_merge_tmp/merge_gpio 2016-09-22 10:50:06 +08:00
Ivan Grokhotkov
ba75f837b8 components/spi_flash: add performance counters 2016-09-22 10:39:36 +08:00
Wangjialin
d2420b667c use uint8_t for fifo struct in uart and i2c 2016-09-22 09:05:39 +08:00
Ivan Grokhotkov
12a0786e2a components/nvs: maintain item hash list at page level 2016-09-21 18:02:52 +08:00
Ivan Grokhotkov
f06ebeba86 components/nvs: avoid reading just-erased page 2016-09-21 18:02:52 +08:00
Wu Jian Gang
31f74b8008 Merge branch 'feature/wifi_lib_update' into 'master'
bugfix: reboot halt and deep sleep crash

1. Fix reboot halt bug, TW7355
2. Fix system crash when calling system_deep_sleep(), TW7356

See merge request !104
2016-09-21 17:22:39 +08:00
Wu Jian Gang
134649141c esp32/lib: update to 9f26b9a1
1. Fix reboot halt bug, TW7355
2. Fix system crash when calling system_deep_sleep(), TW7356
2016-09-21 16:49:30 +08:00
Wu Jian Gang
835cc55138 esp32: wait uart tx finish before cpu freq change 2016-09-21 16:15:42 +08:00
Wangjialin
92569082c6 Remove some macros and declarations that are already in rom/gpio.h 2016-09-21 12:08:42 +08:00
Wu Jian Gang
4f93b49e0a esp32/lib: update to 9403d944 2016-09-21 11:37:10 +08:00
Wangjialin
f7b10745be Remove mutex from GPIO driver code. Replace uint8_t/uint16_t with uint32_t 2016-09-21 09:51:37 +08:00
Angus Gratton
af82eed35d Merge branch 'bugfix/macos_build' into 'master'
fix kconfig build on macOS

macOS version of sed doesn't recognize \r as special character.
Replacing with \x0D substitution which works everywhere.

See merge request !96
2016-09-20 19:28:20 +08:00
Ivan Grokhotkov
d09a79c20d Merge branch 'feature/menuconfig_cpu_frequency_option' into 'master'
Add CPU frequency selection in menuconfig

See merge request !81
2016-09-20 17:45:46 +08:00
Ivan Grokhotkov
9a1bf32274 Merge branch 'feature/lwip_add_debug_code' into 'master'
lwip: add debug code to show udp/tcp pcbs

Add code to show all tcp/udp pcbs, these kind of debug info is helpful for lwip issue debugging.

See merge request !98
2016-09-20 17:22:22 +08:00
Ivan Grokhotkov
da69d6ad3c Merge branch 'master' into feature/menuconfig_cpu_frequency_option
* master: (57 commits)
  components/lwip: fix grammar
  components/lwip: make SO_REUSE configurable via menuconfig
  bootloader: remove trailing newlines from log messages
  components/freertos: override per-task __cleanup handler to close stdin, stdout, stderr
  components/esp32: move peripheral symbols to separate ld script
  components/log: regroup macros for better readability
  gitlab-ci: allow running tests for branches, triggered via API
  components/log: fix timestamp calculation
  components/log: set default runtime log level to ESP_LOG_VERBOSE
  components/log: fix error when using ESP_LOGx from C++ code
  components/log: fix bugs, add options to override log level for files, components, and bootloader
  fix ledc and spi typo
  remove prefix and postfix
  Enable SO_REUSEADDR in LWIP
  freertos: fix memory debug macro issue Define configENABLE_MEMORY_DEBUG according to CONFIG_ENABLE_MEMORY_DEBUG
  peripheral structure headers: move volatile keyword from members to typedef
  Adding -fstrict-volatile-bitfields to the CFLAGS/CXXFLAGS. Without this, gcc tries to access bitfields using the smallest possible methods (eg l8i to grab an 8-bit field from a 32-bit). Our hardware does not like that. This flag tells gcc that if a bitfield is volatile, it should always use the type the field is defined at (uint32_t in our case) to size its access to the field. This fixes accessing the hardware through the xxx_struct.h headers.
  add peripheral  module struct headers
  build system docs: Add note about no spaces in component names
  Docs: Add note about unusual submodule messages when cloning on Windows
  ...

# Conflicts:
#	components/esp32/cpu_start.c
#	components/esp32/include/soc/cpu.h
2016-09-20 17:22:18 +08:00
Ivan Grokhotkov
6e35c0a91a Merge branch 'feature/logging' into 'master'
Add logging library

Logging library, intended to be used across other components.
Uses design similar to Android NDK logging APIs and allows for both compile time and run time filters, similar to logcat.

Also includes cleanup of cpu_startup.c — i was changing some logging output in this file so decided to re-format it and reduce code duplication.

Ref TW6703

See merge request !68
2016-09-20 17:16:41 +08:00
Ivan Grokhotkov
d260aa777c Merge branch 'bugfix/lwip_so_reuse' into 'master'
make SO_REUSE configurable via menuconfig

SSC expects SO_REUSE to be off by default.
Trivial change, moving this option to menuconfig.
This should also (finally!) fix failing tests in master.

See merge request !99
2016-09-20 17:13:09 +08:00
Ivan Grokhotkov
3b22173a93 components/lwip: fix grammar 2016-09-20 16:53:56 +08:00
Ivan Grokhotkov
6b42b90595 Merge branch 'master' into bugfix/lwip_so_reuse
* branch 'master':
  components/freertos: override per-task __cleanup handler to close stdin, stdout, stderr
  gitlab-ci: allow running tests for branches, triggered via API
2016-09-20 16:24:21 +08:00
Ivan Grokhotkov
316d3f9c4a components/lwip: make SO_REUSE configurable via menuconfig
Not all environments need or can work with SO_REUSE enabled, so making this option configurable.
2016-09-20 15:36:55 +08:00
liuzhifu
f64e1c54b7 lwip: add license and add lwip_debug.h 2016-09-20 15:36:49 +08:00
liuzhifu
50c7583f4d lwip: add debug code to show udp/tcp pcbs 2016-09-20 14:51:03 +08:00
Ivan Grokhotkov
dcf34b1be1 bootloader: remove trailing newlines from log messages 2016-09-20 14:18:23 +08:00
Ivan Grokhotkov
45df01ef68 Merge branch 'feature/ci_test_trigger' into 'master'
allow running test suite for branches, triggered via API

One line change to run testing step for branches, if the build is triggered via API.


See merge request !91
2016-09-20 14:11:24 +08:00
Ivan Grokhotkov
6ca02748ac Merge branch 'bugfix/newlib_fd_memory_leak' into 'master'
override per-task __cleanup handler to close stdin, stdout, stderr

Default _cleanup_r function (called from _reclaim_reent) calls _fclose_r for all file descriptors related to a particular instance of struct _reent.
It does that by calling _fwalk_reent, which iterates over __sglue list in struct _reent and calls _fclose_r for each member. But _stdin, _stdout, and _stderr are not in this list, so _fclose_r is not called for them. Which leads to a memory leak.
The easy way to fix this is to reset __cleanup member of struct _reent to our new “patched” version, which first calls the original version (_cleanup_r) and then does _fclose_r for each of the stdin, stdout, and stderr.

See merge request !94
2016-09-20 12:12:06 +08:00
Ivan Grokhotkov
f5f625ead5 kconfig: fix build on macOS
macOS version of sed doesn't recognize \r as special character.
Replacing with \x0D substitution which works everywhere.
2016-09-20 11:31:46 +08:00
Ivan Grokhotkov
e8ae38024d components/freertos: override per-task __cleanup handler to close stdin, stdout, stderr
Default _cleanup_r doesn't do that, which leaks these three file descriptors.
2016-09-19 19:28:36 +08:00
Wangjialin
948be5c0c4 modify typo 2016-09-19 17:50:18 +08:00
Wangjialin
2be163f6cc add gpio driver code 2016-09-19 17:33:21 +08:00
Ivan Grokhotkov
b1ac144874 Merge branch 'driver_merge_tmp/merge_struct_header' into 'master'
add peripheral modules struct headers



See merge request !88
2016-09-19 15:34:37 +08:00
Ivan Grokhotkov
ff2750ab07 components/esp32: move peripheral symbols to separate ld script 2016-09-19 15:05:32 +08:00
Jeroen Domburg
dfab57cd93 Merge branch 'features/lwip-SO_REUSEADDR' into 'master'
Enable SO_REUSEADDR in LWIP

Daniel initially asked me why this wasn't enabled, and I don't think I got any reasons against enabling this. If any, it makes porting existing software easier. Tuan needs it for UDP multicast as well.

Code changes are by Tuan: basically the enable for SO_REUSEADDR in LWIP as well as a bugfix in a bit of mbedTLS that gets enabled.

See merge request !90
2016-09-19 10:42:35 +08:00
Angus Gratton
c2bc965c2c Merge branch 'bugfix/rom_gpio' into 'master'
rom/gpio.h: Use new GPIO_PIN0_REG register name

Closes github #12

See merge request !86
2016-09-19 10:41:34 +08:00
Angus Gratton
0c71709b63 Merge branch 'bugfix/windows' into 'master'
Fix some Windows build issues

Fix and/or document some issues seen under Windows (especially if git clones with CRLF line endings)

See merge request !87
2016-09-19 10:41:14 +08:00
Ivan Grokhotkov
14e003fcf2 components/log: regroup macros for better readability 2016-09-19 08:53:09 +08:00
Ivan Grokhotkov
d9338e64e5 gitlab-ci: allow running tests for branches, triggered via API 2016-09-18 23:12:50 +08:00
Ivan Grokhotkov
1188bdfc68 components/log: fix timestamp calculation 2016-09-18 21:06:43 +08:00
Ivan Grokhotkov
26bf85bad6 components/log: set default runtime log level to ESP_LOG_VERBOSE
With this change, it is possible to use LOG_LOCAL_LEVEL to raise debug level for given file/component
2016-09-18 21:01:28 +08:00
Ivan Grokhotkov
3cdefd9923 components/log: fix error when using ESP_LOGx from C++ code 2016-09-18 20:51:57 +08:00