Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
Nodemcu Firmware
Commits
358379fd
Commit
358379fd
authored
Oct 07, 2018
by
devsaurus
Browse files
Updated ESP-IDF to latest.
parent
bf580849
Changes
7
Show whitespace changes
Inline
Side-by-side
components/modules/Kconfig
View file @
358379fd
...
...
@@ -64,6 +64,7 @@ config LUA_MODULE_BIT
config LUA_MODULE_BTHCI
bool "BlueTooth HCI interface module"
default "n"
select BT_ENABLED
help
Includes the simple BlueTooth HCI module.
...
...
components/modules/bthci.c
View file @
358379fd
...
...
@@ -38,7 +38,7 @@
#include "lauxlib.h"
#include "task/task.h"
#include "platform.h"
#include "bt.h"
#include "
esp_
bt.h"
#include <stdlib.h>
#include <string.h>
...
...
components/modules/ledc.c
View file @
358379fd
...
...
@@ -21,8 +21,8 @@ static int lledc_new_channel( lua_State *L )
ledc_timer_config_t
ledc_timer
;
lua_getfield
(
L
,
t
,
"bits"
);
ledc_timer
.
bit_num
=
luaL_optint
(
L
,
-
1
,
LEDC_TIMER_13_BIT
);
if
(
ledc_timer
.
bit_num
<
LEDC_TIMER_10_BIT
||
ledc_timer
.
bit_num
>
LEDC_TIMER_15_BIT
)
ledc_timer
.
duty_resolution
=
luaL_optint
(
L
,
-
1
,
LEDC_TIMER_13_BIT
);
if
(
ledc_timer
.
duty_resolution
<
LEDC_TIMER_10_BIT
||
ledc_timer
.
duty_resolution
>
LEDC_TIMER_15_BIT
)
return
luaL_error
(
L
,
"bits field out of range"
);
lua_getfield
(
L
,
t
,
"frequency"
);
...
...
components/platform/flash_api.c
View file @
358379fd
...
...
@@ -12,7 +12,7 @@
#include "platform_wdt.h"
#include "esp_image_format.h"
#include "esp_flash_
data_type
s.h"
#include "esp_flash_
partition
s.h"
#define FLASH_HDR_ADDR 0x1000
...
...
@@ -47,7 +47,7 @@ static uint32_t __attribute__((section(".iram1"))) flash_detect_size_byte(void)
uint8_t
data_orig
[
DETECT_SZ
]
PLATFORM_ALIGNMENT
=
{
0
};
uint8_t
data_new
[
DETECT_SZ
]
PLATFORM_ALIGNMENT
=
{
0
};
// Ensure we read something which isn't just 0xff...
const
uint32_t
offs
=
ESP_PARTITION_TABLE_
ADDR
;
const
uint32_t
offs
=
ESP_PARTITION_TABLE_
OFFSET
;
// Detect read failure or wrap-around on flash read to find end of flash
if
(
ESP_OK
==
spi_flash_read
(
offs
,
(
uint32_t
*
)
data_orig
,
DETECT_SZ
))
{
...
...
components/platform/platform_partition.c
View file @
358379fd
...
...
@@ -36,6 +36,7 @@
#include <string.h>
#include <stdlib.h>
#include "esp_flash_data_types.h"
#include "esp_flash_partitions.h"
#include "esp_spi_flash.h"
static
inline
bool
possible_idx
(
uint8_t
idx
)
...
...
@@ -51,7 +52,7 @@ bool platform_partition_info (uint8_t idx, platform_partition_t *info)
esp_partition_info_t
pi
;
esp_err_t
err
=
spi_flash_read
(
ESP_PARTITION_TABLE_
ADDR
+
idx
*
sizeof
(
pi
),
(
uint32_t
*
)
&
pi
,
sizeof
(
pi
));
ESP_PARTITION_TABLE_
OFFSET
+
idx
*
sizeof
(
pi
),
(
uint32_t
*
)
&
pi
,
sizeof
(
pi
));
if
(
err
!=
ESP_OK
)
return
false
;
...
...
@@ -75,7 +76,7 @@ bool platform_partition_add (const platform_partition_t *info)
if
(
!
part_table
)
return
false
;
esp_err_t
err
=
spi_flash_read
(
ESP_PARTITION_TABLE_
ADDR
,
(
uint32_t
*
)
part_table
,
SPI_FLASH_SEC_SIZE
);
ESP_PARTITION_TABLE_
OFFSET
,
(
uint32_t
*
)
part_table
,
SPI_FLASH_SEC_SIZE
);
if
(
err
!=
ESP_OK
)
goto
out
;
...
...
@@ -95,10 +96,10 @@ bool platform_partition_add (const platform_partition_t *info)
memcpy
(
slot
->
label
,
info
->
label
,
sizeof
(
slot
->
label
));
slot
->
flags
=
0
;
err
=
spi_flash_erase_sector
(
ESP_PARTITION_TABLE_
ADDR
/
SPI_FLASH_SEC_SIZE
);
ESP_PARTITION_TABLE_
OFFSET
/
SPI_FLASH_SEC_SIZE
);
if
(
err
==
ESP_OK
)
err
=
spi_flash_write
(
ESP_PARTITION_TABLE_
ADDR
,
(
uint32_t
*
)
part_table
,
SPI_FLASH_SEC_SIZE
);
ESP_PARTITION_TABLE_
OFFSET
,
(
uint32_t
*
)
part_table
,
SPI_FLASH_SEC_SIZE
);
}
out:
...
...
esp32-esp-idf
@
7313e39f
Compare
da278163
...
7313e39f
Subproject commit
da2781631455b2c87c01704503f70443799a5187
Subproject commit
7313e39fde0eb0a47a60f31adccd602c82a8d5ad
sdkconfig.defaults
View file @
358379fd
...
...
@@ -21,3 +21,13 @@ CONFIG_SPI_FLASH_WRITING_DANGEROUS_REGIONS_ALLOWED=y
# Enable panic handler for task wdt to reset the firmware upon wdt timeout
CONFIG_TASK_WDT_PANIC=y
# Disable the MQTT client from esp-idf, we have our own implementation atm
CONFIG_MQTT_PROTOCOL_311=n
CONFIG_MQTT_TRANSPORT_SSL=n
CONFIG_MQTT_TRANSPORT_WEBSOCKET=n
CONFIG_MQTT_USE_CUSTOM_CONFIG=n
# Disable esp-idf's bluetooth component by default.
# The bthci module is also disabled and will enable bt when selected
CONFIG_BT_ENABLED=n
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment