Questions tagged [timer]

Circuit to generate a signal a specific time after a trigger event. The timing can be defined by an RC time constant, or by clock pulses from an oscillator.

Filter by
Sorted by
Tagged with
1
vote
3answers
175 views

How to increase STM32 Timer (encoder mode) counter value?

I am developing mobile robot. Hear i required to read quadrature encoder.So i am using stm32F401 using 16bit timer(encoder mode) to read the count.After 65535 count goes to 0. My question is how to ...
-2
votes
0answers
65 views

Time of arrival of a pulse in 10 ns accuracy [closed]

I would like to send an electromagnetic wave pulse (laser or radio) from at least 5 km distance and see the toa of the pulse in nanoseconds accuracy. Alternatively, I would like to see the toa of any ...
1
vote
1answer
21 views

STM32F7 Two Timer Channels Share One DMA Channel

I am trying to write a driver that sends DShot commands to an ESC. I am using an STM32F722 MCU. The DShot protocol is similar to addressable LEDs where 1/3 duty cycle represents a 0 and a 2/3 duty ...
0
votes
1answer
42 views

Making duty cycle with CTC mode in AVR without using interrupt

I am writing a program to make an output with a 30% duty cycle and a frequency of 3 kHz using an ATmega32 microcontroller. My controller's frequency is 8 MHz and I am going to decrease it to 1 MHz by ...
0
votes
0answers
15 views

Configuration space for the PIC18F66K40 timer 0

I wrote a utility to accelerate analysis of timer configuration in embedded systems. This is not a replacement for testing; it's a convenience visualisation. The default configuration on load ...
0
votes
0answers
63 views

Counting hours from closed circuit

A complete ignorant here. I am trying to custom-build some sort of lab timer with an external trigger (the longest-running one that I found to buy was up to 24 hr and I need one that is up to 72 hr). ...
0
votes
4answers
97 views

How can a lidar achieve cm-level resolution?

In order to achieve cm-level resolution, it seems like a lidar would need to have extremely high sampling rates. Here's my thinking: Light travels at roughly 3·108 m/s, or 3·1010 cm/s. We need to ...
2
votes
1answer
59 views

stm32f051 - Config Timer14 to Interrupt only by counter overflow, not by counter initialization

I'm new to the world of embedded and I'm implementing a short, long and two-click on a button logic in my project on a stm32f051 I'm having a problem with the timer interrupt, I want it to generate ...
0
votes
1answer
21 views

Connect DC 6-30V 1-Way Relay Module Power-off Trigger Delay Cycle Timer Switch with PIR Motion sensor?

I am trying to connect a DC 6-30V 1-Way Relay Module Power-off Trigger Delay Cycle Timer Switch with an HC-SR501 Infrared PIR Motion Sensor Module. The output of the motion sensor is only 3 V. Do you ...
1
vote
2answers
53 views

How to locate timer channels for this uC board?

I'm trying to visualize and point on diagram where timer channels at this datasheet. STM32 uses the term channels. I guess what mean by timer channels are timer outputs. What is meant by channel? Can ...
3
votes
4answers
137 views

Make a string of Christmas lights slowly brighten and dim

OK, here's my Christmas light project and I didn't see this one asked yet on StackExchange. What I am trying to achieve: have a single string of incandescent Christmas lights slowly dim and brighten ...
0
votes
0answers
53 views

6V-12V to on/off switch conversion

