Heart Me - MicroMedic 2013 (by whisk0r)

Cranquistador tymkrs, a nurse/engineer, has created a tiny anatomically-correct (down to level of the Purkinje fibers!) heart-shaped LED gizmo which displays 17 different heart rhythms – and lets you FEEL them too.

Honestly, if this came with a little remote control shaped like a defibrillator paddle, I’d have to get one for Mrs. Cranquis’ next Valentine’s Day gift. 

Check it out!

EDIT: Here’s a 2nd video, which shows the LEDs in better lighting.

Working on the LED Heart: 2AVB Type 1 & 2, 3AVB

So assuming normal sinus rhythm is the following:

  • P Wave: 80ms
  • PR Segment: 50-120ms - I’ll use 100ms for a PR Interval of 180ms
  • QRS: 80-120ms - I’ll use 100ms
  • RR Interval: 0.6-1.2s but taking away the 280ms from the PQRS, that leaves us with 720ms assuming a RR of 1second.

Second Degree Atrioventricular Block Type 1 Code:

So with 2AVB Type 1, what happens is the PR intervals increase, increase, increase, then drop a QRS beat.

This code may have to change because I adjusted the T-P intervals to maintain the same time per beat - but according to this ECG, each beat goes progressively longer - so actually it’d be easier for me to just have left the T-P intervals the same.

Second Degree Atrioventricular Block Type 2 Code:

So this one essentially is where there’s no lengthening of the PR interval, there are just dropped QRS complexes. 

This is pretty dangerous because you never know when there’ll be a complete block between atrium and ventricles.  That these look to be 3:1 or 6:1 conduction doesn’t mean that it couldn’t become 0 conduction.

Third Degree Atrioventricular Block Code:

So with this, I spawned off two cogs - and this is accurate in how Third Degree AVB functions.  The atrium go at their own rate, the ventricles go at their own rate.  There is zero communication between the two.  I had the rate of the atrium go at 60bpm.  And the ventricles were somewhere like 37bpm or so because the intrinsic rates of the ventricles are 20-40.  This of course is dangerous because you don’t have efficient filling of the ventricles from the atrium pumping their blood through.  And because you never know when the ventricles will start fibrillating from lack of cohesiveness.

Last few rhythms: Junctional Rhythm and Sinus Rhythm with Bundle Branch Block!


Just in time for my 9,000-follower mark: It’s DR. CRANQUIS’ CHRISTMAS SURPRISE: Over an hour of audio-only interview of yours truly (with voice disguised a bit) containing:

  • on-the-spot answers to reader questions
  • discussions about telemedicine and whether doctors will be the first to go in a zombie apocalypse
  • a link to Dr. Cranquis’ personal never-before-shared (because it’s downright bizarre) other Tumblr blog.
  • Bonus: I sing a song that I wrote for my other blog, near the end of the interview.

Consider this my early Christmas present to all of my Constant Readers. Enjoy!

(and a HUGE thank-you to Addie “tymkrs” for offering me this interview opportunity – what a fun and flattering experience!)

First Spin!

So if you’ve followed along with some of our more recent videos, posts, and such - you’ll know that I’ve started programming some of my first projects on the Parallax Propeller platform. 

Welp, to document this process of my incessant Q/A sessions, we’ve decided to record it for you in our new Parallax-sponsored podcast called First Spin.  You can find it on firstspin.tv and includes myself, @whixr, and @RoyEltham. 

It’ll be 30 minutes of my asking questions from a complete n00b perspective and Whisker and Roy trying to explain it to me so that my eyes don’t glaze over.  It’ll be my learning about the propeller chip as well as how to program in Spin, its programming language. 

We’ll be releasing it on Tuesdays and if you have any questions about what we’re going over - let us know!


Two Stage FM Transmitter Bug - Preamplifier

So it’s been a while but I thought I’d analyze another schematic similar to the last transmitter bug.  @JohnS_AZ also sent this one to us and it is a two stage FM transmitter bug - supposedly more powerful and capable.  It works with a 9v battery and claims to have a range of up to 1km in the open.

So as in the first transmitter we looked at, the microphone from where our mic level input comes from is an electret microphone.  The preamplifier circuit is quite similar to the one we’ve seen before:

The main differences you’ll note are in the values of the resistor from the power rail to the mic and from the power rail to the collector electrode of the transistor.  I’m not sure of the significance, but perhaps because FM transmitter 2 has three amplification stages as opposed to two, the electret microphone is provided with less power than FM transmitter 1.

You’ll note that the output of the transistor preamplifier stage still goes through a 100nf capacitor as before.  The one new thing we see is a 100nf coupling capacitor connecting the power rail to ground.  This must be some sort of dc filtering capacitor that helps to get rid of any additional noise.

And to reiterate some of what we learned from analyzing the last preamplifier circuit, the initial 22nf capacitor filters out DC currents and allows AC currents (our audio signal) through.

Then, the 22k resistor and 1M resistor do what is known as biasing the base electrode of the transistor.  Remember that it is both the signal and strength of the signal going into the base electrode that determines to what degree the transistor amplifies that secondary current that becomes the output of that stage.

This handy gif was what helped me realize that the two currents were separate but that the one going to the base electrode determined/allowed the amplified current to proceed.

Next up! The adjustable/tunable tank circuit and amplification 1 stage!


A123 batteries - Lithium Iron Phosphate Batteries

So another battery request from @ajfabio was on a123 batteries.  And I’ve never heard of these except through a friend, and even then, it was only about the company.  So here goes!

Many will equate them with lithium-ions but more accurately, they are Lithium iron phosphate batteries (LiFePO4). They have a lower average voltage (3.3V/cell), can be quick-charged (10-15 minute charges), can rival even Li-poly batteries in current delivery (40C+!), and are safer and cheaper.

It seems that the cathode is infused with iron phosphate material.  The following graph looks at the energy densities of different types of batteries.

So unlike using a cathode with lithium cobalt oxide, it’s lithium iron phosphate instead.  To increase electrical conductivity, companies have been doping this with carbon, aluminum, niobium, and zirconium.  And it is these doped lithium iron phosphate cathodes that are being sold.

Unlike other lithium ion batteries these are safer as they have more stable thermal and chemical makeups.  Per wiki, due to significantly stronger bonds between the oxygen atoms in the phosphate (compared to the cobalt), oxygen is not readily released, and as a result, lithium iron phosphate cells are virtually incombustible in the event of mishandling during charge or discharge, and can handle high temperatures without decomposing.

And despite the graph showing the lower energy density - this is over the first year of life.  This disadvantage is offset over time by the slower rate of capacity loss of LiFePO4 when compared with other lithium-ion batteries.  So for example:

  • After one year on the shelf, a LiFePO4 cell typically has approximately the same energy density as a LiCoO2 Li-ion cell. 
  • Beyond one year on the shelf, a LiFePO4 cell is likely to have higher energy density than a LiCoO2 Li-ion cell due to the differences in their respective calendar-lives.

If you remember how lithium ions intercalated and de-intercalated with the lithium cobalt oxide in a normal li-ion battery, instead of lithium cobalt oxide, it’s LiFePO4.

LiFePO4 is an intrinsically safer cathode material than LiCoO2 and manganese. The Fe-P-O bond is stronger than the Co-O bond, so that when abused, (short-circuited, overheated, etc.) the oxygen atoms are much harder to remove.  This also helps with higher speeds of ion migration.

As lithium migrates out of the cathode in a LiCoO2 cell, the CoO2 undergoes non-linear expansion that affects the structural integrity of the cell. The fully lithiated and unlithiated states of LiFePO4 are structurally similar which means that LiFePO4 cells are more structurally stable than LiCoO2 cells.

No lithium remains in the cathode of a fully charged LiFePO4 cell but in a LiCoO2 cell, approximately 50% remains in the cathode. LiFePO4 is highly resilient during oxygen loss, which typically results in an exothermic reaction in other lithium cells.

Cool.  Many thanks to wiki for understandable information!


Ham Radio: Electrical Safety!

Last chapter before the glossary!!  I see light at the end of this wondrous tunnel :).  So respect electricity.  AC and DC current can cause shocks and burns if you’re not careful and depending on the voltages, can range from insignificant to deadly.

Voltage is what causes the charge to flow but doesn’t shock all by itself.  Essentially, as the voltage applied across your body varies, so does current.  This is because different parts of your body conduct different.  The interior of your body conducts quite well as it is mostly salty water.

  • Current                   Reaction
  • < 1milliamp              Generally not perceptible
  • 1                           Faint tingle
  • 5                           Slight shock felt, not painful but disturbing.  Average
  •                              person can let go but strong involuntary reactions can
  •                              lead to other injuries.
  • 6-25 (women)          Painful shock, loss of muscular control; the freezing
  • 9-30 (men)              current or can’t let go range.     
  • 50-150                   Extreme pain, respiratory arrest, severe muscular
  •                             contractions.  Death is possible.
  • 1000-4300              Heart stops.  Muscular contraction and nerve damage
  •                             occur; death likely.
  • 10000                    Cardiac arrest, severe burns, death probable.

