FORUM

LLCC68 TxDone problem

We sending Data from standard LLCC68.c library. TxDone is not getting Set.
Code below:
Intialization:
uint16_t irq_mask = llcc68_irq_masks_e::LLCC68_IRQ_ALL ;
// setting irq mask and di01 mask
llcc68_set_dio_irq_params(&llcc68, irq_mask, irq_mask, 0, 0);

    llcc68_get_irq_status(&llcc68, &irq_status); 

…Transmit Code :
while(1) {
llcc68_write_buffer(&llcc68, 0, buf, len);

 llcc68_set_tx(&llcc68, 500);

delay(500);

llcc68_get_irq_status(&llcc68, &irq_status); 

printf("tx_irq_status: %04X\n",irq_status);

if (irq_status & (llcc68_irq_masks_e::LLCC68_IRQ_TX_DONE)){res=RR_OK; break;}

cnt++;

if(cnt>3) break;

};
TxDone is not getting Set. Same is confirmed on the SPI Bus

Hello! Can you please share the configuration applied to the chip (packet type, RF frequency, packet and modulation parameters, etc.)?

            llcc68_set_pkt_type(&llcc68, llcc68_pkt_types_e::LLCC68_PKT_TYPE_LORA);
	llcc68_set_rf_freq(&llcc68, 868000000L);
	llcc68_cal_img(&llcc68 ,  868000000L);
   	pa_params.hp_max = 2;          // output power
   	pa_params.pa_duty_cycle = 2;   // is +14 dBm		
	pa_params.device_sel = 0;
	pa_params.pa_lut = 1;
	llcc68_set_pa_cfg(&llcc68, &pa_params);

	llcc68_set_tx_params(&llcc68, 14, llcc68_ramp_time_e::LLCC68_RAMP_3400_US);

	mod_params.bw = llcc68_lora_bw_e::LLCC68_LORA_BW_125;
	
	mod_params.sf = llcc68_lora_sf_e::LLCC68_LORA_SF5;//5
	mod_params.cr = llcc68_lora_cr_e::LLCC68_LORA_CR_4_6;//Если
	mod_params.ldro = 0;
	Using llcc68.c Version 1.0 Driver
             
            llcc68_set_lora_mod_params(&llcc68, &mod_params);

	pkt_params.crc_is_on = true;
	pkt_params.invert_iq_is_on = false;
	pkt_params.preamble_len_in_symb = 100;
	pkt_params.header_type = llcc68_lora_pkt_len_modes_e::LLCC68_LORA_PKT_EXPLICIT; 
	pkt_params.pld_len_in_bytes = 16;
	llcc68_set_lora_pkt_params(&llcc68, &pkt_params);
    llcc68_set_buffer_base_address( &llcc68,  0, 128 );
    llcc68_set_lora_sync_word( &llcc68, 0x12); //0x34
     llcc68_set_dio2_as_rf_sw_ctrl(&llcc68, true );

I have done a Trace of the Signals.
Attached.

Tried with Latest LLCC68 Driver 2.0.1 from Github… Same issue… I am currently debugging the problem.

Looks like having multiple problems. SPI signal having extra Signals (Should be Opcode +3 max) .other than what is given in Specs and 2nd Data in MISO is coming as AC AC… (Looks like a Driver LLCC68 driver BUG !).

ISSUE RESOLVED :

  1. Tx Done : Issue resolved by Changing the llcc68.c Driver code…
    system was working file if clear IRQ was done as per spec and DIO was going down.

Change done :
LLCC68_SIZE_GET_IRQ_STATUS = 4, // Changed to 4 from 2

There is a issue in all GET and data is not getting moved to buffer.

Hope above is helpful for all.

  1. Additional SPI data (System is automatically. Triggering CS had to make code change to avoid multiple SPI to single SPI transaction to get Data from SPI). Specs clearly says that CS should be trigged only after Data is sent or received. !

Hi @sramakrishnas.

The way the HAL function sx126x_hal_read is defined is the following:

  1. Write command_length bytes from command buffer
  2. Read data_length bytes from data buffer

It is done in a way that the driver does not need to create an intermediate buffer. The HAL writes directly the data read from the chip in the buffer provided by the user.