Skip to content
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

setTCXO needs to be called before calibration is run #29

Open
Celliwig opened this issue Sep 27, 2024 · 2 comments
Open

setTCXO needs to be called before calibration is run #29

Celliwig opened this issue Sep 27, 2024 · 2 comments

Comments

@Celliwig
Copy link

In the class SX126X, 'setTCXO' is called after 'config' for both 'begin' and 'beginFSK'. 'config' runs the calibration command. The TCXO needs to be configured before calibration is run. so currently you have:

        state = self.config(....)
        ASSERT(state)

        if tcxoVoltage > 0.0:
            state = self.setTCXO(tcxoVoltage)
            ASSERT(state)

This needs to be changed to:

        if tcxoVoltage > 0.0:
            state = self.setTCXO(tcxoVoltage)
            ASSERT(state)

        state = self.config(....)
        ASSERT(state)

This led to a loss of several decibels going by the returned RSSI.

@ehong-tl
Copy link
Owner

Hi @Celliwig

You probably right.

Can you help test it again from the test branch?
https://github.com/ehong-tl/micropySX126X/tree/test

Currently I don't have the hardware in hand for testing.

@Celliwig
Copy link
Author

Sorry, I can't test it I'm afraid. Actually using this library as a basis for a Python implementation on a RPi (I have weird requirements in regards to handling CS lines so used this, rather than some other implementations).

Sorry about that...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants