1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Counter for HeartBeat Monitor

  1. Mar 25, 2009 #1
    I have limited hardware components I can use for this obstacle. Lets say I have precision rectified the input heartbeat signal into a square wave... I am trying to count the number of squarewaves/heartbeats and display them on two 7-segment displays refreshing every 15 seconds...
    I can only use a 4029 Up.dwn counter and a BCD driver to 7 segment display....
    My issue is that the 4029 is going to need to refresh every 15 seconds however !!! the output needs to be in bpm (Beats per minute) which means it is off by a factor of 4... How can i multiply the output by 4 or is there a clever way i can do this with the timer that resets the 4029 every 15 seconds? PLEASE HELP. ive looked everywhere. even minute insight may prove valuable. thanks in advance.

    Can someone verify the frequency of the clock because I read somewhere it is suppose to be 2Mhz minimum and 4 Mhz maximum which would make this task a little different. Thanks
  2. jcsd
  3. Mar 25, 2009 #2
    Okay lets say the input is something like 20 beats for a 15 second interval. that would mean we need an output to the BCD driver to be 80 beats. Could I take the 20 beats and use an oscillator to magnify it by 4 to the input of the Cmos Ic counter? And than again i still have the issue of the minimum frequency accepted by the Ic counter....
  4. Mar 25, 2009 #3
    I was suggested to use D flip flops where the input will pulse and the output will be 4 pulses... Any ideas where this idea came from, moreover how it even works? Thanks
  5. Mar 25, 2009 #4
  6. Mar 25, 2009 #5


    User Avatar

    Staff: Mentor

    Moved to Homework Help.

    Multiplying by 4 in binary is easy. Why?

    A bigger issue for you is doing the Hex to Decimal conversion, unless you can display the result in Hex.
  7. Mar 25, 2009 #6
    why would i have to do a hex to decimal conversion? I think you may have misunderstood the issue.
    I have a square wave as my input that is sampled/counted for 15 seconds, multiplied by 4 and displayed on the 7 seg display which tells the number of square waves passed per minute. This is refreshed every 15 seconds... I just dont know how to multiply a square waves frequency by 4 so that the counter gets the right value and displays the rate per minute.

    and no this is not homework. if i wanted to multiply a binary string by 4, i would shift 2 loggical lefts, i.e. add 2 0s as lsb....
  8. Mar 25, 2009 #7


    User Avatar

    Staff: Mentor

    Okay, semantics. Binary to decimal conversion.

    So you take your binary count and shift it up 2 bits, convert it to a 3-digit decimal number and drive the displays.

    BTW, keep in mind that your simulated heartbeat signal is asynchronous with respect to your 15 second counting clock. What kind of circuit do you need to synchronize those two different domains...? What bad thing can happen if you don't?
  9. Mar 25, 2009 #8
    I understand that... I am going to use a 555 timer in bistable mode to pulse a 1 every 15 seconds which will allow the jamm inputs on the counter to 0000 binary. The heart rate is going to come from an amplifier/filter that comes from a microphone that you place on ur chest near your heart...
    The output for each counter is 4 bits which only represents decimal numbers i.e. 0-9... so shifting would only work if the entire bit stream were continuous for all 8 bits and in binary but its not... The first 4 bits represent a number 0-9 and is the LSB and the second 4 bits represents a number 0-9 as the MSB... so shifting wont work... the signal being counted needs to be multiplied by 4 before being counted and send to display...
  10. Mar 25, 2009 #9


    User Avatar

    Staff: Mentor

    So I guess you are working on two issues now. Is it more efficient in gates to do a contiguous count in binary, shift it up two bits, and then do your binary to 3-digit decimal conversion, or try to do it the way you are now, and figure out how to do the multiply-by-4 with carries in logic after the 3 counters. I'm guessing that option #1 is simpler, but you should draw out each of the 2 options, and figure out which is easiest for yourself.

    Your second issue still has to do with synchronization between your two clock domains. It may well be the case that your assignment is at a basic enough label that they are ignoring clock synchronization issues, and that's okay if it's the case. But if you are looking for some extra credit in a basic class, and a mandatory check-off item in real industry design reviews, you will look into synchronizer circuits for asynchronous inputs into clocked domains.
  11. Mar 27, 2009 #10
    Here is my attempt:

    Im going to add a potentiometer to the 555 timer that is used as an oscillator to mimick the heart rate... This is tempory until i get the electronics together for the actual heart signal...

    I am also thinking of using a single 555 timer with 2 inverters at the output such that after the first inverter, the pulse will be low enabling the latch in the 4511 bcd to 7 seg driver...

    After the second inverter will be a high pulse every 15 seconds which will reset the counter and begin a count for the next period of 15 seconds....

    do you think the propagation delay between the latch being enabled after inverter 1 and the counter being reset for another period after inverter 2 will be enough such that the display correctly displays the value counted for the previous period?
    Last edited by a moderator: Sep 25, 2014
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Similar Discussions: Counter for HeartBeat Monitor
  1. Counter help (Replies: 3)

  2. Encoder counters (Replies: 2)

  3. Asynchronous counter (Replies: 1)

  4. Counters in verilog (Replies: 0)

  5. Design A counter (Replies: 3)