Jeroen Domburg [Tue, 19 Dec 2017 11:12:58 +0000 (19:12 +0800)]
Fix the clock subsystem so it doesn't undo the weird condition spiram_psram.c jams the enable/reset bits of SPI3 in when 80MHz mode is selected anymore
krzychb [Thu, 7 Dec 2017 21:45:39 +0000 (22:45 +0100)]
1. Following https://esp32.com/viewtopic.php?f=14&t=3834 and https://github.com/espressif/esp-idf/issues/1351 updated information regarding selection of the main XTAL frequency. 2. Removed obsolete note about ': not a valid identifier...', as it does not show up anymore with the latests MSYS2 installation.
Ivan Grokhotkov [Fri, 8 Dec 2017 08:14:20 +0000 (16:14 +0800)]
time: rename time source option from FRC to "high-resolution timer"
libc time function now rely on esp_timer_get_time as the source of
high-resolution time, rather than FRC1 timer. Internally, on the ESP32
esp_timer implementation uses FRC2 timer.
- Change help text and labels in Kconfig to use "high-resolution timer"
instead of FRC1. Keep existing Kconfig option name to be backwards
compatible.
- Change references to "FRC1" in the source code to "FRC".
Ivan Grokhotkov [Fri, 8 Dec 2017 12:03:24 +0000 (20:03 +0800)]
vfs/fatfs: use structures with bit fields for FAT date/time
Replace explicit masks and shifts with bit fields when working with FATFS date and time representations. Also zero-initialize remaining members of struct tm.
A couple of typos referencing tx_ring_buf when rx_ring_buf, slv_tx_mux
instead of slv_rx_mux.
Also, I2C_ENTER_CRITICAL()/I2C_EXIT_CRITICAL() usage was not consistent.
Only some of the _set_ functions had them. Most of the _get_ function
had them? It is my understanding that they should be wrapped around
writes, not reads? (I think we still need the lock for reading pairs of consistent values)
Also, the ticks_to_wait timeout handling in i2c_master_cmd_begin() would
not handle integer rollover correctly.
Ivan Grokhotkov [Fri, 8 Dec 2017 04:23:54 +0000 (12:23 +0800)]
sdspi: use response timeout passed from upper layer
Previously SDSPI host driver would rely on retry count when waiting for
the card to read or write data. This caused different timeout times
depending on CPU frequency and card clock frequency. In practice, card
performance does not depend on these two factors.
This change uses timeout_ms field of sdmmc_command_t introduced
previously for SDMMC host.
Fixes https://esp32.com/viewtopic.php?f=2&t=3440&p=16037 and similar
issues related to SDSPI timeouts.
Ivan Grokhotkov [Fri, 8 Dec 2017 11:58:39 +0000 (19:58 +0800)]
vfs/fatfs: fix stat call failing when called for mount point
FATFS does not support f_stat call for drive root. When handling stat
for drive root, don't call f_stat and just return struct st with S_IFDIR
flag set.
Piyush Shah [Thu, 23 Nov 2017 10:09:17 +0000 (15:39 +0530)]
freertos/ringbuf: Added an API xRingbufferCreateNoSplit()
This is a wrapper API for creating a Ring Buffer, which ensures that
the ringbuffer can hold the given number of items, each item being of the
same given length.
Piyush Shah [Mon, 20 Nov 2017 13:53:25 +0000 (19:23 +0530)]
freertos/ringbuf: Add an API xRingbufferGetCurFreeSize() to fetch current free size available
The earlier available API (xRingbufferGetMaxItemSize())just gives
a static max entry value possible for given ring buffer.
There was a feature request for an API which could provide
a real time available buffer size. See below:
houchenyao [Thu, 30 Nov 2017 11:31:51 +0000 (19:31 +0800)]
unit-test-app: support multiple devices test cases:
current unit-test-app don't support test components need to communicate
with each other (like GPIO, SPI ...). Now we add multiple devices mode
to unit test app, support writing and running test with multiple DUTs.
please refer to `docs/api-guides/unit-tests.rst` for detail.
Ivan Grokhotkov [Fri, 1 Dec 2017 04:50:45 +0000 (12:50 +0800)]
docs: add FreeRTOS API docs
- Use `code` tags instead of a mix of `<pre></pre>` and
`@verbatim .. @endverbatim`
- Remove manually added function prototypes from comment blocks
- Remove of grouping (`\defgroup`) — some extra work is needed
to make groups compatible with the way we auto-generate API
reference from Doxygen XML files. It's pretty easy to add the
grouping directives back if/when we implement support for
Doxygen groups in the later stages of documentation build
process.
- Hide private APIs under `@cond .. @endcond`
- Convert some comments into Doxygen-compatible ones
- Fix various documentation issues: missing documentation for
some parameters, mismatch between parameter names in comment
block and in function prototype.
- Add doxygen comments for functions which didn't have them
(thread local storage).
- Add [out] param tags where necessary
- Redefine `xTaskCreate` and `xTaskCreateStatic` as inline
functions instead of macros.
This was due to the different order in the macro and the struct. The struct has another order of the fields (opcode, unused, cycles) vs (cycles, unused, opcode):
> struct {
> uint32_t cycles : 16; /*!< Number of cycles to sleep */
> uint32_t unused : 12; /*!< Unused */
> uint32_t opcode : 4; /*!< Opcode (OPCODE_DELAY) */
> } delay; /*!< Format of DELAY instruction */
After updating the order in the macro it is possible to compile with the g++ compiler.
krzychb [Mon, 4 Dec 2017 05:10:50 +0000 (06:10 +0100)]
Pin descriptions, overview diagram and board dimensions carried over from ESP32-PICO-KIT_Datasheet_EN.pdf. The datasheet looks redundant and will not be used.
Darian Leung [Thu, 23 Nov 2017 14:35:54 +0000 (22:35 +0800)]
freertos/fix SMP bug with Idle task clean up
This commit backports vTaskDelete() behavior from FreeRTOS v9.0.0 which
allows for the immediate freeing of task memory if the task being deleted
is not currently running and not pinned to the other core. This commit also
fixes a bug in prvCheckTasksWaitingTermination which prevented the
Idle Task from cleaning up all tasks awaiting deletion. Each iteration of the Idle
Task should traverse the xTasksWaitingTermination list and clean up all tasks
not pinned to the other core. The previous implementation would cause
prvCheckTasksWaitingTermination to return when encountering a task
pinned to the other core whilst traversing the xTasksWaitingTermination list.
The test case for vTaskDelete() has been updated to test for the bugfix and
backported deletion behavior.
krzychb [Mon, 4 Dec 2017 19:22:24 +0000 (20:22 +0100)]
LEDC Driver: Added back original definitions of 'duty_resolution' and 'clock_divider'. This update is to provide backward compatibility with ESP-IDF 2.1.