Shop OBEX P1 Docs P2 Docs Learn Events
Inside the Propeller — Parallax Forums

Inside the Propeller

HumanoidoHumanoido Posts: 5,770
edited 2012-09-19 01:30 in Propeller 1
Is there anything inside the Propeller chip
that can act like a sensor?

(or a technique to program a sensor inside the chip?)

No, not sense the outside world, but sense the inside of the chip.

The project is to crudely image the inside of the chip,
by mapping electrical fields, or other method
with parts and code inside the chip.

Thanks sincerely

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2012-09-16 07:57
    You have two questions ... The first is whether the Propeller chip can act like a sensor. The second is whether sensing capabilities can be used to crudely image inside the chip.

    The answer to the first question is maybe or "theoretically, but not in any meaningful practical way". The various sections of the chip and their wiring on the chip have capacitance and inductance and this can be measured in a fashion. Semiconductors can detect light and other forms of radiation and the difference between a memory array and a camera chip is more one of intent than structure. That said ...

    The answer to the second question is NO. There's a lot going on inside the chip. Everything it does involves moving charges around and that will affect how much noise and other artifacts there might be on any attempt to measure things on the chip. The fact that there are things inside the chip that theoretically might act as sensors doesn't mean that they can be used in any meaningful way as such.

    Even though you can use RAM arrays as crude photo sensors, the chip package is designed to prevent this from happening. You'd have to grind or chemically etch the package material off the chip to expose a portion of the RAM array to light to use it. You can't just take off the whole package, because then you couldn't have a program stay in un-altered form in memory to process the rest of the memory contents.

    I don't know how the metallization was done over the memory arrays. It could interfere with this effect. Remember that the chip layout is sometimes done specifically to prevent portions of the chip from reacting to electrical fields and ionizing radiation since that's not something you want to happen when you can avoid it.
  • LeonLeon Posts: 7,620
    edited 2012-09-16 08:28
    Many years ago people removed the tops of DRAMs in DIL ceramic packages with metal lids, and used them as low-resolution image sensors. I tried it, but couldn't remove the lids without damaging one or more of the internal wire connections.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-09-16 09:36
    Leon wrote:
    Many years ago people removed the tops of DRAMs in DIL ceramic packages with metal lids, and used them as low-resolution image sensors.

    I believe that's how Micron's CMOS imaging division got its start. The very first imager I worked with in the early '80s included a converted CMOS RAM chip as its sensor. It wasn't very good, though, exhibiting a wide range in sensitivity from pixel to pixel.

    -Phil
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2012-09-16 11:17
    Every i/o pin has a substrate diode that can be a temperature sensor. Given a constant forward current, the voltage across the diode decreases about 2mV per °C. There are chips available that take advantage of that to measure the temperature of an MCU as thermal energy sloshes back and forth. Take a look at the TI lineup of remote temperature sensors. They have become pretty advanced to compensate for non-ideal diode behavior.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-09-16 11:49
    The VCOs used in the counter PLL modes are also temperature-sensitive. The idea is to drive the PLL with a high-enough frequency that the VCO is guaranteed to operate at its free-running frequency, then divide that frequency down so that it can be measured with another counter. Here's a program that demonstrates the technique:
    CON
    
      _clkmode      = xtal1 + pll16x
      _xinfreq      = 5_000_000
    
      PIN           = 0
    
    PUB  start | time, f0, f1
    
      ctra := %00010 << 26 | PIN
      frqa := $8000_0000
      dira[PIN]~~
      ctrb := %01010 << 26 | PIN
      frqb := 1
      repeat
        time := cnt
        waitcnt(time += clkfreq/ 1000)
        f0 := phsb
        waitcnt(time+= clkfreq)
        f1 := phsb
        f1 -= f0
        '.debug "Frequency is: ", dec f1, #CR
    

    Here is some sample output:
    Frequency is: 1805555
    Frequency is: 1805200
    Frequency is: 1804393
    Frequency is: 1804200
    Frequency is: 1804138
    Frequency is: 1804127
    Frequency is: 1804122
    Frequency is: 1804122
    Frequency is: 1804123
    Frequency is: 1804122
    Frequency is: 1804122
    Frequency is: 1804122
    Frequency is: 1804124
    Frequency is: 1804122
    Frequency is: 1804121
    Frequency is: 1804122
    Frequency is: 1804123
    Frequency is: 1804120
    Frequency is: 1802439    [color=red]<-- Hot air applied beginning here.[/color]
    Frequency is: 1798314
    Frequency is: 1790525
    Frequency is: 1783064
    Frequency is: 1774080
    Frequency is: 1766323
    Frequency is: 1759873
    Frequency is: 1755047
    Frequency is: 1750464
    Frequency is: 1746388
    Frequency is: 1743324
    Frequency is: 1740074
    Frequency is: 1739130
    Frequency is: 1736684
    Frequency is: 1734984
    Frequency is: 1734689
    Frequency is: 1733498
    Frequency is: 1733674
    Frequency is: 1735813
    Frequency is: 1738740
    Frequency is: 1739177
    Frequency is: 1741649
    Frequency is: 1742702
    Frequency is: 1744008
    Frequency is: 1744186    [color=red]<-- Hot air withdrawn.[/color]
    Frequency is: 1745236
    Frequency is: 1746028
    Frequency is: 1746421
    Frequency is: 1747160
    Frequency is: 1747906
    Frequency is: 1749566
    Frequency is: 1749995
    Frequency is: 1750000
    

    -Phil
  • Heater.Heater. Posts: 21,230
    edited 2012-09-16 11:57
    Phil,

    That's brilliant. You have just turned an 8 core 32 bit processor into a thermometer:)

    Well, given some calibration this may well be useful sometime.
  • SapiehaSapieha Posts: 2,964
    edited 2012-09-16 12:13
    Hi Heater.

    One thing I can directly can see it can be used to is --- Correction of RTC's controlled by Propeller frequency

    Heater. wrote: »
    Phil,

    That's brilliant. You have just turned an 8 core 32 bit processor into a thermometer:)

    Well, given some calibration this may well be useful sometime.
  • LeonLeon Posts: 7,620
    edited 2012-09-16 12:16
    Many of the newer PICs contain an on-chip temperature sensor that can be read with the ADC.
  • ElectricAyeElectricAye Posts: 4,561
    edited 2012-09-16 12:23
    Heater. wrote: »
    ...You have just turned an 8 core 32 bit processor into a thermometer:)

    Well, given some calibration this may well be useful sometime.

    Could that work as a thermal-protection feature? The Prop can sense it's about to over heat, so it shuts down something or turns on a fan???
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2012-09-16 12:27
    An interesting note about decapping a chip... If you expose the inside of the chip to air, then the dielectric might change enough that you introduce shorts.

    What I mean is... it takes approximately 30kV per centimeter to break down air for a spark or a short circuit to occur. Scaling that down to chip level, that's about 3V per micron. In order to get past Moore's law, great efforts have been made to introduce dielectric materials that increase the permeability between adjacent metal wires and layers at the sub-micron level. The act of decapping the chip and exposing it to air could disrupt the permeability.
  • ElectrodudeElectrodude Posts: 1,665
    edited 2012-09-16 12:43
    If you overclocked it different amounts would you be able to map its insides based on what got messed up starting at what frequency?
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-09-16 13:02
    One thing I wanted to see was the effect of the number of active cogs on die temperature. Here's the modified program I used:
    CON
    
      _clkmode      = xtal1 + pll16x
      _xinfreq      = 5_000_000
    
      PIN           = 0
      COGS          = 1
    
    PUB  start | time, f0, f1
    
      ctra := %00010 << 26 | PIN
      frqa := $8000_0000
      dira[PIN]~~
      ctrb := %01010 << 26 | PIN
      frqb := 1
      repeat COGS - 1
        cognew(@heater, 0)
      repeat
        time := cnt
        waitcnt(time += clkfreq/ 1000)
        f0 := phsb
        waitcnt(time+= clkfreq)
        f1 := phsb
        f1 -= f0
        '.debug "Frequency is: ", dec f1, #CR
    
    DAT
    
    heater        jmp       #heater
    

    Here are the results:

    attachment.php?attachmentid=95634&d=1347825555

    Because '.debug uses PST and an extra cog, I had to obtain the result for one cog from the spectrum analyzer without '.debug being active. Anyway, the results are as expected: the more that's going on in the chip, the warmer the die.

    -Phil
    824 x 495 - 20K
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-09-16 13:11
    Another thing that affects temperature is loading the output pin(s). By connecting a 100-ohm resistor from the counter output to ground, the die temp rose to the same level as adding another active cog would have done.

    One other thing worth noting is that the Prop has 16 independent VCOs spread across one edge of the chip (PLLA & PLLB below):

    PropDieDiagram_P8X32A.jpg

    So it should be possible to measure temperature gradients across the die or localized heating. Of course, some prior calibration would be required, since the VCOs are sure to have different offsets and gains vs. temperature.

    -Phil
  • Mark_TMark_T Posts: 1,981
    edited 2012-09-16 13:34
    In order to get past Moore's law, great efforts have been made to introduce dielectric materials that increase the permeability between adjacent metal wires and layers at the sub-micron level.

    Permittivity surely, not permeability? Most of these dielectrics are oxides and very refractory, zirconium and hafnium dioxides and silicates should resist atmospheric oxygen I think ;)

    [Also the gate dielectric is at the bottom of the pile and not exposed at all ??]
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2012-09-16 13:47
    Permittivity ... dang auto spell ...

    "Also the gate dielectric is at the bottom of the pile and not exposed at all" ... right but even using a 180nm process, the metal to metal distance is .28um ... A spark gap of 840mV in regular air under 1 atmosphere of pressure.
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2012-09-16 21:15
    Phil, insightful as usual, but please help me understand this. The free-running PLL attached to ctra is being driven at 40MHz, and therefore cannot lock and free runs instead. When it free runs, it is going to be up at 200MHz or above. Is that what you see on the spectrum analyzer? Then to count it using POSDET with ctrb, there is a limit to counting speed somewhere around 20MHz. You said,
    "The idea is to drive the PLL with a high-enough frequency that the VCO is guaranteed to operate at its free-running frequency, then divide that frequency down so that it can be measured with another counter. The result of counting for 1ms is a number...".
    Do you indeed have an external hardware divider in there? The frequencies reported with the 1ms gate are around 1.8MHz.

    One thing that generates heat on the die is operating the pin at threshold, as in a sigma-delta converter. So a neighboring counter module used as your temperature sensor should be able to pick that up.
  • jmgjmg Posts: 15,183
    edited 2012-09-16 21:34
    Phil, insightful as usual, but please help me understand this. The free-running PLL attached to ctra is being driven at 40MHz, and therefore cannot lock and free runs instead.

    How a PLL/VCO free-runs also depends on the Phase Comparator - they do not all nicely saturate, but may 'hunt' but fail to lock.

    Would this also work at the other end of the range ? (that is likely to consume less power itself, and also be more MHz-legal to mesaure) :

    The data quotes 64-128MHz as valid for the PLL.VCO, so if you asked for something well under 64MHz would that free-run, or try to lock on some edges, or ?
  • HumanoidoHumanoido Posts: 5,770
    edited 2012-09-16 21:37
    Every i/o pin has a substrate diode that can be a temperature sensor. Given a constant forward current, the voltage across the diode decreases about 2mV per °C.
    Mr. Allen, thanks for this useful info. Can you provide more detail about how to do this? Is the Propeller chip capable of doing this internally or does it require external circuits (to apply current and read the voltage drop)?
  • Mike GreenMike Green Posts: 23,101
    edited 2012-09-16 21:45
    These are the "protective diodes" that shunt high (> 3.6V) or low (< -0.3V) voltages on the I/O pins to the power busses. You would need some external circuitry to provide a constant current source on the order of a few hundred uA at an appropriate voltage. There's nothing that could do this completely internally.
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-09-16 22:10
    Tracy,

    A free-running PLL VCO will oscillate at about 230 MHz. At a PLL's lowest divide ratio (/8), which is actually VCO/128, the output on the pin will be ~1.8 MHz. That's what I'm measuring with the other counter.

    jmg,

    With a 40 MHz NCO drive, the PLL is completely befuddled, shows no inclination to hunt, and its oscillation is quite stable.. At the other end of the range (i.e. 0 Hz), the story is quite different. The output of the VCO is very nearly aperiodic with sporadic episodes of oscillation, followed by longer epochs of quiescence.

    -Phil
  • Tracy AllenTracy Allen Posts: 6,664
    edited 2012-09-17 07:49
    I had to refresh my memory cells about how the PLL dividers are set up. You didn't have to mention it or code it explicitly--Conveniently /128 is mode %000. It's helpful that the divider chain even works with the 230MHz input. The edges hit the first flip-flop at 2.2ns intervals.
  • Heater.Heater. Posts: 21,230
    edited 2012-09-17 08:05
    Of course using Chips real Random object, which uses the PLL, the Propeller is directly in touch with the Global Consciousness without ever connecting anything to it's pins:)

    http://en.wikipedia.org/wiki/Global_Consciousness_Project
  • LawsonLawson Posts: 870
    edited 2012-09-17 12:14
    At the other end of the range (i.e. 0 Hz), the story is quite different. The output of the VCO is very nearly aperiodic with sporadic episodes of oscillation, followed by longer epochs of quiescence.

    -Phil

    Sounds like a PLL driven with 0Hz would be decent entropy source for a random number generator.

    Back on topic, the internal RC clocks are strongly effected by temperature and supply voltage. Given some stable external timing source, they'd give another view into the chip. (even a simple external RC circuit can be enough)

    Lawson
  • HumanoidoHumanoido Posts: 5,770
    edited 2012-09-19 01:30
    The consensus is about using the chip as a thermal heat sensor. The idea now is to map chip’s interior thermal signature - using the chip to measure itself. For example, pin diodes and counter modules will detect heat from their prop locations. From this thread, the following methods will detect heat:


    * Pin Diode
    * VCO
    * Over clocking Different Amounts
    * Neighboring Counter Module
    * RC Clock


    Does this cover all known ways of using the Prop chip to detect its own internal temperature?

    Detecting temp in more locations inside the chip will help create a better thermal map.
Sign In or Register to comment.