-
Notifications
You must be signed in to change notification settings - Fork 35
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix - GFSK & nano crash #211
Fix - GFSK & nano crash #211
Conversation
Allows other modulations than ASK / OOK and 2-FSK to be received.
* revised PROGVERS * pins excluded to avoid crash
* revised comment & changed pins
src/signalduino.h
Outdated
@@ -96,7 +96,7 @@ void setup() { | |||
; // wait for serial port to connect. Needed for native USB | |||
} | |||
|
|||
for (uint8_t i=2;i<13;i++) { | |||
for (uint8_t i=4;i<10;i++) { // pullup on for unused pins |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mir ist das nicht klar, wieso das eine Auswirkung hat, wenn wir die PINs ganz am Anfang auf Eingang mit pullup stellen, damit die nicht umher floaten.
Mit der Anpassung bleibt der pin doch im undefinierten Zustand, wenn wir ohne cc1101 compilieren oder?
Wenn wir den Pin in einem anderen Modus brauchen, dann muss der doch später passend initialisert werden anstelle davon auszugehen, dass der Standardwert für uns passt.
Ebenso PIN 3 und 4, sind doch im Zweifelsfall undefiniert oder?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
enso PIN 3 und 4, sind doch im Zweifelsfall undefiniert oder?
Unter der Schleife werden diese gesetzt.
Lines 103 to 104 in 00089bb
pinAsInput(PIN_RECEIVE); | |
pinAsOutput(PIN_LED); |
Mit der Anpassung bleibt der pin doch im undefinierten Zustand, wenn wir ohne cc1101 compilieren oder?
Dann musst du den cc1101 if deffen :-) denke ich mal.
Es gibt 2 Fälle.
- ohne cc1101
- mit cc1101 wo man bestimmte Pin´s nicht mit 'pinAsInputPullUp' versehen sollte.
ODER ...
der ganze Ablauf muss überarbeitet werden wenn ich das richtig einschätze und überblicke.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also generell heisst das ja, dass D4 bis D9 nun als Eingang mit Weak-Pullup geschaltet werden.
Das ist in Ordnung. D10 ist /CS (also Ausgang), D11 ist MOSI (also Ausgang), D12 ist MISO (also Eingang, kein Pullup notwendig) und D13 ist SCK, also auch Ausgang.
D10 bis D13 sollten wahrscheinlich von der Arduino Library im SPI Init richtig gesetzt werden.
EDIT: Ob die Lib das konfiguriert weiss ich zwar nicht, hab nicht reingeschaut, aber wenn nicht, koennte das tatsaechlich Probleme machen.
Wenn das eine Problem macht, koennte man das evtl. mit einem Oszi sehen (da der Pullup sichtbar das Signal veraendern sollte, wenn der CC1101 da nicht gegen arbeiten kann. Evtl. kommen daher die Wartezeiten, wo dann #212 reinhaut.
Wahrscheinlich ist das Problem mit beiden PRs geloest.
D2 ist GDO2, also Input, D3 ist GDO0, also Output, right?
Was ist mit D1? Der floatet?
Aber dennoch, ein floatender Eingang sollte funktional nichts machen, wenn er nicht abgefragt wird oder an einen Pin Change Interrupt gebunden ist - es kann aber EMV Probleme machen und ist daher zuvermeiden.
Dein Fix repariert aber das D10 bis D13 auf EIngang mit Pullup zu verbiegen. Ich hab im Datenblatt nicht gefunden, ob das was kaputt machen kann. Ich wuerde fast vermuten nein, sonst wuerde SPI auch gar nicht tun. Aber schaden tut das auf keinen Fall.
(Ich rede hier jetzt nur vom Nano und vergleichbar - auf 8 Bit ATmega Basis)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wir haben die unterschiedlichen Varianten uns angesehen und jeweils spezifiziert.
@sidey79 , was machen die Unittests welche fehl schlagen?
* revised hardware spezific unused pins
for (uint8_t i=4;i<20;i++) { | ||
if (i != 9) pinAsInputPullUp(i); // not LED | ||
} | ||
#endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hier ist uns noch ein Fehler unterlaufen, der Arduino Nano ohne CC1101 verwendet andere Pins.
So funktioniert es wieder:
#else // Arduino Nano without CC1101
for (uint8_t i=3;i<20;i++) { // not PIN_RECEIVE
if ( i != PIN_SEND && i != PIN_LED ) {pinAsInputPullUp(i);}
}
#endif
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Die Sache mit Pin_Led leuchtet mir ein, da wir den nie initialisieren.
Pin_Send setzen wir später auf einen definierten Stand.
Ist dir bewusst, wieso das zum Problem führt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Die Sache mit Pin_Led leuchtet mir ein, da wir den nie initialisieren.
Mhmm, pinAsOutput(PIN_LED);
erfolgt gleich nach dem die Pullups der nicht angeschlossenen Pins eingeschaltet werden.
Pin_Send setzen wir später auf einen definierten Stand.
Ist dir bewusst, wieso das zum Problem führt?
Ich sehe in der output.h nicht so ganz durch, wie die Befehle umgesetzt werden.
Mir ist der Fehler aufgefallen, weil der SIGNALduino mit der alten Variante dauernd sendete.
Ich habe LEDs an PIN_SEND und PIN_RECEIVE. Die LED an PIN_SEND leuchtete dann dauernd.
pinAsOutput(PIN_SEND);
scheint offensichtlich nicht mehr das zu tun, was es soll, wenn vorher der Pullup eingeschaltet wurde.
Ich habe auch nicht verstanden, warum ich {pinAsInputPullUp(i);}
unbedingt in geschweifte Klammern setzen musste. Ohne funktionierte es nicht.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also ich habe mir das auch nochmal angesehen - mit dem Scope kann ich nicht sehen, dass die internen Pullups irgendeinen Einfluss auf das Signal haetten jedoch bringt es bei mir auch eine deutliche Verbesserung.
Ich habe ja als Fehlerursache die statische Varible in dem wait_Miso_rf() define in cc1101.h und entsprechend gefixt (den Pullrequest passe ich noch final an).
Um mal ein Gefuehl dafuer zu bekommen, habe ich den Code noch mit etwas mehr Debug versehen:
cc1101.c
void cc1101::sendFIFO(char *startpos, char *endpos) {
cc1101_Select(); // select CC1101
sendSPI(CC1101_TXFIFO | CC1101_WRITE_BURST); // send register address
uint8_t val;
for (char *i = startpos; i < endpos; i+=2) {
val = hex2int(i[0]) * 16;
val+= hex2int(i[1]);
/* DBG_PRINTLN(val); // only to debug */
sendSPI(val); // send value
}
cc1101_Deselect(); //Wait for sending to finish (CC1101 will go to RX state automatically
for(uint8_t i=0; i< 200;++i) {
if( readReg(CC1101_MARCSTATE_REV00, CC1101_STATUS) != MarcStateTx)
break; //neither in RX nor TX, probably some error
delay(1);
}
DBG_PRINTLN("waitMisoCnt");
DBG_PRINTLN(waitMisoCnt);
DBG_PRINTLN("waitMisoRfCnt");
DBG_PRINTLN(waitMisoRfCnt);
}
In cc1101.h entsprechend das Miso wait gefixt (damit es stabil laeuft, aber mal waitMisoCnt und waitMisoRfCnt fuer Statistiken rein)
#define wait_Miso() { uint8_t miso_count = 255; while(isHigh(misoPin)) { waitMisoCnt++; delay(1); if(miso_count == 0) return ; miso_count--; } } // wait until SPI MISO line goes low
#define wait_Miso_rf() { uint8_t miso_count = 255; while(isHigh(misoPin)) { waitMisoRfCnt++; delay(1); if(miso_count == 0) return false; miso_count--; } } // wait until SPI MISO line goes low
Pullups abgeschaltet (also Dein Fix), 4 mal was gesendet:
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
6
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
8
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
10
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
12
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
Was man nun hier sieht: Bei jedem Senden wurde waitMisoRfCnt stetig um 2 erhoeht, d.h. es musste 2 mal auf MISO LOW gewartet werden, was vollkommen in Ordnung ist.
Jetzt machen wir das selbe Spiel wieder mit Pullups eingeschaltet:
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
23
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
40
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
57
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
send cmd detected 2
Adding xFSK message
rearrange beginptr
SN;locating data start:E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000; end:;
msg 1/1 part 0/0 repeats 1
waitMisoCnt
0
waitMisoRfCnt
74
SN;D=E3577F24FCBCEDA9F867EFFFFF1CA880DB034312560798100000;
Nun erhoeht es sich schon um 17 bei jedem send - also stoeren die Pullups vermutlich auf die Abfallzeit des Pegels von MISO.
Man sieht hier also deutlich, dass die Pullups abzuschalten richtig ist - dennoch: sind die eingeschaltet eigentlich nicht das Hauptproblem, dauert halt etwas laenger.
Ursaechlich fuer das Problem ist nach wie vor die statische Variable in den miso waits. Man muss bedenken, wenn 255 auf 0 ist, wird immer abgebrochen.
Also mit Pullups
255, 253, 251,...,203,201,0 kaputt
Ohne Pullups
255, 238, 221, ... 51, 34, 0 kaputt
Es dauert hier einfach nur laenger.
Initial wusste ich ja nicht, was los ist und schrieb im Titel, dass ich beobachtet habe, dass es bei mir nur mal 15 klappt etwa... 255/17 = na? genau, 15 :)
src/signalduino.h
Outdated
} | ||
for (uint8_t i=14;i<20;i++) { | ||
pinAsInputPullUp(i); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hier müssen wahrscheinlich für ARDUINO_ATMEGA328P_MINICUL auch noch Ausnahmen rein.
#define PIN_LED 4
#define PIN_MARK433 A0
* revised pins for pinAsInputPullUp | hardware MINICUL
* revised PROGVERS
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ich verstehe den Ansatz nicht, Pins in der Schleife auszunehmen.
Für mich sieht das wie eine Umgehung eines Problems aus.
Warum beim Radino überhaupt keine Pins auf einen definierten Stand gebracht werden verstehe ich nicht.
Was ich verstanden habe ist, dass die Pins die anderweitig definiert sind nicht besser nicht gesetzt werden, weil da offenbar etwas schief geht.
@sidey79 Wir nehmen keine Pins raus. Es werden alle Pins welche ungenutzt sind eindeutig gesetzt. Wenn wir alle setzen, so geht das schief wie @devzero84 schon erläuterte. was willst du beim Radio anpassen? Bei dem uC sind andere Pins vom Standard genutzt (Vergleich zum Nano bsp.) was denkst du geht da schief? ich übernehme den Pr noch nicht um deine Fragen nicht zu umgehen ;) |
Ich sehe ja ein, dass hier etwas nicht funktioniert.
Eine Schleife geht bis 20. Den Ansatz, Pins anhand unserer Definitionen auszuschließen finde ich irgendwie wartbarer und leichter nachvollziehbar:
|
@sidey79 hier die Zusammenstellung mal verdeutlicht mit dem Hinweis, das beim Radino die PIN´s nur bedingt geändert werden können je nach Hardware. Deswegen haben wir die Schleifen fest nach den Pin´s aufgebaut.
Ja die gibt es. |
Wenn ihr hier durch seid und damit 2 issues geschlossen werden, kann ich den Firmwarestand dann gerne bei mir testen. |
Warum machen wir nicht eine schleife und dann ein continue je nach UC und gesetzter Variable? Ungefähr so. (Syntax ist ggf. nicht 100% korrekt)
|
* revised loop hardware unused pins (better overview)
@sidey79 |
src/signalduino.h
Outdated
|
||
// more pins´s (only on RADINOCC1101) | ||
#if not defined (ARDUINO_RADINOCC1101) | ||
if (i >= 20) { continue; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hier würde ich break verwenden, sobald wir keine Pins mehr initialisieren wollen.
Sieht für mich insgesamt jetzt stimmig aus.
Leider wird es uns ein paar Byte an Flash kosten :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wir werden uns nie in deinen Kopf denken :D Code folgt morgen wenn dir break besser gefällt.
Flash, da haben wir uns nicht einen Überblick verschafft. Die Funktion war hier wichtiger.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Break bricht die Schleife ab.
Continue führt ja nur zum Nächsten Durchlauf.
Die Funktion ist hier wichtiger ja.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Waere es im Grunde nicht besser und einfacher explizit alle Pins erstmal als Input mit Pullups zu setzen und dann spaeter, je nach Controller, die richtigen Pins auf Ausgang bzw. Eingang ohne Pullup (also MISO als Eingang, die anderen SPI Ports als Ausgang, usw.)
Letztlich sind ja gerade die Pins, die verwendet werden, bekannt ueber die jeweiligen Defines.
Dann kann man ueber die entsprechenden Namen einfach die Pins richtig setzen. Der Code sollte dann hier auch nur einmal exisitieren (wenn die Defines fuer alle Controller gleich heissen, wenn nicht, sollte man hier ansetzen).
Auch wenn klar ist, was hier in den Schleifen passiert - es ist irgendwie unleserlich und in 2 Jahren versteht das niemand mehr, ohne sich tief reinzudenken.
Daher lieber sowas:
for(uint8_t i=0; i <= MAXIONUM /* muss man je nach plattform natuerlich haben, koennte aber auch ein define werden */; ++i)
{
pinAsInputPullUp(i);
}
#ifdef CC1101
pinAsOutput(MOSI);
pinAsInput(MISO);
#else
pinAsOutput(IRGENDEINANDERERPIN)
pinAsInput(UNDDERHIERALSEINGANG)
#endif
...
(Habe gerade nicht nachgeschaut, wie die Funktionen genau heissen oder welche Pins es genau gibt - geht ums Prinzip)
Sollte - wenn die defines passen - dann fuer alle Controller passen. Weiter verfeinern ueber #ifdefs geht natuerlich.
Generell: Code wird oefters gelesen, als geschrieben.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Waere es im Grunde nicht besser und einfacher explizit alle Pins erstmal als Input mit Pullups zu setzen und dann spaeter, je nach Controller, die richtigen Pins auf Ausgang bzw. Eingang ohne Pullup (also MISO als Eingang, die anderen SPI Ports als Ausgang, usw.)
So war es ja ursprünglich im Prinzip, aber das führte zu Fehlfunktionen.
@elektron-bbs bitte mit testen. |
Ich denke fast, so könnte ein Schuh draus werden.
Beim radiono muss die 17 noch zusätzlich definiert werden sonst rutscht die noch mit durch. Das kommt aufgrund der komischen Pin´s. Werde mal weiter durchprobieren sämtliche HW. EDIT:
|
Was ich diese verdammte Arduino-Pin-Nummerierung hasse :-( Pin 17 = PB0 = RXLED - OK |
* revised code PullUp loop RFD-FHEM#211 (comment)
* revised loop pinAsInputPullUp & added doc
Was lange .... wird gut :-) @sidey79 nun wurde die Schleife nach erneutem Documentationsvergleich und Ergänzung der Quellen für "finish" beziffert. Wenn dieser PR übernommen wurde, wäre es sehr Hilfreich ein Release zu erstellen und das fehlerhafte Release https://github.com/RFD-FHEM/SIGNALDuino/releases/tag/3.5.0-dev%2B20201221 zurück zu ziehen. (bitte auf das Releasedatum achten und bitte dann die Versionsnummer aus der PROGVERS-Variable nehmen ---> somit kommt man nicht durcheinader) |
src/signalduino.h
Outdated
// radino --> end on Pin 29 (CCM_radino_CC1101.pdf | sources In-Circuit -> pins_arduino.h) | ||
for (uint8_t i=2 ; i<=29;i++) { | ||
#ifndef ARDUINO_RADINOCC1101 | ||
if (i>=23) break; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So kommen wir aber nicht bis einschließlich Nr. 23. Ich denke, break darf erst erfolgen, wenn > 23.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Deine Annahme stimmt. Wenn für Nr. 23 noch der PullUp geschaltet werden soll, dann muss da >23 stehen
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Da unterlief mir ein C&P Fehler weil der Magen knurrte :-D
fertig und korrigiert
* Make a 3.4 Branch * SIGNALDuino.ino | SIGNALESP.ino Fixes default parameter definition * Implement a Wifi reconnect event to restart the telnet server (#120) * SIGNALESP.ino Implement a Wifi reconnect event to restart the telnet server Set ArduinoJson Version to the desired one * commands.h fixed output of version after ping response * fix names - fix cc1101 name * FIX: value of success must be saved before calling reset() success must be saved before calling reset() because reset() will set it back to FALSE * [SIGNALESP] FIX: Min. timer time for cronTimer is 1ms if duration is greater than maxPulse it could happen that the timer time for the cronjob timer becomes negative (or a big value if it is unsigned) * NEW: Settings if LED_BUILTIN on WEMOS boards as PIN_LED * baseline for plattformio * Changes to be compatible with plattformio * signalesp.h prevent crash if first char is a linebreak or # * commands.h fix unsupported command output which caused a crash * Arduino IDE compatibility Added sym links to project files to support arduino compatible layout * Linked ArduinoJson per file * platformio.ini corrected exclude for arduino-ide compatible directory * corrected CMakeLists.txt for testproject added testproject to plattformio.ini (does not work) * build.sh updated build config and travis config for arduino-ide dir structure * change travis build config * clear links * modified symlinks to be relative * remove some symlinks to add again * added symlinks again * rename dir * removed file to link later * added symlinks * build.sh deploy.sh executable flag added * added missing timerone header * added missing cpp file * fix compile * travis changed arduino core version to 2.6.3 * travis update arduino cmd * fixed arduino cmd * added missing symlinks * cc1101.cppAdded wait_miso call after select to repair factory reset * signalesp.h fixed crash with ; as command * signalesp.h modified connection handling commands.h added dumpEEPROM when doing factory reset * SimpleFIFO.h enqueue: ICACHE_RAM_ATTR added to support usage via interrupt * Version 3.4.0-dev+20200216 * platformio.ini added nanocc1101 and nanocc1101@debug * send.h fix unexpected serial print until null termination char is found * platformio.ini Compile definition for serval boards added * send.h cleanup some code * signalDecoder/src/signalDecoder.cpp prevents crashes * Update some compile errors * Update platformio.ini * added different bootloaders * revised HW names * revised minicul 8/16MHz * added monitor_port / upload_port variable to define on start * Update cc1101.cpp * fix - no compile in Arduino IDE from nano, promini, esp8266 without cc1101 but with DEBUG flag - no compile in PlatformIO from nano, promini, esp8266 without cc1101 but with DEBUG flag * Update signalduino.h * revised PROGVERS * Update signalduino.h * wrong date from PR * Update platformio.ini * revised ESP32 config to upload and view monitor * Update platformio.ini * revised ESP32 device useful note * duplicate ESP32 device for DEBUG * commands.h add 0x17 chipid for cc1101 * Update commands.h Fixes syntax, corrected chipid #133 * ESP32 support (#134) * revised for ESP32 (#130) platformio.ini * revised * remove comments & sort devices * remove @lastest comment from esp8266 compile_config.h * added PIN´s for ESP32 * revised comments signalesp.h * revised code for ESP32 (timings, WiFi.events) * fix code line event signalduino.h * revised date README.md * added doc * Update .travis.yml - ESP32 compile (#137) * Update .travis.yml * option to compile ESP32 11d8ece * Update .travis.yml * option to compile ESP32 without cc1101 11d8ece * Maple Mini (stm32f103cbt6) support (#136) * Hardware stm32f103cbt6 integrated * code and config adapted to compile with and without cc1101 * Update dev r3.4 with PlattformIO Updates incl STM Support (#138) * signalesp.h prevent crash if first char is a linebreak or # fixed crash with ; as command modified connection handling * commands.h added dumpEEPROM when doing factory reset fix unsupported command output which caused a crash add 0x17 chipid for cc1101 * Arduino IDE compatibility Added sym links to project files to support arduino compatible layout * Linked ArduinoJson per file * platformio.ini corrected exclude for arduino-ide compatible directory * corrected CMakeLists.txt for testproject added testproject to plattformio.ini (does not work) * build.sh updated build config and travis config for arduino-ide dir structure * travis changed arduino core version to 2.6.3 * cc1101.cpp Added wait_miso call after select to repair factory reset * SimpleFIFO.h enqueue: ICACHE_RAM_ATTR added to support usage via interrupt * send.h fix unexpected serial print until null termination char is found cleanup some code * signalDecoder/src/signalDecoder.cpp prevents crashes * Update some compile errors * ESP32 support (#134) * Maple Mini (stm32f103cbt6) support (#136) * Update platformio.ini (#141) * added radinoCC1101 to compile * revised comments * testet again all PIN´s and compatibility (ICT radino is based on Arduino Leonardo & Micro) * fix - strobe commands register (#140) * Update cc1101.cpp * fix strobe commands register * Update / fix deploy travis config (#142) * travis.yml updated yml for successful deployment of release fixed some yaml warnings on travis * extension of xFSK mode (#145) * xFSK extension extra_script.py * creation file for easy file generation (firmware) platformio.ini * extension of hardware and special debug versions any files: bitstore.h, cc1101.cpp, cc1101.h, commands.h, compile_config.h, functions.h, output.cpp, output.h, send.h, signalDecoder.cpp, signalDecoder.h, signalSTM.h, signalduino.h, signalesp.h * extension of xFSK mode (send & receive) * change notation of calls due to excessive memory consumption (smaller alternative is used) * memory comparison completed -> optimizations for the program sequence - processing on weak hardware runs faster, example: radino, nano - more memory space of the processors * revised debug texts * create symblink * Update signalDecoder.cpp * revised comment for a clear statement * Update signalDecoder.h * added comments * added SIGNALduino project query added for linkage * Update output.cpp * added SIGNALduino project query added for linkage * rename variable and revised comments * revised comments to better understanding * optimized code / string class / xFSK send call cc1101.cpp * revised string class in void sendFIFO * optimized void sendFIFO cc1101.h * revised call void send.h * optimized call xFSK to send * Update output.cpp * revised size comments * Update signalDecoder.h * added comments * macro SDC_PRINT, SDC_WRITE, SDC_PRINTLN inserted to test * Update compile_config.h * Update compile_config.h * revised code signalDecoder.cpp * MSG_PRINT | DBG_PRINT write back to SDC_PRINT * optimized some lines output.cpp * revised comments * back to big memory size functions signalDecoder.cpp * back to big memory size sprintf to save ready compile platformio.ini * revised some comments to view result * Update signalDecoder.cpp * back to big memory size sprintf to save ready compile * Update signalDecoder.cpp * back to big memory size sprintf to save ready compile * Update platformio.ini * revised comments size & version * Update signalDecoder.cpp * fix not compile with define DEBUGDECODE (wrong parameter, macro "SDC_WRITE" passed 2 arguments, but takes just 1) * Update signalDecoder.cpp * fix not compile with define DEBUGDECODE (in POI | error: initializing argument 1 of .... ) * Update platformio.ini * sort hardware for better overview * revised sketch size comments * Update compile_config.h * Update output.cpp * for test * delete output.cpp * delete output.cpp (UNITTEST have no link to compile_config.h) * added functions in some files * update code after REVIEW send.h * #145 (comment) * remove omment compile_config.h * #145 (comment) * revised PROGVERS variable cc1101.cpp * corrected indentation signalDecoder.h * #145 (comment) * comment changed * create output.cpp for functions in project cc1101.cpp * transfer function MSG_PRINTtoHEX functions.h * transfer function DBG_PRINTtoHEX * create symblink * fix output ESP32 & ESP 8266 (#148) * fix output ESP32 & ESP 8266 - fix, no calling of commands possible * dev-r3.5_xFSK_tab_comments - revision indentation (#149) * Update signalDecoder.cpp * revised indentations * revised comments * Update signalDecoder.h * revised comments * Update compile_config.h * revised version * sketch optimized for hardware with little flash (#150) * sketch optimized for hardware with little flash * platformio.ini - revised sketch size comments * signalesp.h - increase writeBufferSize * compile_config.h - revised PROGVERS - revised comments * signalDecoder.h - added new function * signalDecoder.cpp - added new functions myitoa (selfmade alternative to non standard itoa function c++) - remove some sprintf and revised to alternate better sketch size function SDC_PRINT - remove old comments - added function SDC_PRINT_intToHex / nibble_to_HEX - limit array * fix writeBufferSize for ESP * fix writeBufferSize for ESP (#151) * CI Jobs auf Gihub actions übertragen (#152) * .github\workflows\unittest.yml Added unittest workflow Made scrips executable and renamed travis ci yaml file Use more recent (latest supported rapidassist) version added all boards and combinations to workflow excluded some combinations Added github actions unittest workflow, which tests and uploads to a created relese * Compile micro8 mhz (#155) * .github\workflows\unittest.yml - added radino board with incicuit board files - Added dependency between unittest and deploy jobs to run in sequence - renamed firmware to be compatible with flash command from module * Update README.md Updated badge in readme * Codequality check via Github Actions (#154) * Create codeql-analysis.yml * Delete build.sh * Delete deploy.s * created .github\actions\arduino-cli\action.yml move common steps to prepatr arduino-cli into a composite step and refenrence on it in the workflows: - workflows/codeql-analysis.yml - workflows/unittest.yml * Upload compiled firmwares always as artifacs (#159) Artifacts are always placed at github actions to get the compiled firmware files * fix-esp8266-firmware-debug (#158) * ./github/unittest.yml - Removed debug options for compiler (esp8266) #157 - Upload compiled firmwares always as artifacs (#159) - generate a comment output with the flash and ram usage - changed submodule checkout to checkout action * unittest.yml run comments only if this is a pullrequest * Update action.yml spell fix * Update compile_config.h (#156) * Update signalduino.h Add all pins as input pullup * Fix wait_Miso defines in cc1101.h (#213) Static variables are only initialized once so the implementation only worked for a total of 255 iterations. After that, functions like cmdStrobe(), readReg() or writeReg() return immediately if the MISO pin is high. The variable miso_count is now out of while's scope and therefore no longer needs to be static. * Fix - GFSK & nano crash (#211) * dev-r3.5_xFSK Bugfix GFSK - Allows other modulations than ASK / OOK and 2-FSK to be received. * fix nano328 send crash - revised PROGVERS - pins excluded to avoid crash - revised comment & changed pins - revised code PullUp loop #211 (comment) * Fixes a endless loop in mcdecoder (#228) * CMakeList.txt - Added policy for new cmake versions * win32arduino - updated to newest version * test.cpp - Added test to find endlesslopp * signalDecoder.cpp - try to avoid var overflow - modify if conditions checking * signalDecoder.cpp - Fix not stopping early enough * signalDecoder.cpp - fix to last exit for shorts * signalDecoder.cpp - revert mpi and mpiplusone checking * install_rapidassists.sh - Update to version 0.10.0 to be compatible with win32arduino * Update codeql-analysis.yml , platformio.ini (#244) * Update codeql-analysis.yml * Update platformio.ini - remove old event - update information - comment out hardware bootloader_v2 due to errors in the core * Update unittest.yml * Update signalDecoder.cpp (#245) * Update signalDecoder.cpp - fix, code cannot compile with debug option DEBUGDECODE * Update codeql-analysis.yml - use actions checkout also for submodules * LED confirms receipt of FSK (#251) Pin reception works at FSK inverted to OOK. * Update platformio.ini - useful hints added Co-authored-by: HomeAutoUser <[email protected]> Co-authored-by: uwekaditz <[email protected]> Co-authored-by: devzero84 <[email protected]> Co-authored-by: Udo <[email protected]>
(Das Problem mit dem ESP32 ist ein Anderes)