Added first half of RE'd user_interface.c
This commit is contained in:
parent
3e5af479bc
commit
8c9a77efe8
20 changed files with 745 additions and 30 deletions
|
|
@ -27,6 +27,7 @@
|
|||
#include "espressif/esp_common.h"
|
||||
#include "espressif/phy_info.h"
|
||||
#include "sdk_internal.h"
|
||||
#include "esplibs/libmain.h"
|
||||
|
||||
/* This is not declared in any header file (but arguably should be) */
|
||||
|
||||
|
|
@ -345,8 +346,8 @@ static __attribute__((noinline)) void user_start_phase2(void) {
|
|||
sdk_phy_info_t phy_info, default_phy_info;
|
||||
|
||||
sdk_system_rtc_mem_read(0, &sdk_rst_if, sizeof(sdk_rst_if));
|
||||
if (sdk_rst_if.version > 3) {
|
||||
// Bad version number. Probably garbage.
|
||||
if (sdk_rst_if.reason > 3) {
|
||||
// Bad reason. Probably garbage.
|
||||
bzero(&sdk_rst_if, sizeof(sdk_rst_if));
|
||||
}
|
||||
buf = malloc(sizeof(sdk_rst_if));
|
||||
|
|
@ -357,8 +358,8 @@ static __attribute__((noinline)) void user_start_phase2(void) {
|
|||
get_otp_mac_address(sdk_info.sta_mac_addr);
|
||||
sdk_wifi_softap_cacl_mac(sdk_info.softap_mac_addr, sdk_info.sta_mac_addr);
|
||||
sdk_info._unknown0 = 0x0104a8c0;
|
||||
sdk_info._unknown1 = 0x00ffffff;
|
||||
sdk_info._unknown2 = 0x0104a8c0;
|
||||
sdk_info._unknown4 = 0x00ffffff;
|
||||
sdk_info._unknown8 = 0x0104a8c0;
|
||||
init_g_ic();
|
||||
|
||||
read_saved_phy_info(&phy_info);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue