Commit Graph

241 Commits

Author SHA1 Message Date
Thomas Basler
74abc1ec1d Feature: Added new found HMS-2000 to DevInfoParser
Fix #886
2023-05-06 12:16:05 +02:00
Markus Krause
a56d5adb77 fix SPI assignment across generations 2023-04-28 21:26:22 +02:00
Markus Krause
b086c6ace6 remove non-sensical octa-spi setting in FIFO mode 2023-04-28 21:26:22 +02:00
Markus Krause
a37b394139 try fix SPI driver for CMT 2023-04-28 21:26:22 +02:00
Markus Krause
14f9d1b3c6 avert SPI collision on S3/S2/C3 2023-04-28 21:26:22 +02:00
Thomas Basler
3504884836 Fix: xSemaphoreTake was useless
There was no check of the return value implemented therefore xSemaphoreTake was just executed and not locked
2023-04-28 21:02:10 +02:00
Thomas Basler
0441bbbe72 Fix: Queue consumed whole memory on inverter timeout
When the poll interval was e.g. 1sec it was possible that the queue ran full and consumed the whole memory.
Now new entries are only added to the queue automatically if the queue is empty.  This issue also caused a lot of "DTU command failed" messages.
2023-04-25 19:24:56 +02:00
Thomas Basler
98da2b64e2 Rename FLD_PRA to FLD_Q 2023-04-24 22:29:59 +02:00
Thomas Basler
270a7f4933 Rename UNIT_VA to UNIT_VAR 2023-04-24 22:25:15 +02:00
Thomas Basler
793cd9db91 Fix: Possible crash when multiple tasks accessed the SPI bus
This could happen when  the main loop and the web server callback accessed the  SPI bus at the same time  (e.g. to show the isConnected status)
2023-04-22 10:59:32 +02:00
Thomas Basler
f5c15a445b Move byteAssignment to stack (avoid container) to save heap 2023-04-22 01:12:29 +02:00
Thomas Basler
0e9c666981 Implement method as static 2023-04-21 19:02:10 +02:00
Thomas Basler
5d2656550c Optimize detection if RF module is configured
Use PinMapping method instead of dedicated method in Hoymiles lib --> Same result but reduces variables
2023-04-17 23:19:53 +02:00
Thomas Basler
af3a277e30 Introduced HoymilesRadio property to determine if a configuration attempt was done 2023-04-17 18:59:56 +02:00
Thomas Basler
1416efc6f9 Fix: Endless loop when CMT module was configured but not connected 2023-04-17 18:58:23 +02:00
Thomas Basler
7c37d289c0 Enabled additional statistics data for HMT inverters
Not yet shown in web ui and mqtt
2023-04-15 10:55:48 +02:00
Thomas Basler
6856ba9972 Fix: Change defines to get a correct calculation if base frequency of CMT module is different compared to Hoymiles base frequency 2023-04-15 10:55:48 +02:00
Thomas Basler
f3942bb647 Fix: Set correct frequency when changing it via web ui
Previously it could happen that the frequency was changed between saving old and recovering new frequency. Therefor an invalid frequency was saved in the CMT module
2023-04-15 10:55:48 +02:00
Thomas Basler
8356db94b9 Send ChannelChangeCommand only once per cycle as the inverter will not response at all 2023-04-15 10:55:48 +02:00
Thomas Basler
ac7b5dba11 Resend and Retransmit count is now implementable per command 2023-04-15 10:55:48 +02:00
Thomas Basler
e2aa29f117 Remove cmtProocess method and move RF logic into the cmt2300wrapper class 2023-04-15 10:55:48 +02:00
Thomas Basler
f5767e61ef Implement CMD56 as own command.
By doing so, it's possible to send all packets via the sendEsbPacket method. A lot of stuff could be removed which is no more used.
2023-04-15 10:55:48 +02:00
Thomas Basler
cfb37906ca Rename cmtFreqToChan to getChannelFromFrequency and simplify handling of current channel 2023-04-15 10:55:48 +02:00
Thomas Basler
1259f09503 Replace multiple print calls by a single printf in HoymilesRadio_NRF 2023-04-15 10:55:48 +02:00
Thomas Basler
a11ee472c6 Optimize cmtChToFreq method to return float instead of string. Renamed also to getFrequencyFromChannel 2023-04-15 10:55:48 +02:00
Thomas Basler
2a92f67a9a Implement get and set channel in cmt2300 wrapper class 2023-04-15 10:55:48 +02:00
Thomas Basler
fffd872b20 Replace HOY_BASE_FREQ by CMT_BASE_FREQ 2023-04-15 10:55:48 +02:00
Thomas Basler
5b648b63ac Implemented blocking write method in CMT2300 driver and use it in sendEsbPacket. 2023-04-15 10:55:48 +02:00
Thomas Basler
6331210b94 IsReachable of the inverter was never reached 2023-04-15 10:55:48 +02:00
Thomas Basler
25722f6055 Adjust buffer size in StatisticsParser for inverters with more inputs 2023-04-15 10:55:48 +02:00
Thomas Basler
50ce7f014d Expose min and max frequency in HoymilesRadio_CMT 2023-04-15 10:55:48 +02:00
Thomas Basler
6ea34b331d Increase command timeouts to support inverters with 6 channels and more phases 2023-04-15 10:55:48 +02:00
Thomas Basler
1614b2ad2d Add newline after log output 2023-04-15 10:55:48 +02:00
Thomas Basler
5e11f0b854 Implement property in HoymilesRadio_CMT to set the frequency during runtime 2023-04-15 10:55:48 +02:00
Thomas Basler
fe5e5bc4b1 Implement cmtBaseChOff860 as a define 2023-04-15 10:55:48 +02:00
Thomas Basler
4561e52735 Adjusted some comments 2023-04-15 10:55:48 +02:00
Thomas Basler
996404ceed Introduce gpio2 for the CMT2300A module
This implements the sending interrupt instead of polling. On the other hand, gpio3 is made optional.
2023-04-15 10:55:48 +02:00
Thomas Basler
bec9870347 Move alarm messages from heap to stack 2023-04-15 10:55:47 +02:00
Thomas Basler
fc5f6887cb Adjust name from CMT2300a to CMT2300A 2023-04-15 10:55:47 +02:00
Thomas Basler
098691af9d First step towards a modular CMT2300 driver similar to the NRF24 one 2023-04-15 10:55:47 +02:00
Thomas Basler
035fdbc54a Increase CMT SPI speed to 4 MHz 2023-04-15 10:55:47 +02:00
Thomas Basler
defcc02204 Set CMT to 13dBm and added parameter values in plain text 2023-04-15 10:55:47 +02:00
Thomas Basler
67055276ca Implement different Eventlog messages for HMT inverters
Also make message list much more readable
2023-04-15 10:55:47 +02:00
Thomas Basler
06cc19fc70 Use TimeoutHelper for TX timeout 2023-04-15 10:55:47 +02:00
Thomas Basler
46036eb958 Simplify dumpBuf method in HoymilesRadio 2023-04-15 10:55:47 +02:00
Thomas Basler
83c623708f Fix crash if radio settings where changed while the radio was not initialized 2023-04-15 10:55:47 +02:00
Thomas Basler
de2b7ab2d2 Check that all RF modules as in idle mode before sending mqtt packages 2023-04-15 10:55:47 +02:00
Thomas Basler
b7fb294368 Set DTU serial for CMT modules 2023-04-15 10:55:47 +02:00
Thomas Basler
dc91929d6e First rough implementation of HMT inverters 2023-04-15 10:55:47 +02:00
Thomas Basler
45882543b6 Allow dynamic pin mapping for CMT module 2023-04-15 10:55:47 +02:00