mirror of
https://github.com/thelsing/knx.git
synced 2025-08-08 13:47:01 +02:00
reworked PR #230
This commit is contained in:
parent
62f3e85cea
commit
50d2b7a70b
3
.vscode/extensions.json
vendored
3
.vscode/extensions.json
vendored
@ -3,5 +3,8 @@
|
|||||||
// for the documentation about the extensions.json format
|
// for the documentation about the extensions.json format
|
||||||
"recommendations": [
|
"recommendations": [
|
||||||
"platformio.platformio-ide"
|
"platformio.platformio-ide"
|
||||||
|
],
|
||||||
|
"unwantedRecommendations": [
|
||||||
|
"ms-vscode.cpptools-extension-pack"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@ -495,7 +495,7 @@ void CC1310Platform::init()
|
|||||||
setupNVS();
|
setupNVS();
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t* CC1310Platform::getEepromBuffer(uint16_t size)
|
uint8_t* CC1310Platform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
if(size > KNX_FLASH_SIZE)
|
if(size > KNX_FLASH_SIZE)
|
||||||
{
|
{
|
||||||
|
@ -108,7 +108,7 @@ bool Esp32Platform::sendBytesUniCast(uint32_t addr, uint16_t port, uint8_t* buff
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t * Esp32Platform::getEepromBuffer(uint16_t size)
|
uint8_t * Esp32Platform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
uint8_t * eepromptr = EEPROM.getDataPtr();
|
uint8_t * eepromptr = EEPROM.getDataPtr();
|
||||||
if(eepromptr == nullptr) {
|
if(eepromptr == nullptr) {
|
||||||
|
@ -108,7 +108,7 @@ bool EspPlatform::sendBytesUniCast(uint32_t addr, uint16_t port, uint8_t* buffer
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t * EspPlatform::getEepromBuffer(uint16_t size)
|
uint8_t * EspPlatform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
uint8_t * eepromptr = EEPROM.getDataPtr();
|
uint8_t * eepromptr = EEPROM.getDataPtr();
|
||||||
if(eepromptr == nullptr) {
|
if(eepromptr == nullptr) {
|
||||||
|
@ -265,7 +265,7 @@ int LinuxPlatform::readBytesMultiCast(uint8_t* buffer, uint16_t maxLen)
|
|||||||
return len;
|
return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t* LinuxPlatform::getEepromBuffer(uint16_t size)
|
uint8_t* LinuxPlatform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
if (_fd < 0)
|
if (_fd < 0)
|
||||||
doMemoryMapping();
|
doMemoryMapping();
|
||||||
|
@ -109,7 +109,7 @@ void RP2040ArduinoPlatform::restart()
|
|||||||
|
|
||||||
#ifdef USE_RP2040_LARGE_EEPROM_EMULATION
|
#ifdef USE_RP2040_LARGE_EEPROM_EMULATION
|
||||||
|
|
||||||
uint8_t * RP2040ArduinoPlatform::getEepromBuffer(uint16_t size)
|
uint8_t * RP2040ArduinoPlatform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
if(size%4096)
|
if(size%4096)
|
||||||
{
|
{
|
||||||
@ -144,7 +144,7 @@ void RP2040ArduinoPlatform::commitToEeprom()
|
|||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
uint8_t * RP2040ArduinoPlatform::getEepromBuffer(uint16_t size)
|
uint8_t * RP2040ArduinoPlatform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
if(size > 4096)
|
if(size > 4096)
|
||||||
{
|
{
|
||||||
|
@ -61,7 +61,7 @@ void SamdPlatform::restart()
|
|||||||
|
|
||||||
#ifdef USE_SAMD_EEPROM_EMULATION
|
#ifdef USE_SAMD_EEPROM_EMULATION
|
||||||
#pragma warning "Using EEPROM Simulation"
|
#pragma warning "Using EEPROM Simulation"
|
||||||
uint8_t* SamdPlatform::getEepromBuffer(uint16_t size)
|
uint8_t* SamdPlatform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
//EEPROM.begin(size);
|
//EEPROM.begin(size);
|
||||||
if(size > EEPROM_EMULATION_SIZE)
|
if(size > EEPROM_EMULATION_SIZE)
|
||||||
|
@ -34,7 +34,7 @@ void Stm32Platform::restart()
|
|||||||
NVIC_SystemReset();
|
NVIC_SystemReset();
|
||||||
}
|
}
|
||||||
|
|
||||||
uint8_t * Stm32Platform::getEepromBuffer(uint16_t size)
|
uint8_t * Stm32Platform::getEepromBuffer(uint32_t size)
|
||||||
{
|
{
|
||||||
// check if the buffer already exists
|
// check if the buffer already exists
|
||||||
if (_eepromPtr == nullptr) // we need to initialize the buffer first
|
if (_eepromPtr == nullptr) // we need to initialize the buffer first
|
||||||
|
Loading…
Reference in New Issue
Block a user