The most dangerous currents are those that travel through the heart such as hand to hand or hand to foot.  Electrical currents of 100mA or more can disrupt normal heart rhythm.  Depending on the resistance of the path taken by the current, voltages as low as 30 volts can cause enough current flow to be dangerous.

And burns caused by dc current or low frequency ac current are a result of resistance to current in the skin, either through it or along it.  The current –> heat –> burn.

These are obviously preventable if there’s no way for you to come in contact with an energized conductor.  Remove, insulate, secure loose wires and cables before testing or repairing equipment.  Never assume equipment is off or de-energized before beginning your work.  Check with a meter or tester first.  And if you do need to work on equipment with the power on - the following steps are the manual’s suggestions:

  • Keep one hand in your pocket while probing or testing energized equipment and wear insulating shoes.  This gives current nowhere to flow in or along your body.
  • It’s easy to have bad habits while working with low voltage or battery powered equipment.  Be extra careful when changing to work around higher voltages.
  • Never bypass a safety interlock during testing unless specifically instructed to do so.  These remove power when access panels, covers, or doors are opened to hazardous areas in equipment.
  • Capacitors can store charge (as we know) after a charging circuit is turned off, presenting a hazardous voltage for a long time.  Make sure all high-voltage capacitors are discharged by testing them with a meter or use a grounding stick to shunt their charge to ground.
  • Storage batteries release a lot of energy if shorted.  Keep metal objects such as tools and sheet metal clear of battery terminals and avoid working on equipment with the battery connected.
  • Remove unnecessary jewelry from your hands.  Rings can absorb RF energy and get hot in a strong RF field.
  • Avoid working along around energized equipment and remember that electricity moves a lot faster than you can.

What do you do? Turn the power off.  Install a master ON/OFF switch for AC power to your station and work bench.  Learn how to turn it off at the master switch and circuit-breaker box.  Learning CPR is probably a good idea too.


Ham Radio: Interference!

I know in football games they call interference, but I don’t know what that means.  So.  Ham Radio instead!  Interference is caused by noise and signals.  Noise interference is caused by natural sources such as thunderstorms, signals unintentionally radiated by appliances, industrial equipment, and computer equipment.

Interference from nearby signals (QRM) is part of the price of frequency flexibility.  If hams operated on assigned and evenly spaced channels, there would be much less interference.  They would also be overloaded quite often!  But, most interference is manageable.

  • Common sense and courtesy - No one owns a frequency
  • Good filters to reject interference
  • Be aware of other activities such as special events, DXpeditions, and contests

Harmful Interference

If a transmission seriously degrades, obstructs, or repeatedly interrupts the communications of a regulated service, that’s considered harmful interference.  Each ham should try to minimize the possibility of causing this.  Reports of interference such as transmitting off-frequency or generating spurious signals (splatter and buckshot) should be checked out.  Remember, when testing/tuning a transmitter, keep test transmissions short.

Sometimes, propagation on a band can change due to ionospheric or atmospheric conditions.  A signal that wasn’t there a few minutes ago may suddenly become strong enough to disrupt your contact.  Changing antenna direction can allow a previously rejected signal to be heard, etc.

The distortion here is most likely caused by accidental interference from ionospheric/atmospheric conditions.

If you are the one dealing with interference, try changing your frequency or changing antenna direction.  And if you’re the one causing it, apologize, identify and take the needed steps to reduce interference.  This could require you to change frequency, reduce power, or move your antenna.

Willful Interference

Simply put, intentionally creating harmful interference is called willful interference and is never allowed.  The interference doesn’t have to be aimed at one specific contact or group.  Anytime communications are deliberately disrupted, that’s willful interference.  For example, intentionally transmitting spurious signals by overmodulating is willful interference.  Common sense and maturity folks.


Beta? Hfe? Gain? 2N3904s! I think its transistor theory...

So a bunch of the folks were talking about engineering and electronics and the like in our irc room and I got to talking about how engineers love smashing a whole bunch of letters and numbers together to make chip names sound ridiculous.  So I asked folks what their favorite transistor was for audio applications and instead of getting 10 different kinds, a few of them agreed on the 2N3904 (spoilsports :p).

Anyway so somehow they got to explaining how to find the DC current gain of a transistor based on its datasheet and such:

Explanation 1:

Per @mgburr and Lancelot: A 2N3904 transistor’s beta max value is 150 and min value is 100.  When figuring out DC current gain, the beta value is part of the formula.  In the sheet above, it is also known as as hFE.  (hFE = beta = gain for easier understanding)

So if you need to build an amplifier with a gain of 300, you set up 3 transistor stages.  A good rule of thumb is to build it using the minimum beta value instead of the max:

[100] + [100] + [100] = 300…So even if it’s at its minimum, it still has enough gain
[150] + [150] + [150] = 450…If all of the transistors were at their max, gain = 450

If you based the gain off of the maximum beta value instead of minimum:

[150] + [150] = 300….  This is possible if it works at its maximum gain BUT
[100] + [100] = 200….  This wouldn’t give you enough gain!

Now hFE and beta cannot be greater in value than allowed by the gain.  Otherwise you get noise caused by saturation and clipping of the signal

If we look further into this, beta/hfe/gain = the ratio of the current going through the collector/the current through the base.

Explanation 2: 

Per @brainwagon: Transistor Man looks at the current going from the base to the emitter.  He then adjusts the collector/emitter current to be hFe * Ib. 

  • hFE is found on the datasheet (also known as beta/gain) as highlighted in the above datasheet.
  • Ib is the current at the base.

These are 2 ways to prove that hFE=Gain

Our players are:

  • Current at the base = Ib
  • Current at the collector = Ic (or hFe*Ib)
  • Gain = Gain

First explanation from @mgburr and Lance: Beta/hFE/Gain = the ratio of the current going through the collector/the current through the base

  • Gain = Ic/Ib
  • Gain = (hFe*Ib)/Ib
  • Gain = hFe

Second explanation from @brainwagon: Collector/Emitter current = hFe * Ib

  • Ic = hFe*Ib
  • hFe = Ic/Ib
  • hFe = (hFe*Ib)/Ib
  • hFe = hFe = Gain



Free Indie Game: Quench v0.1.0a

Here is a link to an early alpha test for a simple game we built in a few hours last night. Let us know what you think, and any additions you would like to see.  We will be posting several of these beginnings.  Your feedback will determine which projects get the most attention, so vote with your voice!



10.25 Ham Lesson o' de day

Capacitors store electrical energy by way of capacitance and is measured in farads - The Farad is the amount of charge capacity that a capacitor can hold.  Another way I understood it was that it’s the amount of current that it takes to increase voltage within the capacitor by 1volt/second.  IE how much current has to pass into the capacitor before the rate of voltage increase = 1 volt/second.

Capacitor Part 1:

@whixr mentioned to me that capacitors are often used to allow AC current but not DC current, and so are known as DC blockers.  So another metaphor that he’s come up with is the following.  Capacitance is like a rubber membrane in a barrel (brown line).  Pipes are attached to each end of the barrel and a pump connects those pipes.  You can only pump water in one direction so much, then the rubber wall will not stretch anymore (stretching possible according to dotted black lines).  Picture:

With DC current, that’s like pumping water from only the left to the right side (for instance).  The water can only go against the rubber membrane so much, before it stops.  If however, you have AC current, it’s like the pump pumping water from the left, then the pump pumping water from the right.  And the water ends up going back and forth.  So that anything in between the pump (power source) and barrel (capacitor) can take advantage of that current.  So too capacitors do not allow DC current through and only allow AC current to work upon it.

Capacitor Part 2:

This is of my own making from studying capacitors and from what Whisker’s told me about capacitors.  Essentially a capacitor’s like a cul-de-sac, and kids running into the cul-de-sac is like electrons going into one side of the barrel or electrode.  They can’t go past the cul-de-sac (re: DC current).  The only way is to go back the way they came in (re: AC current).

Capacitor Part 3:

So we have a sandwich: two conducting surfaces called electrodes and between these two electrodes, an insulating dielectric (wood/rubber/air).  Remember, conductors allow current to flow easily and insulators do not.

This is when no power is running through yet - when both electrodes have the same number of electrons as the other, and therefore no voltage/electric potential has been induced.  (Our dielectric is Gandalf)

And I’ve gone and gotten the battery on and as always, the current will go towards the positive electrode.  Current will go in the only direction it can towards the negative electrode of this capacitor.

Well now that you’ve gotten all of the electrons on one side of the equation, there’s this electric field that’s been created, and it’s got a huge amount of energy potential behind it.  I’ve gone ahead and taken the battery away.

And when you end up putting both ends of the capacitor on the same conductor, you get a huge rush of electrons rushing back to balance things out = pow! bam! crackle!

Capacitor Part 4:

