Author Topic: Temperature sensor to interface with CPLDs  (Read 1308 times)

0 Members and 1 Guest are viewing this topic.

Offline garvind25Topic starter

  • Regular Contributor
  • *
  • Posts: 59
  • Country: in
Temperature sensor to interface with CPLDs
« on: June 09, 2018, 10:36:36 am »
Hi,

  Can anyone suggest a simple SPI output based temperature sensor for interfacing with a CPLD. I am looking a hand solderable component which I can put on my CPLD based project and try interfacing with it. There are several sensors available on the internet but since I have never worked with these devices, I don’t know which to select.

Thanks,
Arvind Gupta
 

Offline IonizedGears

  • Regular Contributor
  • *
  • Posts: 248
  • Country: us
Re: Temperature sensor to interface with CPLDs
« Reply #1 on: June 09, 2018, 11:59:29 am »
You need to choose the type of temperature sensor you'll be using if you haven't already. The three main ones are PTC/NTC thermistors, thermocouples, and RTDs. Each of these categories have many subtypes and compositions that make them useful for specific temperature ranges, etc. Generally people use thermocouples for fast measurements or RTDs for their low-drift, high accuracy.

For thermocouples:
The MAX31855 is an IC for interfacing with thermocouples. There is a version for each type of thermocouple so just choose depending on what you decide to use. Interfacing with it is stupid easy since it requires no setup because it doesn't have registers that need to be set in the first place. It doesn't even have a MOSI pin. It outputs 32 bits including the converted thermocouple temperature, some fault-detection bits, and the internal temperature used for cold junction compensation. It comes in a SOIC package so it's pretty easy to solder by hand.

There is a MAX31856 IC as well but it's much more complicated because it supports many thermocouple types and requires MOSI to setup the registers. It also comes in a smaller, slightly harder to solder package.


For RTDs:
Look into the MAX31865, I haven't used it/made a library for it yet so I can't say much about it.

IX

I am an EE with interests in Embedded, RF, Control Systems, and Nanotech.
 


Offline NorthGuy

  • Super Contributor
  • ***
  • Posts: 3147
  • Country: ca
Re: Temperature sensor to interface with CPLDs
« Reply #3 on: June 09, 2018, 04:32:28 pm »
DS18B20 are very popular for "normal" temperature range. Not exactly SPI, but it probably doesn't matter for CPLD.
 

Offline garvind25Topic starter

  • Regular Contributor
  • *
  • Posts: 59
  • Country: in
Re: Temperature sensor to interface with CPLDs
« Reply #4 on: June 09, 2018, 04:55:33 pm »
Thanks for the replies. Thermocouples and RTDs will be an expensive option for just trying to interface a temperature sensor to CPLD. I am looking for low cost options which are easily available. DS18B20 is a non SPI device. Will look into it later. As per the Digikey link, yes there a a lot of devices available but not on low cost sites like aliexpress etc. Hence, still looking for more answers pls.  :P

Thanks again,
Arvind Gupta
 

Offline dgtl

  • Regular Contributor
  • *
  • Posts: 183
  • Country: ee
Re: Temperature sensor to interface with CPLDs
« Reply #5 on: June 10, 2018, 04:35:37 pm »
Unless there is a microcontroller somewhere, the 1-wire is not simple to write in hdl, requires a quite large state machine. Try to find some kind of SPI or I2C sensor, that does not require too much of configuration to use, something that would require only reading temperature register value.
A CPLD is a bit strange choice for temperature sensor reading. A uc would be much more appropriate (unless there are some other parts of the system that would require CPLD).
 

Offline NorthGuy

  • Super Contributor
  • ***
  • Posts: 3147
  • Country: ca
Re: Temperature sensor to interface with CPLDs
« Reply #6 on: June 10, 2018, 05:34:29 pm »
... the 1-wire is not simple to write in hdl, requires a quite large state machine.

One-wire is the same as SPI, except data and clock are multiplexed on the single wire.

 

Offline andy1

  • Contributor
  • Posts: 25
  • Country: fi
Re: Temperature sensor to interface with CPLDs
« Reply #7 on: June 10, 2018, 06:17:52 pm »
I would look into PWM-output temperature sensors, there are several manufacturers, they are usually quite cheap and the cpld/fpga part can be really simple to get the value.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf