Skip to content

LLCC68 #2

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

Closed
remi206 opened this issue Apr 19, 2025 · 5 comments
Closed

LLCC68 #2

remi206 opened this issue Apr 19, 2025 · 5 comments

Comments

@remi206
Copy link

remi206 commented Apr 19, 2025

Will it work with the LLCC68 chip?

@swoboda1337
Copy link
Owner

I have never tried the LLCC68 but it seems like it should. Basically the same as the sx1262

@remi206
Copy link
Author

remi206 commented May 20, 2025

Hello. I was able to run the E220-900MM22s module built on the LLCC68 chip. But it only worked after editing the code sx126x.cpp, line 161: (if (strncmp(this->version_, "SX126", 5) != 0) {) on (if (strncmp(this->version_, "LLCC68", 5) != 0) {). As I understand it, this is a chip check, can add a check to the code for either SX126 or LLCC68?

@swoboda1337
Copy link
Owner

swoboda1337 commented May 20, 2025

Ah right.

There is also a hw_version enum:

          cv.Required(CONF_HW_VERSION): cv.one_of(
                "sx1261", "sx1262", "sx1268", lower=True
            ),
  if (this->hw_version_ == "sx1261") {
    if (pa_power == 15) {
      uint8_t cfg[4] = {0x06, 0x00, 0x01, 0x01};
      this->write_opcode_(RADIO_SET_PACONFIG, cfg, 4);
    } else {
      uint8_t cfg[4] = {0x04, 0x00, 0x01, 0x01};
      this->write_opcode_(RADIO_SET_PACONFIG, cfg, 4);
    }
    pa_power = std::max(pa_power, (int8_t) -3);
    pa_power = std::min(pa_power, (int8_t) 14);
    buf[0] = 0x18;  // max 80 mA
    this->write_register_(REG_OCP, buf, 1);
  } else {
    uint8_t cfg[4] = {0x04, 0x07, 0x00, 0x01};
    this->write_opcode_(RADIO_SET_PACONFIG, cfg, 4);
    pa_power = std::max(pa_power, (int8_t) -3);
    pa_power = std::min(pa_power, (int8_t) 22);
    buf[0] = 0x38;  // max 140 mA
    this->write_register_(REG_OCP, buf, 1);
  }

can also add llcc68 there, I guess it should do the same thing as sx1262?

Do you want to submit a PR for this? I can merge it. If not I can do it sometime.

@remi206
Copy link
Author

remi206 commented May 20, 2025

I specify SX1262 in the settings.

@remi206
Copy link
Author

remi206 commented May 20, 2025

Take your time . You can do this later .

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