Commit Graph

485 Commits

Author SHA1 Message Date
OnlineCaveman
d24f6de36f Added the RF (0x27B0)
Added checks for RF 0x27B0 as that should work ootb I suppose.

Builds and uploads successfully.
Gives the debug output "ERROR, RF transceiver not responding" since I have no RF hw to test.

Same goes for the TP 0x07B0. Build and uploads successfully.
Gives the debug output "ERROR, TPUART not responding" since no I have no TP uart hw to test.
2022-10-25 17:24:55 +02:00
OnlineCaveman
7373ab0a87 No IP version yet 2022-10-25 16:19:53 +02:00
OnlineCaveman
76762571ea Ifdef include requested change 2022-10-25 15:56:34 +02:00
OnlineCaveman
02565a0ba3 Cleanup
Removed unnecesary Qspi stuff for now. Compiles fine for samd51 and samd21. Have no samd21 platform or tpuart to do thorough testing but nothing fundamental was changed in samd_platform other than the ifdef checks.
2022-10-17 21:10:23 +02:00
OnlineCaveman
598f6bddfd Merge branch 'master' of https://github.com/OnlineCaveman/knx-samd51 2022-10-17 20:38:08 +02:00
OnlineCaveman
37e056a91c ARCH_SAMD
Now checking for __SAMD21__ and __SAMD51__ in knx_facade, samd_platform (samd21) and samd51_platform (samd51)

Preparation for external flash functionality in platform.h
2022-10-17 20:37:44 +02:00
OnlineCaveman
b403480f0c
Merge branch 'thelsing:master' into master 2022-10-17 19:59:28 +02:00
OnlineCaveman
c0e5621a5f Rename back to original 2022-10-17 19:52:10 +02:00
OnlineCaveman
6c4a10e189 Fault in change tracking
Renaming subdir knx to force changes
2022-10-17 19:51:31 +02:00
OnlineCaveman
b8107fd62d SAMD51/SAMD21 files
Separate files for SAMD51 and SAMD21 platforms.
2022-10-17 19:48:09 +02:00
Sonnengruesser
a0134e6cfb
RP2040 EEPROM/Flash compiler flag fix (#216)
* RP2040 EEPROM/Flash compiler flag fix

only check flash size if Flash is used, not EEPROM

* RP2040 EEPROM/Flash compiler flag fix

use EEPROM emulation as default to allow build of the knx-demo (memory.h defines EEPROM size 1024 which doesn't work with Flashsize 4k)

* Update rp2040_arduino_platform.h
2022-10-15 22:25:22 +02:00
mumpf
5b48f21f53
get rid of some warnings during build (#214)
(comparison between signed and unsigned integer expressions)

Co-authored-by: Waldemar Porscha <wp@porscha.eu>
2022-10-15 22:24:58 +02:00
OnlineCaveman
4248a1f073 Updated for samd51 flash storage compatibility 2022-10-15 16:15:32 +02:00
thelsing
920b1d287a
Update README.md 2022-08-15 11:31:29 +02:00
Matthias B
8af9121f6f
H8I8O Example (#210)
Firmware for the H8I8O that allows configuring pins as input, output or PWM output in a similar way to the original.
2022-08-15 11:27:57 +02:00
thelsing
5dc3d7666b
Update platformio.ini 2022-08-15 11:12:48 +02:00
thelsing
476d9ce57d
Update platformio.ini 2022-08-15 11:12:30 +02:00
thelsing
6631d278a0
Update platformio-ci.ini 2022-08-15 11:12:16 +02:00
thelsing
2049321071
Update platformio-ci.ini 2022-08-15 11:11:57 +02:00
thelsing
704c334ffe
Update platformio-ci.ini 2022-08-15 11:10:06 +02:00
mumpf
3bf7f5ce48
remove unnecessary print to console (#213)
Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-07-15 23:11:10 +02:00
Matthias B
8b9ff4fce1
H8I8O (#209)
* Add defines for LED, button and serial port

To make supporting different board layouts easier, this introduces some new defines:

For all platforms:
- `KNX_LED` -  the programming LED, defaults to `LED_BUILTIN`
- `KNX_BUTTON` - the programming button, defaults to `0`

For Arduino platforms:
- `KNX_DEBUG_SERIAL` - the serial port that is used for debugging, defaults to `Serial`
- `KNX_SERIAL` - the serial port used for communication with the TPUART, default depends on platform

* GD32 flash workaround

Addressing #181

At least some GD32 devices seem to require unlocking the flash twice. As the unlock function exits with `HAL_OK` if the flash is already unlocked, STM32 devices can run the same code without issues.

* Add H8I8O and H8C09 configurations to knx-demo

Addressing #181

These configurations both serve as examples for the use of these boards and other custom boards that don't use the standard pinout.

* Add STM32 unlock target

This copies the brute force unlock approach by @pavkriz into a custom target. With this commit, it is possible to automatically unlock e.g. a H8I8O board without leaving the PlatformIO IDE.

See #181
2022-06-08 21:13:34 +02:00
rueckix
bd907c242d
Fix prog button handling (#207)
* Update stm32_platform.cpp

Addresses a side effect of https://github.com/thelsing/knx/pull/177, which causes the eeprom buffer to be overwritten every time getEepromBuffer is called. This prevented programming of STM32 boards as their initial bus address was lost before programming.

* progbutton fix

* Update stm32_platform.cpp

Addresses a side effect of https://github.com/thelsing/knx/pull/177, which causes the eeprom buffer to be overwritten every time getEepromBuffer is called. This prevented programming of STM32 boards as their initial bus address was lost before programming.

* Update knx_facade.h

Remove superfluous attribute _buttonPinInterruptOn

* Update knx_facade.h

attachInterrup on CHANGE for progbutton detection
2022-05-31 07:20:59 +02:00
rueckix
3948045c28
Fix stm32 eeprom handling (#205)
* Update stm32_platform.cpp

Addresses a side effect of https://github.com/thelsing/knx/pull/177, which causes the eeprom buffer to be overwritten every time getEepromBuffer is called. This prevented programming of STM32 boards as their initial bus address was lost before programming.

* Code style fix
2022-04-30 22:15:16 +02:00
croghostrider
eb963583ee
Fix last CodeFactor Style issues (#202)
* fix malformed whitespace

* fix trailing spaces 


fix trailing spaces
2022-04-25 20:30:53 +02:00
mumpf
d43703f7bd
Get rid of occsional fails during ETS programming (#200)
- happens just with large applications
- occured mainly on SAMD platform
- new crc16ccitt algorithm without additional buffer
- reorder groupObjTable in memory for less fragmentation

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-04-25 19:27:47 +02:00
croghostrider
e12a074e07
Removed redundant declaration (#199)
remove "virtual" where "override" or "final" already implies it.
2022-04-25 11:27:40 +02:00
mumpf
4b8b951be8
FIX issue introduced with #194 (#201)
- if go handler writes to same go, value is not sent to bus anymore

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-04-25 11:18:57 +02:00
Simon Billemont
29702f69c3
Fix #191 by initializing the platform pointer in all KnxFacade constructors (#198)
* Fix #191 by initializing the platform pointer in all KnxFacade constructors

* Revert "Fix #191 by initializing the platform pointer in all KnxFacade constructors"

This reverts commit adc05cfaf7.

* Alternative fix for #191 by initializing the platform pointer in KnxFacade(&bau) from the platform stored in bau
2022-04-19 09:51:36 +02:00
Simon Billemont
01979174e3
Fixed accedental swap of size parameter and KNX_FLASH_SIZE define introduced in PR #196 (#197) 2022-04-16 22:16:02 +02:00
Simon Billemont
b0153de97f
Fix issue with Esp8266/Esp32 platform reinitializing EEPROM multiple times causing it to forget staged EEPROM changes (#196) 2022-04-13 09:19:18 +02:00
mumpf
9c620a013d
GroupObjects can communicate internally (#194)
* GroupObjects can communicate internally
- GroupObjects use callback infrastructure also during write to bus
- external and internal write of a GO can be handled identically
- needs #define INTERNAL_GROUPOBJECT

* FIX-Works now also if SMALL_GROUPOBJECT is not set

* Remove #ifdef INTERNAL_GROUPOBJECT

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-04-12 00:28:21 +02:00
mumpf
2453c3ce5d
Forgotten init for PR #187 (#195)
Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-04-06 21:36:36 +02:00
mumpf
22af8267c3
Openknx version support (#190)
* Feature: Allow additional version check on startup
- added versionCheckCallback
- added apiVersion to DeviceObject
- added new versionCheck to memory,cpp

* updated source code formatting

* changes for PR
- (old) version is again part of version check
- naming conventions

* forgotten parameter in callback

* correct wrong buffer initialization

* version <-> apiVersion swapped

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-03-02 13:38:30 +01:00
mumpf
a10fa20bde
Feature: additional callbacks for application (#189)
* Feature: additional callbacks for application
- beforeRestart callback
- beforeTablesUnload callback

* naming conventions for PR

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-03-01 21:42:03 +01:00
mptei
145c354110
Removed unneded TX_WAIT_ECHO state; fixed echo detection (#188) 2022-03-01 17:30:54 +01:00
mumpf
4f17ed4b5d
Feature: Uninitialized GO handling (#187)
- don't send senseless values on GroupValueRead

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-03-01 17:28:11 +01:00
mptei
f4d7f604be
Handling buffer overrun (#184) 2022-02-26 22:41:23 +01:00
SirSydom
1f079147c0
solves #183 (#185)
get the unique id directly from flash instead using the async. SDK call.
2022-02-26 22:40:17 +01:00
mumpf
c47a8b06c8
- Get rid of EEPROM emulation (#186)
- Use SAMD-Flash without copying parameters to RAM

Co-authored-by: Waldemar Porscha <waldemar.porscha@sap.com>
2022-02-26 22:39:21 +01:00
mptei
9c48027d3c
Using defines in ACK handling (#182)
* Using defines in ACK handling

* added newline
2022-02-24 21:23:57 +01:00
SirSydom
d27f420217
solves #178 bugfix when sending frames > 63 byte, missing masking of … (#179)
* solves #178 bugfix when sending frames > 63 byte, missing masking of upper bits after sending a U_DataOffset

* also masked U_L_DATA_END_REQ correctly

* used bit masking instead of %
2022-02-24 10:13:02 +01:00
SirSydom
a306174878
Branch flash pr with large eeprom (#177)
* save WIP on flash api + header reorder

* reduce diffs to master

* added support for RP2040 (Raspberry Pi Pico)

* support DPT9.009 (airflow) and DPT9.029 (absolute humidity)

* added support for RP2040 (Raspberry Pi Pico) (#145)

* worked on flash implementation

* worked on flash implementation

* added malloc for _EraseBlockBuffer, fixed some bugs

* fixed memoryread and crash while loading KOs (+debugstuff)

* some fixes and debugs

* align to pagesize

* clean up debug stuff, comments ...

* added support for both Eeprom and Flash (NvMemoryType) plattforms.

* changed memoryReadIndicationP to memoryReadIndication
added stdlib and defines

* fixed std::min

* another try for fixing the min problem

* rolled back linux plattform to eeprom

* comments only, hints for plattforms

* bugfix when calculating memorywrites over multiple blocks by mumpf

* added support for EEPROM-Emulation / RAM-buffered Flash
improvements in RP2040 plattform

* fixed typo in KNX_FLASH_OFFSET

* - writebuffersize clarified (PR discussion)
- changed alignment from flashpagesize to 32bit
- added override modifier (PR discussion)
- changed comment regarding flash/eeprom functions for plattforms to override/implement (PR discussion)

* resolved CodeFactor issue

Co-authored-by: Thomas Kunze <thomas.kunze@gmx.com>
2022-02-22 14:24:36 +01:00
Michael Geramb
53425e2ef7
Add callback functions for prog mode and improve documentation (#173) 2022-02-19 20:23:50 +01:00
thelsing
d26771c432
Merge pull request #171 from mptei/tx_throttle_rx_wait_addr
More tpuart fixes
2022-02-13 21:56:03 +01:00
SirSydom
2c2d69a396
Rp2040 plattform newcore (#172)
* added support for RP2040 (Raspberry Pi Pico)

* support DPT9.009 (airflow) and DPT9.029 (absolute humidity)

* adapted to work with the latest arduino-pico core V1.11.0
- setPollingMode for knxSerial
2022-02-13 21:54:38 +01:00
Mike Pieper
408cd2bbeb printHex takes to long 2022-02-13 11:22:02 +01:00
Mike Pieper
c908d5dc0a handle all available bytes 2022-02-06 14:13:48 +01:00
Mike Pieper
7d7e6eb3b4 New state RX_L_ADDR; loop load adaption 2022-02-06 07:55:34 +01:00
Mike Pieper
1ee4377e61 tx throttle. 2022-01-22 15:20:27 +01:00