PIC Output + ?

Discussion in 'General Electronics Chat' started by FroceMaster, Aug 22, 2014.

  1. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    HI.
    Have this project where i need to messure some RPM's
    And now i want to know if this will Work, hardware part.
    img016.jpg
    From top.
    LCD display, for view of rpm.
    Next the MCU 16F690 should do it.
    And a 4051 8*switch, ( use only 3 input, save one pin from MCU and "future safe").
    sensors for messure RPM's
    The buttons on right to adjust level for alarm.
    HAve connected the backlight on LCD to a pin from MCU, can that Work ?
    and finaly a output from MCU to control a 12 v relay to "honk" a horn.
    When alarm..
    Can the hardware part function ???
     
  2. MrCarlos

    Active Member

    Jan 2, 2010
    400
    134
    Hello ForceMaster

    The scheme looks good, could work well if you have a good program in the PIC16F690.

    As viewed in the scheme. With the PIC you select the sensor Through 4051.
    The signal generated by the sensor is processed by the program in the PIC to be displayed on the LCD.

    I think it would work that HardWare.
    But much depends on the program in the PIC

    You could be missing in you design some kind of shaping for the signals output from the sensors.
    What type of sensors you use ?.
    Probably necessary to amplify the signal. or to conform to logic levels.

    A Question For You:
    What is the purpose of the 2N3904 transistor and associated components?
    It is this your question the answer?
    HAve backlight on the LCD connected to a pin from MCU, can that Work?
     
  3. MikeML

    AAC Fanatic!

    Oct 2, 2009
    5,450
    1,066
    The 10K resistor on the base of the relay switching transistor is way too high. Needs to be 220Ω
     
    Last edited: Aug 22, 2014
  4. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    It is not clear what the hardware is measuring. What are you measuring the RPM of and what is the range?
     
  5. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    Yes the transistor is for backlight. So i can get the users att. Can i use bc547 instead ?

    Rpm in range from 0 to 2-300 . The sensor is a omrom inductive sensor. http://industrial.omron.dk/da/produ..._sensors/compact_cylindrical/e2a/default.html
     
  6. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    The sensor has an output that looks like...what? What are you measuring? Period, pulse width, voltage...give us a break here.
    Do you seriously believe a datasheet in Danish is useful?
     
  7. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    Sorry, here is the schematic in English
    Technical%20info_02767xX.jpg
     
  8. MrCarlos

    Active Member

    Jan 2, 2010
    400
    134
    Hello FroceMaster

    Why did not you go over here:
    http://forum.allaboutcircuits.com/showthread.php?p=755238#post755238
    There You have a better circuit than you enclose here.

    You can probably use the BC547 to drive the backlight. would have to analyze the data sheets of both the LCD as the transistor.

    Have You analyzed how the output of those magnetic sensors are ?
    As I mentioned in my previous message, it is likely that you have to form the magnetic sensor signals to the 4051 have logic levels, 1's and 0's, in its inputs.

    Have You a flowchart for building this RPM meter ?

    By the way: With what programming language you're developing the code for PIC ?

    I guess you have to go step by step developing the RPM meter.
    You can test a sensor along with the 4051 to see how is its output.
    In their own environment where they will work those magnetic sensors.

    Once the pulses are as square as possible,

    To connect 4051 output to the input of the PIC and the PIC to handle 4051 to select one of its inputs.

    Parallel to this you could try the PIC with LCD, switches, alarm circuit and maybe the circuit for Backlight.

    But. . . There may be more ways to achieve your goal.
     
  9. Papabravo

    Expert

    Feb 24, 2006
    10,137
    1,786
    OK now I see what you are doing electrically. I still don't know what you are doing mechanically. I'm guessing that as the shaft rotates, the "object" enters and then retreats from the valid sensing zone. So what is the sensed "object" made of and how is it attached to the shaft?
     
  10. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    Well have made an updated version of my schematic,
    New schematic.png
    I know i will have to test the sensors, but they should make a pretty Square signal. or else i would need to maybe run them through a schmit trigger, "old 74LS132 days"

    The thing that is my biggest concern is the Building with the transistors and that i not will get interference when relay is working.

    The software part for 16F690 i think i have some clue to Work out, but that will be posted later in another forum, cause i problerly will need a Little help.

    Software concern:
    What i also will know, is it ok to run the 16F690 without a extern xtal, i will need to every second to read from input, and NeXT second switch on 4051 to NeXT input, hopefully there is "room" in the 16F690 , or i will need to change to 16F1509(same pins). but that one do not have EEPROM.

    Edit
    BTW i use MPLAB 8.92 to develop the software.
    Have build to other Projects, so i know a Little how it Works,
    Flowchart , sure someday ;)
     
  11. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    BTW i use MPLAB 8.92 to develop the software.
    Have build to other Projects, so i know a Little how it Works,
    Flowchart , sure someday ;)
     
  12. Alberto

    Active Member

    Nov 7, 2008
    169
    36
    Still not very clear what you will do. Do you need to know the Shaft direction along with its rpm? Bear in mind that omron proxy normally work with 12vdc to 24vdc so you will need an opto isolator to convert their outputs to TTL level.

    Alberto
     
  13. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
    Dont care the directions, Ok, i didnt know that it should be 12 or 24v, but will check out,.
    Here is btw the flowchart for MCU Software.
    flowchart.jpg
     
  14. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
  15. Alberto

    Active Member

    Nov 7, 2008
    169
    36
    Yes 4N33 will work! But you should look at TLP 504a where you have two optos per chip.

    Alberto
     
  16. FroceMaster

    Thread Starter Member

    Jan 28, 2012
    400
    4
Loading...