When a capacitor is connected to a circuit, as current flows into it, it develops an electrical potential (seen above) - this is known as voltage though measured in farads (amount of current to increase the voltage in the capacitor by 1volt/second).  Remember that the capacitor always wants to “reequilibrate” or “leak” the current it’s been given back into the circuit.  That’s why capacitors are known as voltage smoothers.  Example:

Alright.  So we’ve got a power source that’s not very reliable - sometimes it gives out a certain amount of power, and when the weather’s bad, it gives out another amount of power.  All within a certain range, but not precise all of the time.  Everything’s connected to ground.  And we’re trying to light a light bulb.  So when the power source is pushing forth too much power, it gets sucked up by the capacitor and the capacitor’s “rubber membrane” absorbs that extra energy.  However, should the voltage falter from the power source, the capacitor then takes up the slack and releases its energy into the circuit.  This allows “voltage smoothing” to occur, and the light bulb would never know the difference!

These are the more common types of capacitors as well as different specs for each. (http://i.cmpnet.com/planetanalog/2007/06/C0201-Table2.gif

Next article - how to read capacitors!


Diode Junction Capacitance

So in trying to answer why germanium diodes are used for crystal sets, I came across the concept of junction capacitance - that is - a diode acting as a capacitor.  I thought I’d explore this more so that I wouldn’t make the next post a ginormous one.

Remember all the hoopla about:

  • Forward bias: Putting the power source such that charge is able to flow through the diode
  • Reverse bias: Putting the power source such that charge is not able to flow through the diode

Well, we’re going to focus on reverse biasing today when talking about junction capacitance.  As you remember capacitance is two conductors separated by an insulator/dielectric.  Well, when you reverse bias:

You end up with a depletion region which if you think about it is like a dielectric.  Does this then look familiar? 

  • Capacitor = 2 conductors with a dielectric in between? 
  • Diode in reverse bias mode = 2 semiconductors with a depletion region in between?

So there is capacitance that occurs!  But what does this mean?  Essentially, if the junction capacitance is too large, it will reduce the effectiveness of the circuit at high frequencies; the whole waveform will pass through the diode-turned-capacitor instead of being demodulated. 

  • Note: As the frequency of a current increases, the capacitor passes more charge across the capacitive plates in a given time resulting in a greater overall current flow through the capacitor appearing as if the internal resistance of the capacitor has decreased:


Why does any of this matter to AM radio?  Because AM radio frequencies are quite high.  And therefore the diode cannot have a large junction capacitance otherwise it will allow a modulated signal through instead of just the audio signal.  Thus this is something that we still need to consider.


32.Rules, Regulations, and Guidelines on RFI

Firstly, make sure you’re not the problem!  Make sure your station is in good working order with appropriate grounding, filtering, and good quality connections.  You can also eliminate interference to your own home appliances first by demonstrating that you aren’t interfering with your own devices (haha).

Eliminate sources of interference in your own home, such as worn out motor brushes, poorly filtered power supplies, etc.  This way, you know it’s not those things that are causing the interference.  If you happen to be potentially radiating interference to your next door neighbors, the following suggestions may help:

  1. Start by making sure it’s really your transmissions that are causing the problem.
  2. Offer to help determine the problem - detection, overload, or harmonics.
  3. If you’re sure that the noise is caused by a neighbor’s equipment, help determine the source of interference - severe noise often indicates defective equipment that could be a safety or fire hazard. 
  4. Be nice :p

Rules and Regulations!

Part 15 of the FCC’s rules governs the responsibilities of owners of unlicensed devices that use RF communications (cordless phones/wireless data transceivers), or unintentional radiators.  These are called part 15 devices.

Basically what Part 15 says is:

  1. An unlicensed device permitted under Part 15 or an unintentional radiator may not cause interference to a licensed communications station.  Its owner must prevent it from causing such interference or stop operating it.
  2. An unlicensed device permitted under Part 15 must accept interference caused by a properly operating licensed communications station, such as from an Amateur Radio station

Essentially, what this means is that as long as the station is operating properly under the FCC’s rules, then the operation is protected against interference by and complaints of interference to unlicensed equipment.  They would be responsible for getting rid of the interference on their end - even a tv station.

It is also the owner’s responsibility to eliminate interference caused by their own device, even with assistance from you.  These rules are printed in the owner’s manual for all unlicensed devices and are available on the FCC website.

That means that hams end up getting it pretty cush even if neighbors don’t like that rule much!


Conventional Flow vs Electron Flow Theory

So in working on my foxhole radio - I realized I needed to look at diodes a bit more as I was making essentially a DIY diode with the pencil and razor blade.  And in looking at diodes, I realized that something just didn’t add up.  And perhaps by the end of this post still won’t add up.

I’m going to further preface this by saying I think having two different theories is dumb and stupid.  Especially when people are trying to learn this stuff for the first time!

So video below shows what I understand:


The question is if current/electrons go from the negative side of the battery to the positive side of the battery, how do diodes only allow current to go from anode to cathode (or P to N)? 

Alright, so after digging around /way/ too much, it seems that there are TWO different types of theories - the right one and the wrong one that people keep around because it’s been around for a long time.  I seem to be referencing both with my question.  Let’s start with the wrong one:

Conventional Flow Theory

The idea was that charge flowed from something with positive charge to something with negative charge (though negative charge is due to having more electrons).   And because we associate “positive” with “surplus” and “negative” with “deficiency,” engineers decided to retain the old concept of electricity with “positive” referring to a surplus of charge, and label charge flow (current) accordingly. 

Electron Flow Theory

This is clearly not how batteries work.  So another theory called the Electron Flow Theory came about to show how electrons actually moved - which was from negative to positive (as the electrons moved from the negative to the positive pole):


Ahh…much better.  But then we have the diode issue - below is what we would expect of a normal diode set up:

So when the + end of the battery is attached to the anode, and the - end of the battery is connected to the cathode, we get current capable of lighting up a bulb!

If we label this according to conventional flow notation - everything makes sense - current goes from the surplus side to the deficient side of things and current goes through the diode as expected.

But! If we use electron flow notation - the way electrons actually “move” around in a circuit we get the following.  And it looks completely backwards to how we’d expect current to move in a circuit with a diode:

How has it been explained away?

So some people say, just deal with it or that’s just how people notate it.  But if the electron theory shows current flowing in the very direction that a diode’s supposed to block it, how can /anyone/ ignore it?!  And with almost everything else we talk about where/how the electrons move through a component…but somehow the definition of a current changes for diodes? *confused*  Here are some explanations others have given:

  • In a semiconductor it is sometimes useful to think of the current as due to the flow of positive “holes” (the mobile positive charge carriers that are places where the semiconductor crystal is missing a valence electron).
  • In semiconductors, when we say current flows from + to -, we don’t mean the electron flow, we mean the hole flow. We know positive charges come from protons and negative charges come from electrons. But we also know that protons do not flow since the proton is stuck in the nucleus, therefore positive charges do not physically flow. Electrons on the other hand, do flow since they can jump from atom to atom so negative charges can flow. But when the negative charge jumps, it leaves behind a “hole” of positive charge that originates from the proton in the nucleus which no longer has its charge canceled to zero because the electron isn’t there anymore. As the electrons move in one direction and leave behind holes, it will appear as though the holes flow in the opposite direction. This hole flow is conventional current.  So it’s hole flow for entire circuits and not electron flow?
  • Current is positive charge.  So even if protons don’t move, the fact that electrons are moving from the negative to positive end of a diode means that a positive charge is “moving” from the positive to negative end of a diode.
  • The latest explanation is that direction is less important than how they are placed in the circuit - that is relative to the polarity of the power source.  So if they are placed in a configuration that allows current flow through them, so be it.  But if the polarity reverses, it’ll block current.  So if you have an ac current, it will seem as if the diode is blocking current from one “direction” but not the other.  Thanks to @whixr for his help :p


  1. http://www.opamp-electronics.com/tutorials/conventional_versus_electron_flow_1_01_07.htm
  2. http://mste.illinois.edu/murphy/HoleFlow/HoleFlow.html
  3. http://www.electro-tech-online.com/general-electronics-chat/90846-help-conventional-flow-vs-electron-flow.html
  4. http://www.allaboutcircuits.com/vol_3/chpt_3/1.html
32.Direct Detection

In continuing with looking at specific types of interference…I give you direct detection!

So strong RF signals can pretty much interfere circuits through electronic components such as transistors, diodes, and ICs.  Just as with the crystal set radio, radio waves can induce small currents and voltages in the circuit.  Those extraneous voltages and currents can potentially upset its operation or distort an audio signal. 

The symptoms of direct detection are thumps or pulses when a transmitter is turned on and off:

  • AM/SSB: You may hear a garbled voice
  • FM: These may sound like hums

So obviously to eliminate RFI caused by direct detection, the RF signals must be prevented from entering the equipment.

This type of interference is most common to telephones because they’re rarely designed to reject RF signals and so low-pass filters connected at the telephone’s modular jack are the best way to reduce RFI from direct detection.

This reminds me of the time I heard truckers talking while using my landline.  I talked back to the trucker and I swear they could hear me - but the plausibility is questionable :p


How to use a breadboard

Before you start laughing.  No! I don’t know how to use a breadboard :p.  Whisker has explained it to me at least three times but all of the holes end up confusing me and then we just start from square 1.

So! The magic of a solderless breadboard is that you don’t need to use solder to put your circuit parts together - go figure.  It consists of electronically connected regions that you can plug your components to - kind of a plug and play.  This way if you want to do some experimentation, you just take out one component, and substitute it with another!

This is a breadboard.  In fact it looks almost like mine except mine seems to be twice as long thanks to @JohnS_AZ. 

The text is a bit small but essentially says:

  1. The horizontal holes on each side of the breadboard are connected together.  Anything plugged into these five holes will still be electrically connected together.
  2. Note that the horizontal holes on one side of the breadboard don’t connect to the other side.
  3. The vertical strips that run the length of the breadboard are electrically connected.  These strips are usually used for power and ground connections.

+ seems to be used for power and - usually used for ground.  But if you’re connecting a battery to these vertical lines - the + end of the battery goes to the + line and the - end of the battery goes to the - line (as far as I understand).

Now to work on my LM386 audio amp circuit!


    Upcoming Cranquis Interview: Submit your questions by July 2 for possible inclusion!

    Cranquistador-Hipster check!

    Who was “into” Cranquis back before he was really popular? You know, wayyyy back in December of 2011? Back before 11,000 other people had found this blog? Was it YOU?

    If so, you probably remember this audio interview that I did with the nimble-fingered hepcats Tymkrs and Whisker over at zombietech.tv. And we couldn’t leave well enough alone, so… we’re doing another interview next week.

    Once again, Tymkrs is accepting questions from my readers to be asked and answered “live” during the interview taping. If you have a question (zombie-related or not, medical or otherwise, anonymous is fine too) that you’d like to submit, drop her a line in her ask box here before Midnight CST on Monday July 2. Please include the tag “#cranquis” for easy identification. By submitting your question, you give permission for it to (possibly) be selected by Tymkrs and included in the interview!

    Stay tuned for updates on the air-date for the interview.

    Expanding the Heartbeat Project

    I’ve gotten some very kind comments on the @hackaday post featuring my Halloween heartbeat project from other healthcare professionals out there.  It’s so great to see other folks in the profession who are also interested in electronics especially since I usually get blank stares from my co-workers when I talk about my budding interest in programming/electronics.  Scarily enough, I am their token “computer whiz”.

    Be that as it may, some of the commenting folks were interested in seeing this project go further.  So I thought I’d outline what I already have (though taken apart), and what I think would be cool to expand on.

    What I have:

    So I have a program that makes the heartbeats go “faster” or “slower” by changing the amount of time between lub and dub in response to the amount of light on a photoresistor.  It also showed the conduction pathway of the heart and matched it according to the lub-dub.

    What I need to correct:

    • I need to make it so that the timing between lub-dub is the same, but the timing between the lub-dub pairs are different (given differing amounts of light).  
    • Accurate timing of the lighting system to match the milliseconds of physiologic current.
    • I also need to accurately match the lub-dub to when it actually happens.

    What I would like to add:

    • LEDs for the valves so that you can get a visual with the sound
    • More LEDs to flesh out the electrical pathways
    • A knob/switch to select between different rhythms
    • Different rhythms and sounds to go with said rhythms

    Rhythms to have:

    • Normal Sinus Rhythm
    • Sinus Bradycardia
    • Sinus Tachycardia
    • Atrial Fibrillation
    • Atrial Flutter
    • Supraventricular Tachycardia
    • Ventricular Fibrillation
    • Ventricular Tachycardia
    • First Degree Block
    • Second Degree Block Type I
    • Second Degree Block Type II
    • Third Degree Block



    So, as I mentioned yesterday, a special surprise/gift for my Constant Readers is in the works. It’s actually being created by long-time reader tymkrs, and YOU get to be involved – for a limited time. 

    Between NOW and 5 pm US Central Standard Time on November 30 2011 (yes, Matilda, that’s TOMORROW), tymkrs is accepting your Questions for Dr. Cranquis in her Tumblr Ask Box. She will be sorting through your questions and picking out some (a few, more than one, not many, etc) to ask me in a “real-time” Q&A.

    You can submit any question that you’ve ever wanted for Dr. Cranquis to answer – questions about medical school, working in a hospital, being on-call, memorable patients, dating, predictions for the year 2020, House MD, zombies, WHATEVER – but questions requesting medical advice or close-guarded details about Cranquis’ secret identity will not make the cut, so don’t waste your time.

    Further details will emerge when the finished Q&A is, well, finished. Stay tuned! ;)

    Generalities learned from the LM3914N - Courtesy of @JohnS_AZ

    So this IC, as many others, have a whole lot of pins.  And I’m glad that @JohnS_AZ knew what they were and how they worked and I realized that it was because of that knowledge, that things “made sense”.  It wasn’t just oh, this works because the schematic says it’s supposed to.  Thanks to John, I’ve put a slightly more comprehensive explanation together:

    So I wanted to go through the labeled pins and see what new lessons I could learn. 

    Pin 2 (V-): This, as in most ICs, usually means the negative power rail - and this is usually set to ground.

    Pin 3 (V+): This, as in most ICs, usually means the positive power rail.  This is usually pretty much just what is required to power the chip and leds.

    Pin 4 (RLo): This is essentially the low end of the internal voltage dividing tree.  If you’re making a voltmeter, and you want to have the meter measure from 12v to 24v, RLo would be 12v.  You would adjust this reference level by placing a resistor between Rlo and V-. 

    Pin 5 (Sig): This is the signal level - this is the signal whose voltage levels you’re measuring. 

    Pin 6 (RHi): This is the Reference High and sets the high end of the internal voltage dividing tree.  The voltage on this pin also determines how much it will take for the LED bar to light up all of the way (all LEDs lit up).  So if you wanted the meter to measure from 12v to 24v, Rhi would be connected to 24v.  Anything above 24v would still make the LED bar light all the way up.

    Pin 7 (Ref Out): By default, this is the + lead of an internal 1.25v source.  LED brightness is controlled by changing how much current flows through the Vref pin.  

    Pin 8 (Ref Adj): By default, this is the - lead of an internal 1.25v source.  This can be adjusted anywhere up to 12V.  But this is done by adding a resistor or pot between RefAdj and ground.  I thought it might be possible to put RefOut to V+ and have a pot in between to adjust.  This may be important especially if RHi is attached to RefOut.

    Pin 9 (Mode): If this is placed to ground, you have DOT mode.  And if it is placed to the power rail, you have BAR mode.

    A few extra notes:

    • This chip is one you can daisy chain together - to make a super long and more sensitive voltmeter.  So Chip1 Rlo would go to ground, Chip1 Rhi connects to Chip2 Rlo , and Chip2 Rhi connects to some reference voltage for a two-chip 20 LED display.
    • Audio scale only ever gets to 1 or 2v, so we need the top of the divider tree to be lower, in the neighborhood of what we expect the maximum input voltage to be - hence our use of hooking Pin 6 RHi to Pin 7 RefOut
    • The LM3914 chip is linear - it turns on in even steps.  The 3915 is a log chip, the 10 LEDs light at different voltages representing a log scale.  And then 3916 is a special LOG scale set up for use as a true VU meter.  If you look at page 7 on each of the data sheets, you will see that the -ONLY- difference between the chips is the value of the resistors in the divider tree.  So how that divider network, with or without additional resistors on Rhi and Rlo TOTALLY determine what voltages the individual LEDs represent.

    A “basic” lesson.  A comparator compares two voltages - for our purposes, one is a reference off of a voltage divider tree and the other is from the signal.  If the signal is greater than reference, then a HI/ON output goes forth from the opamp, otherwise the output is LO/OFF. 

    • If the + input of the comparator is higher than the - input, the output is off.  If the - input is higher than the + input, the output turns on, and the LED lights do as well.
    • So all of the - inputs of the 10 comparators of the chip are tied together and that’s where the input signal goes.
    • Each + input is connected to a different point in the divider tree, so each one sees a different voltage.  In this chip, each resistor is 1k.  So if Rlo is ground and Rhi is 10v, the first comparator will see 1v, the second will see 2v, then 3v, etc.
    • All of those internal resistors add up to 10k ohms. So if you connect a separate 10k resistor between RHi and 10v, the TOP comparator will now see 5V instead of 10v.  So now, instead of the top LED lighting at 10v, it will light at 5v.
    • If you connect a RHi to 10v, and connect RLo to a separate 10k resistor to ground, now the TOP comparator will see a 10v again, but the bottom one will see 5v.  So now the bottom one LED will not light until the input is over 5v.

    I still have some questions (though I’m not sure how to word them) on the Ref Adj and Ref Out, BUT, for now I’m satisfied :).  And of course, thanks to @johns_az as he was the one who gave me most of this information and answered my questions in an understandable manner.