In order to connect/disconnet a battery pack I need to use a timer (https://www.highwildoutdoors.com/products/6v-12v-universal-digital-timer) which seems has 6v-12v output. I am not sure which relay I ...
2
votes
4answers
163 views

Resettable timer with opamp

I need to make a circuit with an opamp and passive components that has those constraints : When it receives a pulse on one input, its output should be high. After a predefined duration T, it should ...
0
votes
1answer
55 views

Faster Timer0 overflow than 2 ms on Attiny85

I'm trying to get a Timer0 overflow with an overflow every 500us, but can't find a solution to get it so low. I'm running the Attiny85 on its internal 1 MHz clock, so I know it is not gonna be the ...
1
vote
0answers
43 views

Triggering 3ADC's simultaneously in continuous mode by a timer in STM32

I have 3 ADCs (ADC1, ADC2, ADC3) configured with 3 different channels for 3 gpio pins to collect the data and all 3 ADC's are triggered simultaneously by TIM1 at the rising edge of the pulse. It is ...
0
votes
1answer
52 views

Momentary on for one minute

I’ve built a dumb waiter using a 12 V electric over hydraulic pump and a cylinder. Currently using the wired remote to send it up and down. I would like to be able to push a button mounted to the wall ...
0
votes
0answers
160 views

How to update period of a timer every interrupt on stm32 with preload enabled?

I'd like to change timer period inside interrupt handler that is equivalent to AVR code ISR(TIMER0_COMP_vect){ OCR0 == new_value } As I undestand the documentation,...
0
votes
2answers
95 views

High power to low power timed switch with microcontroller clocking

I am new to this circuit things and still currently learning. I am trying to build a circuit with a heater and fan that switches to low power mode after 12 hours. Currently I am also trying to learn ...
0
votes
1answer
74 views

MSP430 Timer Interrupt Not Happening

I recently starting learning how to program a MSP430 and thought I'd start by writing a program to turn a LED on and off every second. However, when I run my code the LED goes on an stays on. When I ...
1
vote
0answers
42 views

Question regarding STM32 timer trigger mode for synchronization

I am using STM32L4R5 and need a specific case of synchronization: I am using TIM15 to generate a PWM signal with 50% duty cycle. In my application I have to stop PWM from time to time using the pin as ...
1
vote
3answers
86 views

Starting and stopping timers with a button

I want to start and stop timers from the button state. I am using an STM32F407VG. This it the circuit I designed: When the button is pushed there is 0.45 V. When I release the button there will be 4....
0
votes
2answers
72 views

How can I provide time-controlled current protection?

I need a component name or solution. I have a fan motor that I run with AC. I am controlling with MCU and driver. Operation logic: 0.75 s on, 9.25 s off. My circuit works flawlessly with this logic. ...
1
vote
0answers
70 views

Capacitor Time Delay circuit not working

simulate this circuit – Schematic created using CircuitLab I made a circuit schematic for a simple discrete capacitor+resistor time delay circuit, using a 1500uf capacitor and a 100kOhm resistor ...
1
vote
2answers
117 views

How to Have Two PWM Signals with Adjustable Duty Cycle

I am using Mosfets as switches in half bridge application. I use STM32F407VG as PWM generator. I used TIM1(TIM1 CH1 and TIM1 CH1N) in order to generate two complementary PWM signals to switch Mosfets. ...
-1
votes
1answer
151 views

Algorithm for calculating prescaler and period of a timer

I want to set frequency of a timer in a microcontroller. Frequency is determined by Prescaler and Period (ARR). Both of these are 16bit integer numbers. $$f_{tim}=\frac{f_{clock}}{prescaler\cdot ...
2
votes
3answers
91 views

555 Astable output staying high

I have a ICM7555 with a 12 V supply in an astable circuit. When ENABLE goes high, I want my output to be high for a given amount of time, then carry on as a normal astable from there. So I have a ...
2
votes
1answer
202 views

DMA request is ony done 1 time in STM32 - Even if I have check marked it as Circular Mode

Cause for writing this question: I think I found a bug. This happens when I try to enable DMA for SDADC and Input Capture. Introduction: I'm using STM32F373VBTx processor and it working great! Except ...
0
votes
0answers
35 views

TPL5110 autoshutoff

I am planning to use TPL5110 (Adafruit breakout) with a LoRa-based soil sensor, to make it energy efficient for battery use. I want to turn on the sensor box after every hour to send data and shutoff ...
1
vote
1answer
30 views

The idea of instantiating posix timer for each command to send and there are multiple commands

I'm writing a linux-based app using posix timers, and the idea is to send certain commands over UART every specific intervals. For instance, <CMD-A> needs to ...
1
vote
2answers
119 views

Are 7555 inputs protected internally by diodes?

I've tested the inputs of a 7555 with a diode tester and I could read a 0.7V/0.6V drop between each input and GND and each input and VCC. Something that suggests that they are protected for over/under ...
0
votes
1answer
65 views

Astable 555 Timer how to create longer pulse at reset/beginning/turning on

I would like to build simple 555 based fan controller. The requirements are: at start the controller generates one longer pulse (which can be configurable) after one longer pulse it generates PWM ...
1
vote
1answer
27 views

timer mode 1 and edsim giving different result

IN 8051, Timer 0 in mode 1, if the maximum count reaches, the timer should displayed with 0000H, and should stay 0000h until we stop it and start again . But with this program ...
2
votes
4answers
209 views

Would using the output of a 555 timer to charge/discharge its capacitor work?

Background I'm relatively new to electronics and playing around with a 555 timer. I found that for astable operation, all sources I've seen recommends the following design (with different resistor and ...
1
vote
1answer
42 views

Triggering a transistor when received an X amount of 12v signals within a given time frame

I want to be able to close the electric tailgate on my car using my keyfob (this functionality is not possible from the factory). Coming from a software developer background, of course I could use ...
1
vote
1answer
83 views

A question on timers in 8051

Suppose the timer 1 of 8051 has finished counting, and raised TF1. Since it rolls back to 0, so currently TH1=00,TL1=00, and assume the bit TR1 is still set. At this moment, if we just clear the TF1 ...
0
votes
1answer
58 views

How to connect the output of the 555 in monostable mode to an optocoupler?

I currently have the following schematic for my circuit: Link to the simulation. On the simulation everything is working pretty good. The output of the 555 which is in monostable mode is giving ...
2
votes
2answers
155 views

How to get a single pulse for 10 milliseconds?

I am trying to get a single pulse of 10 milliseconds on the output of my 555 timer. I following is my schematic: I am supplying 12 V for Vcc. The value of Resistor R and capacitor C is 100 ohms and ...
1
vote
1answer
260 views

STM32 timer triggers interrupt immediately aftern CR1->CEN first enable

As is described in STM32: Timer interrupt works immediately, the STM32 timers don't work correctly for their first interrupt. I am using a nucleo STMG070RB. Configuring TIM7 (which is a basic timer) ...
0
votes
1answer
59 views

Using TSOP17 and 555 to measure distance

I am trying to design a simple circuit that measures distance. I will use an IR emitter and an IR reciever photodiode, and just measure the time between the moment the pulse was sent and when it was ...
0
votes
2answers
97 views

Using boost converter and battery to power Peltier device

I designed a boost converter using a 555 timer in order to power a Peltier device. This is mostly just for fun and to understand circuits a bit better. I ordered all the parts so that they are the ...
0
votes
2answers
212 views

Astable 555 circuit always on, not oscillating

It has been quite a while since I've used a breadboard or looked at circuits (probably 20+ years since high school and college physics.) I'd like to think I know how they work, but something isn't ...
1
vote
2answers
74 views

Multiple timers with ultra low power

I want to blink 3 different coloured LED's with different timing repetitions. Red - every 2 minutes. Green - every 25 minutes. Blue - every 2 hours. Components in the circuit:- 3 different coloured ...
0
votes
0answers
60 views

Why timer (tmr2) calculated for a 1 sec delay produces a much higher delay when running a clock

Below is the code I used using TMR2 to display a clock. I calculated the parameters required so TMR2 will give a 1 sec delay. However, I noticed the pin enable delay function ...
0
votes
1answer
68 views

Timer maximum and minimum resolution

I am having a development board and it has system clock of 32 bit timer 48Mhz .if i want to find the maximum resolution with pre-scale value how to find it. This pre-scale has 16 bits and how could i ...
4
votes
2answers
870 views

Why doesn't the switch command in this code work?

I want to create a clock using a timer (TMR2) to do the calculation and display current time. I have a problem dealing with the switch statement and couldn’t ...
0
votes
1answer
41 views

300ns Pulse Generator to Drive LED

I wanted to use a 555 timer in astable mode to generate a 5V signal to flash an LED on and off. This works fine when the pulse length of the LED is in seconds or milliseconds. But this got me thinking ...
0
votes
0answers
26 views

What Happens when PWM Period register and Compare register is also loaded with same value

Consider, PWM engine based on timers, PWM period register is loaded with 0x3FF (10bit, specifies the period of pwm frequency) and compare register( to vary the duty cycle , when timer count = cmp ...
0
votes
2answers
73 views

How can I hold Vcc logically for a while? [closed]

I want to hold Vcc at 5 volts for approximately 35 seconds. I can set this with a capacitor and r-c circuit. Assume I'm not take too much current from the capacitor, about 5 uA. But, during 35 seconds ...
1
vote
1answer
133 views

Is there an easy way to oversample encoder input in STM32 microcontrollers?

I need to oversample the encoder input. Currently the single channel resolution is 2500 pulse/rev, thus combined channel resolution is 5000 pulse/rev. I need more or less 10 times higher resolution. I'...
0
votes
2answers
172 views

How to develop a compact multi function timer like 35238-MP?

There are many timer circuits available in the internet using IC555 or IC 4060 also using microcontrollers like arduino, or even using only mosfet. I also already made a simple timer using IC555. ...

1
2 3 4 5
20