DangerKlippers/danger-klipper

Feature request: Port ADS1118 SPI ADC/Amplifier support

comradef191 opened this issue · 1 comments

There's another fork of Klipper which has added ADS1118 support, for use on Replicator 2 clones as a thermocouple amplifier.
I think it would be nice to have alongside #103, and the ADS1118 features a few key differences that make it more desirable for certain usecases over existing supported SPI Thermocouple chips.

Comparison between the TLA2518 a PR is up for, and the ADS1118:

  • Both use SPI with a single ChipSelect pin rather than needing multiple I/O pins for each input
  • Both can run off 3V3 or 5V
  • TLA2518 is 12-bit, ADS1118 is 16-bit
  • Sample Rate maxes out at 1000 per second on the TLA2518, compared to 860 on the ADS1118
  • Price on Mouser:
  • The ADS1118 can operate as Thermocouple input; The TLA2518 only accepts ADC inputs

I feel like the ADS1118 isn't particularly worth it for use as a regular ADC Thermistor input due to the extra cost and halving of inputs compared to the TLA2518, unless the extra bitrate makes it better despite lower sampling rate.

It does, however, seem to shine rather well as a Type-K thermocouple amplifier, being the amplifier of choice on various expensive printers.
In particular, its cheap. really. cheap.

The next two cheapest amplifier chips that Klipper supports are the AD8497 at £4.65/e, and the AD8495 at £6.59/e
Both of these chips come with major flaws.

  • The AD8495 can only read upto 400c, not really enough for HT materials
  • The AD8497 can only read upto 250c, barely enough for ASA

The ADS1118 can read up to 1,250c, Plenty enough for extremely high-temperature printing (god holy shit it better be wtf...), whilst being over £2 cheaper and easier to source than the next cheapest chip capable of over 500c- the MAX31855 for £6.67/e

"ok but pera the only boards using this are these randomass replicator clones"

I'm currently working on a mainboard that uses an ultra-cheap STM32 MCU and then has four slots for custom SPI modules, rather than "wasting" I/O on temperature inputs the user may not want.
I already have a design for the TLA2518, and had planned to make a module for a Thermocouple amplifier and a PT100 RTD. It'd be really nice if I can have that thermocouple amplifier be cheap as hell.
Added bonus is these modules should work on any machine with exposed SPI pins and I/O to use as CS, not just my mainboard.
I might design a board even if there isn't an active PR or dev work yet, idk yet

Hi,

Just a note that the TLA2518 is 1000 ksps, not samples per seconds. So around 1000x more than the ADS1118. The TLA2518 PR uses 128x oversampling, giving it ~15 bits of precision.

Best regards,
Lasse