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

Thread: Teensy Micromod with Ethanol sensor

  1. #1

    Teensy Micromod with Ethanol sensor

    Hello!

    I need some advice regarding an ethanol sensor that outputs up to 5V. Using an Arduino with 5V this is a walk in the park and there is plenty of information online.
    Teensy is 3.3V so I'm thinking that I need to use a voltage divider on the input pin to protect that pin from getting above 3.3V(?).

    Also, what seems to be the standard here is to give the same signal wire a 4.7k res and 5V, I figure it is to give it ground if no signal.
    So that begs the question. Do I give that signal wire 3.3V instead or am I missing something here?

    I made a little image in paint (nice huh ).

    Appreciate your input!

    Click image for larger version. 

Name:	TeensyEth.png 
Views:	19 
Size:	13.6 KB 
ID:	25710

  2. #2
    Senior Member+ KurtE's Avatar
    Join Date
    Jan 2014
    Posts
    9,576
    If you are wanting to measure the voltage...
    And nothing special... I often add in a voltage divider using two resistors:
    https://en.wikipedia.org/wiki/Voltage_divider

  3. #3
    Quote Originally Posted by KurtE View Post
    If you are wanting to measure the voltage...
    And nothing special... I often add in a voltage divider using two resistors:
    https://en.wikipedia.org/wiki/Voltage_divider
    Thank you for your reply!
    Yes I want to measure the voltage. But what get's me confused is the 4.7k resistor and 5V on the signal wire. I would presume it is to it GND if no signal but I can't be sure.
    See this image. It is works with Arduino Nano since is has 5V tolerance.

    Click image for larger version. 

Name:	BI3WI4x.png 
Views:	21 
Size:	26.5 KB 
ID:	25711

  4. #4
    Senior Member BriComp's Avatar
    Join Date
    Apr 2014
    Location
    Cheltenham, UK
    Posts
    416
    You don't say what sensor you are using nor do you state the type of output from the sensor.
    I googled an ethanol sensor which had the following information on it's sensor output. I do not know if it is the same as the sensor you want to use.
    The signal circuit carries the ethanol percentage via the frequency signal. The ECM provides an internal pull up to 5?V on the signal circuit, and the fuel composition sensor pulls the 5?V to ground in pulses. The normal range of operating frequency is between 50–150?Hz. The microprocessor inside the sensor is capable of a certain amount of self-diagnosis. An output frequency between 180?Hz and 190?Hz indicates that the fuel is contaminated.
    If your sensor is the same as this then the sensor output should be connected via two resistors ( forming a potential divider ) to GND. Connect the mid point between the two resistors to the Teensy input.
    I will leave you the job of calculating the values of the two resistors. This is complicated by the pull up resistor in the sensor as this will be part of the resistor network. It might be useful if you stated the model of the sensor being used.

    The circuit you are suggesting WILL put 5v on the Teensy input and destroy it.

Posting Permissions

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