fix agc reset on SX126x, SX1276 & LR11x0 chips#1743
fix agc reset on SX126x, SX1276 & LR11x0 chips#1743weebl2000 wants to merge 7 commits intomeshcore-dev:devfrom
Conversation
|
what boards do you think the AGC doesn't work on? On a V4, I've been watching closely at a terrible site I have with 945Mhz STL microwave and turned off agc.reset.interval and then back on. I think it "might" be working but not sold on that. |
I have reports that it gets stuck on V3 and T114, as well. My DIY node based on ESP32-S3 and E22 900M30S gets affected, too. |
|
I figured out why I'm not seeing this AGC problem. Its had me stumped on and off for a couple days. I set my repeaters to Zero on the int.thresh 0 Once I changes this back to default, yep, I can watch my noise floor eventually hit -120 on my V4 and be of course very desensitized. I tried @weebl2000 test firm builder and in fact it is fixed. also, no current spike on AGC rest every 12 seconds that mine is set for the test. |
840d1b7 to
ce05fed
Compare
|
@weebl2000 Your test firm still has the 22 second powersaving delay. Can you update your base 1.13 firm with that fix? I'm testing your AGC fix now but since I'm in a busy area, I'm never sleeping and its draining battery pretty good in our rain for days weather. |
the fixagcreset is up-to-date with the meshcore/dev branch. Are you building fixagcreset branch? https://mcimages.weebl.me/?commitId=fixagcreset what branch is the 22 second powersaving delay branch? I can merge that one with this one for you so you can test the combination. |
|
@weebl2000 the 22 second delay showed up in 1.13 and @IoTThinks Kevin made a hotfix on his github. They also also have powersaving13 as well. I've been testing it on 2, V4 boards and its awesome. It is not merged into the dev branch at this time. If you could do something temporary with ether the hot fix, that would allow me to test at 3 tower sites tomorrow for work that I'm taking an insurance agent to. All easy access repeaters in town. The hot fix on easy sky mesh is under Firmware, Testing, PR-1687, : heltec_v4_repeater-002878e.bin and I have that running in addition to stock 1.13 and its perfect. I'm guessing that would be the simplest? All 3 of these sites go numb -120 in just under 24 hrs and this AGC reset fix should be golden to find out really quick! |
|
@weebl2000 22-second delay in PowerSaving is likely the OLED issue on Heltec v4 in the current MC 1.13 (main and dev). It should not be related / affected to your PR. @towerviewcams The fix for 22-second powersaving delay in PowerSaving 13 is included in the bellow pending PR too. |
try this one: https://mcimages.weebl.me?commitId=agc-tower it includes this PR + #1687 + #1569 |
|
@weebl2000 Trying right now! |
|
@weebl2000 Wow! what a difference! I'm slamming 2 boards at the same time, with 2 different companions and 2 ios phones. So im connected at the same time. #1 V4 has the AGC/pwr save fix. This PR and 1687 and 1569 I'm slamming them both side by side and the AGC reset works every time. back down to -104 ish......... #2 is sticking and not resetting. Sometimes its slow, and others not. I'm sure if I let this run for a day we would see. -Field Test @IoTThinks, Keven, I know you told me on FaceBook that you haven't seen where you need to reset. Let me test this and I'll know very quickly. I'm sitting next to over 1 megawatt of power and 4 cellular companies all on my 800ft tower that I manage. |
|
90 mins in and holding -98 to -102 on noise floor readings. This is exciting so far!!!! |
|
The FAQ may need to be updated. |
|
@towerviewcams Well, 1MW interference. Then it makes sense. So your agc reset interval is 4? Besides the noise floor number, have you observed if the repeaters can receive more packets or better SNR...? I would love to have lower noise floor and better RX too. My noise floor for Heltec v3s with 3 and 5dbi is -97 to even -77 recently. |
My AGC reset is 8. Everything has been working great. Prior to this reset working properly, decoding packets was very intermitant and required a very strong signal as noise floor would increase to -86 or so and remain there. Now, I'm holding -97 to -102......I do see a suddon drop to -86 and then it pops back up with the AGC reset. So far so good! |
|
Today, I'm going to OTA this at another location that has 600,000 watts broadcast noise and 3 cellular tenants. My noise floor here drops slowly to -91 and I was going to do the LNA bypass. Not now, lets try this! Update soon! |
|
@towerviewcams Great. This symptom seems to happen to many boards including RAK4631. Not just Heltec v4. |
|
Now running this on another V4 in the field next to 600,000 ERP broadcast transmitter and AGC is working nicely. Taking my Wio down to power -9 and can trace now just fine! Before, my noise floor was holding -89 and could not. Let this run for rest of the day and I'll know for sure. now im at a very nice -96-98 ish. reset rate 8 seconds. If works great I'm going to set my reset timer to 16 on both tests. then more as time goes on to find the sweet spot where it starts to drop before reset |
80710c9 to
3f59f9d
Compare
|
I've tested this on a V3, works fine, just as well as with V4. |
80710c9 to
7f9107b
Compare
|
@towerviewcams I have tested with my Heltec v3 with 3dbi antenna for half a day. MC 1.13: This branch: (commit dbb739) All values for agc.reset.interval give the same noise floor.
|
@IoTThinks My noise is broadcast at 580Mhz so its far away from 910Mhz but a HUGE signal source for sure. I'm glad your seeing good results. Cellular is much closer to 910mhz and will get through your filter easier. So it doesn't surprise me. |
|
More then 32 hours and running perfectly on V4 still using the "agc-tower" firm build. Fantastic @weebl2000 Just as a thought, @IoTThinks Keven, will you please please put this into a test Powersaving13.1 beta test? Lets consider putting this together? |
|
@weebl2000 @IoTThinks BIG UPDATE So the AGC-Powersave that has the three merged PR and the quick sleep does have serious login responsiveness issues. @beachmiles is totally correct. So I have pulled that from my tests that ran for 24hrs. -done there The dev_plus has a 16 second delay before power saving kicks in. current is 47mA and then will drop down to 11mA after the delay. I've done allot of testing ALLOT after it goes to sleep and it responds every single time, quickly! So, how can we get this delay down and still have it respond? That would then be perfect. In busy areas we may never sleep. -The dev-plus also has the hardware delay, and I have 3 repeaters LOS to my house that are high level, and I must say this is just fantastic. It checks briefly to see if there is on air traffic before it transmits. very good. |
Then later, the repeater should sleep instantly, right?
What is your agc setting and how many hops to do remote login?
Via ping or repeat, right? |
|
@weebl2000 I remember you have LBT in dev_plus, right? If the repeater postpones a repeat or CLI response and they are counted in hasPendingWorks(), powersaving will wait and skip sleeping until hasPendingWorks() is false. By right it should be ok. Or may be CLI response is not counted in hasPendingWork()? |
|
|
Let me check the source code of agc powersaving and dev-plus. For PowerSaving 13, I still can remote manage via 5 nearby hops. I guess int.thresh and LBT has some impacts when delaying the response due to air activity. Do you set int.thresh? |
@IoTThinks int.thresh 10 power saving 13 does not have the AGC reset bug fix. it will clamp down to -120 within 24 hrs |
@towerviewcams NRF52 PowerSaving broke my ESP32 PowerSaving. That's why the repeater needs more time to sleep. This has been fixed in PR #1687 |
|
@towerviewcams you can try this one, perhaps it works - I haven't tested yet: https://mcimages.weebl.me/?commitId=agc-powersave2 it contains this PR, #1600, #1569, #1653 and #1687 with a fix hopefully. |
|
@towerviewcams I have tested just now the agc-powersave vs. PowerSaving 13. I will check the AGC source code tomorrow. |
@weebl2000 @IoTThinks something still wrong with wake up to receive first packet or something to that effect. |
I have that issue on pretty much all of my remote repeaters, even using the standard release firmwares. The only ones that ever connect first try are direct connects. Anything that is flood requires at least two tries. |
This is sitting here in my work bench. I rolled back to previous devs and also stock 1.13 and all back to normal. So i know its new and confirmed |
|
Logging in and the "Request status" button works ~90% of the time on AGC-Powersave with powersaving on or off. The issue seems to not be related to powersaving on or off, not sure if something under the hood is keeping powersaving on even if I have it off, etc. |
|
Let me merge the AGC of this PR to PowerSaving 13.1 (Based on MC 1.13 main branch) today. |
|
@towerviewcams @terminalvelocity23 This PowerSaving 13.1 based on MC 1.13 MAIN + this PR. The bin files and source code are at https://github.com/IoTThinks/EasySkyMesh/releases/tag/PowerSaving13.1 I'm testing too. If fine, I will deploy PS 13.1 to all newly repeaters too. |
…x stuck noise floor at -120 dBm. PR meshcore-dev#1743 By https://github.com/weebl2000
This is great news Kevin! I'll get this programmed up now just before bed and check in the morning after it runs all night. Thanks friend! |
|
A friend discovered a bug affecting PR1687 PowerSaving in dev branch. This is the PR to fix. Well, it is good as we can use both PowerSaving and AGC reset. |
@IoTThinks Are you saying that that firm above that you tagged me in that I started testing has the bug? or just the dev branch that is NOT part of the above link with Powersaving 13.1 ?? UPDATE- Update2- |
1. warm sleep 2. wake to stdby 3. Calibrate(0x7F) to reset all internal blocks 4. re-apply DIO2 RF / boosted gain & register patch to make sure everything is as it was
Similar to SX126x but simpler.
8771761 to
9bae9d0
Compare
|
I think this PR is good to be merged. |






fixes #1716- see discussion there for initial test results
fixes #1209
I've referenced SX1262 datasheet to implement the calibration reset.
For LR1110 similar implementation, the 'AGC' is completely black boxed behind firmware so you can only reset it by resetting registers.
LR1110 datasheet page 9 section 1.2.1 states:
•Air interface fully compatible with the SX1261/2/8 family
Also see LR1110 user docs
So reset is very similar.