Schmitt trigger on IRED xmtr


Closed Thread
Results 1 to 6 of 6
  1. #1

    Default Schmitt trigger on IRED xmtr

    I breadboarded a 16F628a pair as an infrared xmtr and rcvr at 38 khz and all seems to be ok except I'm not getting proper function when I combine my 38khz PWM and the data from SEROUT. (T1200)

    I see the 38khz (more like 38.4) at pin 1 of my 4093 and see the SEROUT at pin 2 on my scope, yet I'm getting about 20khz at the 4093 output and no function from the remote control.

    I've been under the impression that there is no problem driving either TTL or CMOS with a PIC.....is that the problem? Would a 74HCT132 make the difference?

    Thanks.

  2. #2
    G8RPI's Avatar
    G8RPI Guest


    Did you find this post helpful? Yes | No

    Default

    Hi Michael,
    As the '4093 is a NAND gate, the ouput will be inverted, how are you driving the IR LED?
    If you have a two channel 'scope, put 1 channel on your data from the PIC and the other on the output of the '4093. You should see a high level when your data is low and a series of low pulses when the data is high.

    HTH,
    Robert G8RPI.

  3. #3


    Did you find this post helpful? Yes | No

    Default

    Actually that should read N1200 not T1200.

    It's a mimic of the circuit I saw on Rentron with a 38khz pwm and serout/serin.

    I'm driving a 2n4403 to switch the anode of the xmtr led.....the data looks perect on the rcvr serin terminal. I'm simply using portb to look at the data....

    START:

    SERIN PORTA.0,N1200, [QUALA,QUALB,DAT]

    PORTB.0 = DAT.0
    PORTB.1 = DAT.1

    AND SO ON

    GOTO START


    Using a 16f628a--comparators are off.

    I see perfect data at serin but nothing on the portb outputs....took the data directly from the sharp module and also through a 4401 buffer.

    Oh well.

  4. #4


    Did you find this post helpful? Yes | No

    Default

    I need to ask also....

    On the 16F628a, if I CMCON = 7 to turn the comparators off....
    do set TRISA so the xtal pins are inputs?

    On my rcrvr, I'm using A0 for SERIN and the xtal is on A6 and A7

    so...

    TRISA = %11000001 ?

    I was also mixed up on the MCLR function.

    The 16C65B I've used to date had to have a 4.7k to V+ or they won't function.

    I had had MCLR configured as "reset" in the epic software....only to find out it needed to be an "input" for the chip to work.

    (I still don't get that one).

  5. #5
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    Michael, The reset function can be set to internal, leaving the reset pin available for external use. However this pin can only be used as an input pin and has NO output drive capability. Its all in the data sheet for the processor you are using.

    Dave Purola,
    N8NTA

  6. #6


    Did you find this post helpful? Yes | No

    Default

    Thanks Dave, so in EPIC language that means choose "input" ?

    When I chose "reset" in the Epic software and had a 4.7K to V+, the PIC wouldn't function at all.

    I chose "input" and it works.

    So, will the chip reset regardless of which I choose?

    I am going to look at my breadboard this morning and hardwire the SEROUT/SERIN to see if it's an infrared problem.....don't know why I didn't think of that yesterday.

    It's called middle aged brain atrophy.

    It has to be something simple....maybe in my chip setup. I've always used the 16C65B OTP part....this 16F628 is new to me.

Similar Threads

  1. PIC16F628a Schmitt Trigger Input
    By yankee in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 18th March 2009, 14:05
  2. Replies: 2
    Last Post: - 8th February 2009, 05:10
  3. Need Help... 16f630 Schmitt Trigger
    By tohu thomson in forum mel PIC BASIC
    Replies: 1
    Last Post: - 13th August 2007, 15:13
  4. build in schmitt trigger
    By mischl in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 5th April 2007, 16:16
  5. 16F628A ired with battery
    By Michael in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 7th March 2006, 13:56

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

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