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.

LMP90100 GPIO healthiness check

Other Parts Discussed in Thread: LMP90100

Hi...

I am using LMP90100 in my application.

Registers reading after configuration are not showing the actual data whats written.

And also GPIO pins as outputs pulled to high also not giving high at output.

So please help me how to check the healthiness of LMP90100.

 

Thank you in advance..

 

  • Hi Sravanthi,

    there isn't a specific command to check the healthness of the LMP90100.

    If you are not reading what you have programmed it is possible that you haven't written inthe right way.

    The test you have done with the GPIOs is good to check the rightness of your writing command.

    Please refer to the example codes at the following link to check the rightness of your commands.

    http://www.ti.com/lit/zip/snac029

    regards,

    Domenico

  • Sir...

    The sequence is successful for some other ICs.

    This is the sequence I am following for LMP90100.

    Please check

    // GPIO_DIRCN 0x0E register; pins as output

    //URA setup

    I2CMasterSlaveAddrSet(I2C1_MASTER_BASE,0x28, false);

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x01); //FID to write through bridge
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_START);

    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE, 0x10); //Write address in URA setup
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_CONT);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x00); //URA address
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }

    while(I2CMasterErr(I2C1_MASTER_BASE)!=0)
    {
    UARTprintf("I2C error in URA is %u \n",I2CMasterErr(I2C1_MASTER_BASE));
    }
    SysCtlDelay(6666);

    //LRA setup
    I2CMasterSlaveAddrSet(I2C1_MASTER_BASE,0x28, false);

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x01); //FID
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_START);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE,0x0e); //LRA
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_CONT);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE,0xff); //Register data
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    while(I2CMasterErr(I2C1_MASTER_BASE)!=0)
    {
    UARTprintf("I2C error in LRA finish is %u \n",I2CMasterErr(I2C1_MASTER_BASE));
    }
    SysCtlDelay(6666);


    //GPIO pins as output ends**

    //writing to GPIO_DAT register ;

    //URA setup

    I2CMasterSlaveAddrSet(I2C1_MASTER_BASE,0x28, false);

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x01); //FID to write through bridge
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_START);

    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE, 0x10); //Write address in URA setup
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_CONT);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x00); //URA address
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }

    while(I2CMasterErr(I2C1_MASTER_BASE)!=0)
    {
    UARTprintf("I2C error in URA is %u \n",I2CMasterErr(I2C1_MASTER_BASE));
    }
    SysCtlDelay(6666);

    //LRA setup
    I2CMasterSlaveAddrSet(I2C1_MASTER_BASE,0x28, false);

    I2CMasterDataPut(I2C1_MASTER_BASE, 0x01); //FID
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_START);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE,0x0f); //LRA
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_CONT);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    I2CMasterDataPut(I2C1_MASTER_BASE,0xff); //Register data to pull the pins high
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))
    {

    }
    while(I2CMasterErr(I2C1_MASTER_BASE)!=0)
    {
    UARTprintf("I2C error in LRA finish is %u \n",I2CMasterErr(I2C1_MASTER_BASE));
    }
    SysCtlDelay(6666);


    //writing to GPIO_DAT register ends**

    So can you help to find the mistake in this..

    Thank you

  • Hi Sravanthi,

    I think that a possible error is the following if I have well understood your code:

    I2CMasterDataPut(I2C1_MASTER_BASE,0xff); //Register data
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))

    .....

    I2CMasterDataPut(I2C1_MASTER_BASE,0xff); //Register data to pull the pins high
    I2CMasterControl(I2C1_MASTER_BASE,I2C_MASTER_CMD_BURST_SEND_FINISH);
    while(I2CMasterBusy(I2C1_MASTER_BASE))

     

    you are writing a "1" in a reserved bit. In the Datasheet we say that reserved bit must be set to "0" unless otherwise specified.

    regards,

    Domenico

  • Sir....

    As per your suggestion...I tried with reserved bit as zero. But output value on GPIO in not changing.

    So please can you help me in this issue.

    Thank you in advance...

  • Clearly telling about problem....

    I am using I2C bus in my application.

    So I2C bus to SPI bridge I used SC18IS602B.

    To this bridge LMP90100 is the only slave.

    LMP90100 CSB is connected to ground. Is it any problem?

    So selecting any slave (means any Function ID of the bridge) will have any problem related to non functioning of the LMP90100.

    If not why this GPIO configuration is not successful.

    Reading of the configuration of any register is not showing exact data.

    So please help me to check whether LMP90100 is functioning properly or not.

    Thank you in advance....

  • Hi Sravanthi,

    in the DS we have the following regarding the CSB

    CSB - Chip Select Bar

    An SPI transaction begins when the master asserts (active low) CSB and ends when the master deasserts

    (active high) CSB. Each transaction might be separated by a subsequent one with a CSB deassertion, but this is

    optional. Once CSB is asserted, it must not pulse (deassert and assert again) during a (desired) transaction.

    CSB can be grounded in systems where LMP90xxx is the only SPI slave. This frees the software from handling

    the CSB. Care has to be taken to avoid any false edge on SCLK, and while operating in this mode, the streaming

    transaction should not be used because exiting from this mode can only be done through a CSB deassertion.

     

    It means that the LMP90100 can work with the CSB grounded.

    Are you sure that the I2C to SPI is working fine ? Can you please test the LMP90100 alone ?

    Only in this way you and I can understand what is going wrong.

    regards,

    Domenico

  • Hi...

    I2C to SPI converter bridge is working fine.

    The LMP90100 is alone tested with GPIO pins,but its not responding as I am doing.

    I am trying to write the code for pulling high but its not coming high voltage.

    Is there any requirement of pullup resistors or anything else.

    Is there any other way to test the LMP90100 alone.

    Please help me in this issue....

    Thank you...

  • Hi Sravanthi,

    the GPIOs do not require any pull-up or pull-down resistances.

    Before checking the output of hte GPIOs have you read back the register you have programmed ?

    Was its content equal to the one you have programmed ?

    regards,

    Domenico

  • HI..

    Another clarification is required....

    In URA setup what Instruction Byte 1 is telling?When to use write address 0X10 and read address 0x90.

    In LRA setup also we are mentioning whether write and read transaction is going to be happen. Is it redundant or wat?

    So please clear my doubt...

    Thank you ,,,,

  • Hi Sravanthi,

    the URA is usually used to point to the first register you want read or write to. You have to use always INST1 = 0x10.

    The command 0x10 simply sets the pointer.

    The first bit in LRA is not a reduntant information, that bit is strictrly related to the operation you want to perform (read or write).

    In case of multiple operations (read or write) to the same register (same pointer) you are not obliged to send the URA for each operation. You can send the URA the first time and then only LRA for successive operations.

    regards,

    Domenico

     

  • HI...

    Thank you very much clarifying the doubt very immediately...

    Then where to use 0x90 as instruction byte.

    Please give some idea for checking the LMP90100 other than with  GPIO checking.

    Thanking you...

  • Hi Sravanthi,

    the 0x90 is simply used to read back the pointer. You do not need it to program the device.

    Until the readback of the regster you want to program dos not match the content that you wanted to write it is hard to find a method to check if the LMP90100 is working fine or not.

    See also this app note: http://www.ti.com/lit/pdf/snaa075

    regards,

    Domenico

  • Is there any initial settings are required before accessing the GPIO pins.

    Thank you in advance

     

  • Hi....

    Is there any restriction  of taking different voltages on VA and VIO pins.

    I have taken 3.3V for  I2C to SPI bridge converter.

    And for LMP90100 VIO as 3.3V and VA as 5V.

    So is there anything wrong in taking VA different from VIO.

    Please reply to this question

    Thank you...

  • Hi Sravanthi,

    you can have VIO and VA at two different voltage level. This is exactly the purpose of the VIO.

    regards,

    Domenico

  • HI...

    Still I am not able to find the mistake in LMP90100 side.

    Can you tell what are the initial register configuration settings required for GPIO.

    How can I find the error in LMP with oscilloscope, what are the minimum wave forms required?

    Thank you...

  • Hi Sravanthi,

    Were you able to read back the content of the registers you have programmed ?

    Until you are not able to do this I cannot help you.

    regards,

    Domenico

  • Hi...

    I am using I2C to SPI bridge,for this bridge LMP is the oonly slave,which CSB is connected to ground always.

    So is there any pattern changes while writing into these registers,because CSB will be deasserted to zero early.

    So is there any chances it may take earlier bit as first bit?

    Thank you....

  • Hi Sravanthi,

    it could happen only if there are spurius spike signal on the SCLK line. Do you have any chance to check this line wiht a scope ?

    DO you know what happens to the SCLK line when your I2C to SPI converter configure the SPI bus?

    Just to remove any doubts, can you control the CSB line too ? In this case you assert the CSB when your I2C to SPI converter has configured the SPI bus.

    regards,

    Domenico

     

  • Hi...

    After so many days my problems has solved. 

    In my circuit LMP90100 is the only one slave but connecting CSB to ground didnt work.

    After correcting this mistake its working fine.

    Thank you for your support.

    Now I am able to write the registers and read the registers.

    Again some doubts has yet to be solved.

    I am not able to configure the CH0 as VIN0-VIN1 and CH1 as VIN2-VIN3.

    In data sheet these are the default values its given But when I am trying to read giving it as 0x00 and 0x12.

    So please clear my doubt.

    Another doubt is 

    In CH_CONFIG I am trying to disable the buffer,but its not happening.Why so?

    In datasheet its given like when gain is >16 it will be included. How this gain will be decided.

    Please clear my doubts.

    Thank you for your support and cooperation.

  • Hi...

    Now I am able to write and read all the registers in LMP,

    For LMP channel 1 output also I am able to read from ADC.This channel voltage is 1.6V.

    Channel 0 voltage is in mV. This voltage when I am trying to read is giving the reference voltage.

    So is there any setting need to be changed to measure this voltage.

    Please reply to this question...

     

    Thank you... 

  • Hi Sravanthi,

    The configuration you are trying is set by default inthe LMP90100. so do not write nothing.

    Have you connected a Voltage reference between VREFP1 and VERFN1 ?

    Please refer to the QUICK START section in the Datasheet.

    The buffer is automatically enabled when the gain set in the PGA is >16. You cannot decide to remove the buffer if the PAG gain is >16.

    regards,

    Domenico

  • Hi...

    Configuring the registers able to do successfully.

    Reading the Channel 1 output from ADC is also happening successfully.(1.6V)

    Reading the channel 0 output from ADC is giving the reference voltage every time. This channel voltage is in the range of mV.

     

    For both the channels common reference voltage I am using.

    So any register setting need to be changed??

     

    Thank you...

  • Hi Sravanthi,

    please provide me with the voltage values you are applying to VIN0, VIN1, VIN2, VIN3.

    By default CH0 = VIN0-VIN1, CH1 = VIN2-VIN3.

    regards,

    Domenico

  • Hi...

    VIN0 is 500mv and VIN1 is 0V.

    CH0=VIN0-VIN1.

    CH1 voltage I am able to read successfully.

    Channel 0 voltage only not able to read. Every time its showing reference voltage.

    Please clarify my one more doubt...

    If these two are my channels how to read ADC voltages continuously from LMP. If I use one more channels continuous scan in CH_SCAN register will ADC consecutive readings will be two channel voltages.

    Do I need to configure the registers for every channel reading of ADC.

    Please clarify my doubts...

  • Hi Sravanthi,

     

    The voltage at VIN0 and VIN1 is withing the range. If you have not selected any Gain the reading should be fine.

    In case you have selected a Gain and (VIN0-VIN1)*Gain is bigger than VREF then you are saturating the ADC and you will read always VREF.

    Regarding the SCAN of the channels, if you leave the LMP90100 in the default conditions, it is in the ScanMode0, it means continuous conversion of single channel.

    By default the first ch of the scan mode is CH0 and the last is CH6. Since by default the scan mode is Scanmode0 you are acquiring CH0 continusly.

    In order to acquire multiple channels in continuos scan you have to select ScanMode2, moreover you have to select the first and the last channel of the scan (all these parameters needs to be filled in the register 0x1F) see page 56 of Datasheet.

    regards,

    Domenico

  • Hi...!

    I am using gain as 1. but still I am not able to read CH0 ADP output voltage. But I am able to see VIN0 voltage as 500 mV and VIN1 as 0 V.

    I have checked with all ODR.

    Is there any extra settings to be set along with this to measure in mV ??

    Thank You....

  • Hi Sravanthi,

    what do you mean for "measure in mV" ?

    regards,

    Domenico

  • Hi...

    To measure in mV input at input pins do I need any special settings.

    Every time I am getting the saturation voltage for CH0.

    What might be the problem for  this kind of output.

    Thank you...

  • Hi Sravanthi,

    it is really strange that you are reading the saturated code, if your voltage reference (between REFP1 and REFN1) is higher than VCH0 and the gain is equal to 1.

    Which is the 500mV source? Are you using a voltage divider ? If so which are the values of the resistors ?

    If you are using a voltage divider with high resistors (>10Kohm) please enable the buffer (bit 0 of CH0_CONFIG register).

    regards,

    Domenico

  • Hi...

    When I am measuring VIN0-VIN1  and VIN1-VIN0 voltages are different.

    Why so it will happen.

    Please clarify my doubt....

    Is there any chance that pins will fail to function?

  • Hi...

    I connected 0.5V to VIN1 and VIN3 is connected to ground. Ref voltage is 2.5V.

    And  I am assigned VIN1-VIN3 as channel 0.

    I tried to read SENDIAG_FLAGS(0x19) register it is showing data as 0x50,which means that modulator is over ranged.

    What will be the reason to show like this? 

    What is the interpretation from this value?

    Is there any failure of pins?

    Please clarify my doubts.

    Thank you...

  • Hi...

    Please explain the differential voltage measurement by fixing one input to half of the reference voltage (As given in example in datasheet).

    Thank you...

  • Hi Sravanthi,

    Allow some time to Domenico to review your new question.

    Thanks!

    Mayrim

  • Hi Sravanthi,

    SENDIAG_FLAGS(0x19) = 0x50 means :

    1.one of the input is reaching the rails (GND or VDD)

    2. the modulator is not overranged, but the adc is clamped

    In your case the first assertion is clear,  the second one according to your setup can be true only if you have set a gain >=5.

    Please provide me with the schematic of your application and the register setting.

    regards,

    Domenico

     

  • Hi Sravanthi,

    this is the classical problem of sensor with bipolar voltage output and differential ADC supplied between GND and VDD.

    In order to acquire negative and positive signal, you shifht the output of the sensor at 1/2VREF.

    In this way negative values of the sensor will fall in the (GND, 1/2VREF) range, while positive value will fall in the (1/2VREF, VREF) range.

    Seethe Themocouple example in the DS.

    regards,

    Domenico