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.

Switching Gas Sensor Platform to Oxygen Mode (LMP91000)

Other Parts Discussed in Thread: LMP91000, LM4120

Hello,

I purchased the gas sensor platform reference design with the LMP91000 and BLE bluetooth module. I want to use it with an oxygen sensor but cannot figure out how to switch it to oxygen mode from the default CO mode.

I purchased the CC debugger and downloaded the Smart RF flash programmer and successfully updated the firmware on the module in the Smart RF software.

I have also downloaded the IAR workbench and the firmware from TI website. I opened the firmware file with IAR workbench, just like the reference guide instructed, and put an "x" next to CO mode and removed the "x" next to O2 mode.

But I can't get past this point. I can change the code using the IAR workbench software but I can't upload any firmware changes to the gas sensor device in this software. Conversely, I can update the firmware of the device using the Smart RF flash programmer software but I cannot actually change the firmware to my desired oxygen setting using this other software. The user guide does not state how to upload firmware changes made in IAR workbench to the device. How do I upload the changes I make to the firmware in IAR workbench to the physical device? If I fix the problem, will the iPhone app automatically recognize that the device is in oxygen mode and plot data accordingly?

Thanks,
Will

  • Hello Will,

    Apologies for the delayed answere, we will get back to you within one day.

  • Perhaps a better way to state my problem:

    I downloaded IAR embedded workbench and switched the settings to O2 mode (I think...) but when I try to download and debug the new firmware settings to the device via the CC debugger IAR finds no target device. I looked in my devices and printers and my PC recognizes the CC debugger on the com port. What am I doing incorrectly?

  • Hello,

    Thank you for clarification!

    The apps engg is looking into it and will get back to you shortly.

  • Hello, here's the response I have received:

    Under the Project tab is a “Download and Debug” option which will compile and download the modified code.

    It is also connected to an icon in the toolbar. Also please check with customer, what license version is being used. As if its only kickstarter, then there is a limit on the size of code. They need a full license.

     

     

    Hardware response

     

    For O2 sensor Resistor R43 – 0ohm resistor needs to be installed

     

     

     

     

     

     

     

  • Hi Evgeny,

    I have a 30 day trial of the software so it is NOT code limited. I can compile the code without error (Whereas in the code-limited kickstarter you cannot compile code over 4k. I learned that the hard way).

    My issue is when I click download and debug as you have indicated, the software asks me to identify the target device, and gives me a list of target devices to choose from. This list of target devices is always empty, despite the fact that I have connected the BLE device to a COM port using the CC debugger and my windows machine recognizes the CC debugger on the USB port. Any ideas as to how I can point the software to the module on the COM port as my target device?

  • Hello William,

    Here's the response I got from the support team:

    From a quick experimentation, I only get that error message he is indicating when I don’t have the CC Debugger plugged in.

     

     If the CC Debugger is connected to the IAR IDE and the hardware device is not connected or not turned on, I get

     

     

    I would also consider making sure the firmware on the CC Debugger is current using RF Studio 7.

    http://www.ti.com/lit/ug/swru197h/swru197h.pdf

     

    I have also seen someone who ended up having to install the driver manually as it appears IAR didn’t get it installed for him correctly.

    http://e2e.ti.com/support/wireless_connectivity/f/155/t/138289.aspx

  • Hello William,

    One of our team members has used CCS to successfully program the gas sensor. Could you please check that connector of CC debugger is installer properly (the notch should be facing outside the board)?

  • We too cannot seem to change the "app" to read the oxygen sensor.  (The app is a TI Ipod or Ipad app to demonstrate the Bluetooth system communicating with the sensor.)  The Bluetooth is sending the correct hex code, but how do you change the Apple IPod or IPad app to read other than CO ppm.  We want percent oxygen.  We did install the zero ohm resistor on the device.  It appears this is "app: related and not the TI hardware.  We only need the app for demo purposes at this point before we write our own, but need to display oxygen percent this week if the project is to get funded.

  • Open the firmware file with IAR workbench,
    put an "x" next to CO mode and remove the "x" next to O2 mode. To enable compiler to load corresponding Header files
    this will ensure that in the file Filename: sensorBLEBroadcaster.c

    the compiler INCLUDES header files accordingly as below:

    #if defined O2_SENSOR
    #include "O2_Sensor_Settings.h"

    #elif defined CO_SENSOR
    #include "CO_Sensor_Settings.h"
    #endif

    Next to adjust to other types of O2 sensors we need to tweak these parameters : by referring File Name: TI_LMP91000.h

    // LMP91000 Settings for the O2 Sensor
    #define SENS_OPERATIONAL_MODE OP_MODE_3_LEAD ( we changed to OP_MODE_2_LEAD )
    #define SENS_FEEDBACK_GAIN TIA_GAIN_7K_OHM ( we changed to 3.5K for a 200uA for 20.9% O2.)
    #define SENS_RLOAD R_LOAD_100_OHM (not required for 2 lead)
    #define SENS_INT_Z_REF_DIVIDER INT_Z_SEL_67_PERCENT (
    #define SENS_REF_SOURCE REF_SOURCE_EXTERNAL (generated by LM4120)

    The Basic TI system is calibrated to as below

    840 counts × 0.001221 = 1.025 V ADC Voltage

    Vref (2.5V) x ( INT_Z_SEL_67_PERCENT)
    ------------------------------------------------------ = Isensor (20.9%)
    TIA_GAIN_7K_OHM

    The eval board is designed for 91uA for 20.9%
  • small mistake
    Vref (2.5V) x ( INT_Z_SEL_67_PERCENT)- VOUT
    ------------------------------------------------------ = Isensor (20.9%)
    TIA_GAIN_7K_OHM