Skip to content

Commit

Permalink
Merge PR #209 Let _RF_CALIB adapts to multiple partitions
Browse files Browse the repository at this point in the history
  • Loading branch information
ligenxxxx committed Aug 5, 2024
1 parent 9bb296d commit 29adc3b
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/rom.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ void CalibProc() {
DM6300_SetPower(RF_POWER, RF_FREQ, pwr_offset);

I2C_Write8_Wait(10, ADDR_EEPROM, RF_FREQ * (POWER_MAX + 1) + RF_POWER, table_power[RF_FREQ][RF_POWER]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_TAB2 + RF_FREQ * (POWER_MAX + 1) + RF_POWER, table_power[RF_FREQ][RF_POWER]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_TAB3 + RF_FREQ * (POWER_MAX + 1) + RF_POWER, table_power[RF_FREQ][RF_POWER]);
break;

case 'c':
Expand Down Expand Up @@ -120,6 +122,16 @@ void CalibProc() {
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC_IL, rxbuf[3]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC_QH, rxbuf[4]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC_QL, rxbuf[5]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC2 + EEP_ADDR_DCOC_EN, 0x00);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC2 + EEP_ADDR_DCOC_IH, rxbuf[2]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC2 + EEP_ADDR_DCOC_IL, rxbuf[3]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC2 + EEP_ADDR_DCOC_QH, rxbuf[4]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC2 + EEP_ADDR_DCOC_QL, rxbuf[5]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC3 + EEP_ADDR_DCOC_EN, 0x00);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC3 + EEP_ADDR_DCOC_IH, rxbuf[2]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC3 + EEP_ADDR_DCOC_IL, rxbuf[3]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC3 + EEP_ADDR_DCOC_QH, rxbuf[4]);
I2C_Write8_Wait(10, ADDR_EEPROM, EEP_ADDR_DCOC3 + EEP_ADDR_DCOC_QL, rxbuf[5]);
break;
}
break;
Expand Down

0 comments on commit 29adc3b

Please sign in to comment.