CTMU like peripheral on STM32 - Page 1
Forum section: electronics / beginners

author: mercurial
author_rank: Regular Contributor
timestamp: February 01, 2024, 05:55:33 am
content: I see that Microchip has CTMU(Charge time measurement unit) peripheral which is versatile and can be used for high resolution (< 100ps) time measurement applications.I couldn't find similar peripheral in other MCU brands, i could have probably missed it do any other MCU brands especially STM32 support high resolution time measurement in hardware like the CTMU.If not is it possible to implement such functionality external to the device, I see that we might need a fast switching current source, but are there any other implications in trying to do so. Has someone already done this on an STM32 or on a MCU that doesn't have a CTMU.

author: AndyC_772
author_rank: Super Contributor
timestamp: February 01, 2024, 08:58:55 am
content: I've not seen a similar device anywhere. The closest is probably a capacitive sensor designed for touch buttons, which you might be able to use for some of the same applications.I did check out the high resolution timer in some of the newest STM32s, but it seems to be designed to generate - not measure - pulses with very fine resolution.

author: jwet
author_rank: Frequent Contributor
timestamp: February 02, 2024, 05:48:27 pm
content: There are a few specialty parts like the CTMU and you could roll your own with an onboard MCU CCAP timer. It depends what you're trying to do. The microchip stuff is nice for basic timing. Some options follows.Maxim (ADI) makes a part called the MAX35102 which has a resolution of 20 pS. It was designed for use in flowmeters and laser time of flight. These are called TDC or TAC's- time to digital converters.Maxim (ADI) also make "time verniers" that were used as precision delays in Automatic Test Equipment pin drivers. This stuff is exotic and expensive but you can get timing down to the picosecond. Look at MAX32000 series or ADATE 9.. series.You can roll your own CTMU like function with a constant current source, fast comparator and a standard timer with CCAP type functions where an input can capture the time.A small FPGA could be used to implement a function like this and give you some flexibility.Good luck.

author: bidrohini1
author_rank: Contributor
timestamp: February 03, 2024, 01:06:03 pm
content: For high-resolution time measurements, you can utilize the input capture feature of the timers.

author: DavidAlfa
author_rank: Super Contributor
timestamp: February 03, 2024, 01:35:32 pm
content: I wouldn't waste useful peripherals for touch buttons (If that's your target), there're touch sensors for 3 cents:https://www.lcsc.com/product-detail/Touch-Sensors_Shenzhen-Fuman-Elec-TC233A_C2798022.htmlFor precise reading of capacitance variation, the MPR121 provides 12 independent channels with 10-bit resolution, though a bit expensive, reaching $1 mark:https://www.lcsc.com/product-detail/Touch-Sensors_NXP-Semicon-MPR121QR2_C91322.html

author: mercurial
author_rank: Regular Contributor
timestamp: February 05, 2024, 07:03:17 pm
content: Some really good suggestions for rolling out your own CTMU,But some questions remains. If we need picosecond resolution, the current source has to be switched atleast in 10's of picosecond range if not lower. How does one achieve this without breaking the bank?