Hello Everyone
I'm relatively new to electronics but am an experienced programmer. I'm currently working on an Arduino weather station project and making good progress. However, I am having problems with a reed switch based rain gauge. For various reasons I don’t want to use an Arduino interrupt (saving them for another function) to monitor the rain gauge, so I have been experimenting with using a flip flop IC.
I just happen to have a 74HC74 D Type flip-flop in my collection which I bought years ago for another (unfinished) project. I have not used a flip-flop before and so having problems understanding the IC. I have spent considerable time Googling and experimenting with the IC, all to no avail.
Basically, I want to connect one pin of the rain gauge to ground and the other pin to +5V, that in turn connecting to the SET pin of my IC. So when the rain gauge tips there will be a short pulse of +5V hitting the SET pin. This should hopefully cause Q1 to go HIGH and stay high until my Arduino sketch reads it and then causes the RESET pin to go high which should reset the flip-flop.
I'm however having problems understanding the IC. I know that the 74HC74 has a clock pin but I just want to use it as a standard SR flip-flop. This is what I have tried so far.
Experimenting with the flip-flop lighting an LED when SET goes HIGH...
PIN1 (RESET) — To Arduino so it can be reset with +5V
PIN2 (DATA) — to +5V
PIN3 (CLOCK) — NOT USED
PIN4 (SET)— Quick pulse of +5V to set
PIN5 (Q1) — TO LED
PIN6 (Not Q) — NOT USED
PIN7 (GND) — to GROUND
PIN14 (VCC) — to +5V
However, connecting as above I cannot get the flip-flip to set or reset correctly. Initially, I thought that the IC might have been faulty so I tried various other 74HC74 IC’s. All to no avail. I have even tried this setup using an online circuit simulator, of course, it does not work.
Am I misunderstanding something? Is it not possible to use this IC as a standard SR flip-flop? If not, can anybody recommend an IC?
I hope this makes sense and I appreciate any help.
Kind Regards
Nikki
I'm relatively new to electronics but am an experienced programmer. I'm currently working on an Arduino weather station project and making good progress. However, I am having problems with a reed switch based rain gauge. For various reasons I don’t want to use an Arduino interrupt (saving them for another function) to monitor the rain gauge, so I have been experimenting with using a flip flop IC.
I just happen to have a 74HC74 D Type flip-flop in my collection which I bought years ago for another (unfinished) project. I have not used a flip-flop before and so having problems understanding the IC. I have spent considerable time Googling and experimenting with the IC, all to no avail.
Basically, I want to connect one pin of the rain gauge to ground and the other pin to +5V, that in turn connecting to the SET pin of my IC. So when the rain gauge tips there will be a short pulse of +5V hitting the SET pin. This should hopefully cause Q1 to go HIGH and stay high until my Arduino sketch reads it and then causes the RESET pin to go high which should reset the flip-flop.
I'm however having problems understanding the IC. I know that the 74HC74 has a clock pin but I just want to use it as a standard SR flip-flop. This is what I have tried so far.
Experimenting with the flip-flop lighting an LED when SET goes HIGH...
PIN1 (RESET) — To Arduino so it can be reset with +5V
PIN2 (DATA) — to +5V
PIN3 (CLOCK) — NOT USED
PIN4 (SET)— Quick pulse of +5V to set
PIN5 (Q1) — TO LED
PIN6 (Not Q) — NOT USED
PIN7 (GND) — to GROUND
PIN14 (VCC) — to +5V
However, connecting as above I cannot get the flip-flip to set or reset correctly. Initially, I thought that the IC might have been faulty so I tried various other 74HC74 IC’s. All to no avail. I have even tried this setup using an online circuit simulator, of course, it does not work.
Am I misunderstanding something? Is it not possible to use this IC as a standard SR flip-flop? If not, can anybody recommend an IC?
I hope this makes sense and I appreciate any help.
Kind Regards
Nikki