Attempting to add support to esp32s3.

Will it work? Who knows...

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos
2024-04-04 21:01:55 +02:00
parent 3d0a27c834
commit 023039deb2
24 changed files with 229 additions and 74 deletions

View File

@@ -20,7 +20,7 @@
#define _FILE_H_
#include <stdlib.h>
#ifndef ENABLE_EMULATION
#if !defined(ENABLE_EMULATION) && !defined(ESP_PLATFORM)
#include "pico/stdlib.h"
#else
#include <stdbool.h>

View File

@@ -19,13 +19,13 @@
#include <stdint.h>
#include <string.h>
#ifndef ENABLE_EMULATION
#include "pico/stdlib.h"
#include "hardware/flash.h"
#else
#if defined(ENABLE_EMULATION) || defined(ESP_PLATFORM)
#define XIP_BASE 0
#define FLASH_SECTOR_SIZE 4096
#define PICO_FLASH_SIZE_BYTES (8 * 1024 * 1024)
#else
#include "pico/stdlib.h"
#include "hardware/flash.h"
#endif
#include "pico_keys.h"
#include "file.h"

View File

@@ -20,7 +20,7 @@
#include <stdlib.h>
#include <stdio.h>
#ifndef ENABLE_EMULATION
#if !defined(ENABLE_EMULATION) && !defined(ESP_PLATFORM)
#include "pico/stdlib.h"
#include "hardware/flash.h"
#include "hardware/sync.h"
@@ -38,15 +38,19 @@
#define lseek _lseek
#include "mman.h"
#else
#ifdef ESP_PLATFORM
#else
#include <unistd.h>
#include <sys/mman.h>
#endif
#include <fcntl.h>
#define FLASH_SECTOR_SIZE 4096
#define PICO_FLASH_SIZE_BYTES (8 * 1024 * 1024)
#define XIP_BASE 0
int fd_map = 0;
uint8_t *map = NULL;
#endif
#endif
#include "pico_keys.h"
#include <string.h>