Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 10 of 10

Thread: Teensy digital pins as primative interrupt-based antennas?

  1. #1
    Senior Member
    Join Date
    Oct 2019
    Posts
    178

    Teensy digital pins as primative interrupt-based antennas?

    I recently had a disaster attempting to use buttons. I found I can wave my hands at the buttons and the RF noise could trigger a swarm of interrupts as if the button was mashed. This is useful behavior in other contexts and I have questions.

    I have applications where I've been using FM radio modules to complete an acoustic ranging loop. The implementation is short range and has to be cheap and light. The FM radio is only conveying a timing beat, so it's over featured for what it does.

    I have two goals:
    1: Process local RF noise into usable interrupt trains used for sensing.
    2. Transmit timing data over the air.

    #1: If a piezo tuned to a particular frequency were physically compressed while coupled to an antenna, could a floating wire (Schmitt Trigger etc) on a digital pin on a Teensy reliably register an interrupt train matching the piezo frequency? ...and thus detect the piezo impact over the air.

    #2 If an appropriate length of wire were applied to a PWM pin, it would radiate at the PWM frequency...and potentially trigger interrupts at that frequency on a nearby Teensy configured the same way. This would allow for easy acoustic ranging loops. Also, if the transmitting Teensy had a set of wire stubs and a particular PWM pattern between them, it should show up to the listening Teensy as a specific pulse train...thus allowing it to identify nearby units over the air.

  2. #2
    Senior Member
    Join Date
    Jul 2020
    Posts
    1,178
    Quote Originally Posted by kdharbert View Post
    I recently had a disaster attempting to use buttons. I found I can wave my hands at the buttons and the RF noise could trigger a swarm of interrupts as if the button was mashed. This is useful behavior in other contexts and I have questions.
    Forgot to declare pullups?

    I have two goals:
    1: Process local RF noise into usable interrupt trains used for sensing.
    I don't think you mean noise - be aware of the difference between noise, interference and signal - here you have a signal
    you want to sense I think - but its unclear
    2. Transmit timing data over the air.
    To what accuracy?

    #1: If a piezo tuned to a particular frequency were physically compressed while coupled to an antenna, could a floating wire (Schmitt Trigger etc) on a digital pin on a Teensy reliably register an interrupt train matching the piezo frequency? ...and thus detect the piezo impact over the air.
    No, the RF oscillator is what determines the frequency, this is usually quartz-locked in the transceiver/transmitter module.
    Besides you need an RF receiver to pick up a radio transmission (sensitivity and selectivity are vital in the radio world - signal strength
    varies over many orders of magnitude, in real time, and what if you're near another transmitter?).

    #2 If an appropriate length of wire were applied to a PWM pin, it would radiate at the PWM frequency...and potentially trigger interrupts at that frequency on a nearby Teensy configured the same way. This would allow for easy acoustic ranging loops.
    This would probably count as an illegal wide band transmitter, potentially interfering with emergency services transmission and
    a very very bad idea. Only for very short range and very low power might this be legal.

    The radio frequency spectrum is regulated and licensed, you have to stick to the rules.

  3. #3
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany
    Posts
    9,054
    Quote Originally Posted by kdharbert View Post
    2. Transmit timing data over the air.
    What distance?

    As Mark said, probably a very bad idea.
    Light may be possible..

  4. #4
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany
    Posts
    9,054
    Edit: on the other hand, DD4WH and I created a DCF77 receiver.. (77khZ), Software only, with the audio shield + antenna
    The military uses even lower frequencies for submarines.

    Not sure where the range begins where a licence is needed..

  5. #5
    Senior Member
    Join Date
    Oct 2019
    Posts
    178
    The plan is for super low power using no amplification.
    For FCC compliance, my reasoning is that Teensy's PWM only goes into hundreds of MHZ. At those frequencies, the transmit limit will be well above what the Teensy can drive off of 3.3v.

    I already use optical comms for similar work, but it requires aiming and extra circuitry.

  6. #6
    Senior Member+ Frank B's Avatar
    Join Date
    Apr 2014
    Location
    Germany
    Posts
    9,054
    Without extra circuitry, it is not possible.

  7. #7
    Senior Member
    Join Date
    Jul 2020
    Posts
    1,178
    Quote Originally Posted by Frank B View Post
    Edit: on the other hand, DD4WH and I created a DCF77 receiver.. (77khZ), Software only, with the audio shield + antenna
    The military uses even lower frequencies for submarines.

    Not sure where the range begins where a licence is needed..
    I know 87kHz is used for cave rescue services in the UK, its probably licensed for single-sideband only - many "public use"
    bands have bandplans that prescribe the modulation types, duty cycles and power levels - these are legal restrictions on
    use of the band.

    The RF spectrum regulations are hugely complex and vary between territories, change over time. You are liable if you
    interfere with other services.

  8. #8
    Senior Member
    Join Date
    Jul 2014
    Posts
    3,316
    Quote Originally Posted by MarkT View Post
    The RF spectrum regulations are hugely complex and vary between territories, change over time. You are liable if you
    interfere with other services.
    adding: Even listening to, or intercepting non-public transmissions may be illegal and in particular cases may get you in trouble.
    and interfering means also publishing frequencies and content of intercepted non-public information.

  9. #9
    Senior Member DD4WH's Avatar
    Join Date
    Oct 2015
    Location
    Central Europe
    Posts
    660
    Quote Originally Posted by kdharbert View Post
    The plan is for super low power using no amplification.
    For FCC compliance, my reasoning is that Teensy's PWM only goes into hundreds of MHZ. At those frequencies, the transmit limit will be well above what the Teensy can drive off of 3.3v.
    You are clearly wrong with that statement!
    Connecting an antenna to a Teensy pin (without any further hardware) can make the Teensy an illegal transmitter with much more power than is legally allowed. For example, 50 nanoWatts is the legal limit for an FM transmitter in many European countries; this is clearly exceeded by the Teensy when connecting a wire of 10cm to an output pin.

    Inform yourself about all the legal regulations in your country, if you want to be safe.

  10. #10
    Senior Member
    Join Date
    Oct 2019
    Posts
    178
    @DD4WH
    Good info on the transmit power limits.
    I have some threads going in other forums and informing yourself is remarkably difficult in this case it turns out.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •