This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

How to load data onto registers?

Other Parts Discussed in Thread: LMX2492

I am using SPI commands to load data onto the various registers of the LMX2492 PLL. But I am unaware of the exact way to do this. I have assumed that it is done as follows:

If I want to load the data 0x8 onto register 0x30 then the 24-bit SPI command should be    0b0000 1000 0000 0000 0001 1110  where the first 0000 1000 represent the 8-bit data 0x8  and the rest of the bits (i.e. 0000 0000 0001 1110) represent the 16-bit register address (for register 30). Can anyone confirm that this is the correct way of loading data onto the registers? Or should the positions of the data and the address be switched?

  • Hello Edward,

    The first 16 bits of the register are the address, followed by the next 8 bits of data. This is stated in the Datasheet, as shown below. 

    Register 0x30 is reserved, so you wouldn't write to this register. Register 0x1E (Register 30) can be written to and is the Charge Pump Monitor's low threshold value.

    Please let me know if you still do not have an understanding.

    -Joe

  • section 7.7 of the D/S shows the timing diagram for serial data transaction.

    Each register is 24 bit long: [R/W , A14:A0 , D7:D0]. W==0 and R==1. Serial communication is MSB first meaning the first bit communciated in time is the R/W bit...

    Be careful to identify registers in the desired base. As pointed out 0x30 (hexadecimal) is a reserved register.

     

    Regards,

    Simon.

  • Thanks for the responses. I used Register 0x30 only as an example for this question. According to what I understand from your responses, the sequence of SPI writes to the PLL in this scenario should be "0000 0000" then "0011 0000" which comprise the address 0x30 including the R/W bit which is 0 in this case. The last SPI write should be "0000 1000" which is the data 0x8. Please correct me if I am wrong.
  • you are correct. best regards, Simon.