Going backwards, can't even get a basic blinky working now


Closed Thread
Results 1 to 27 of 27

Hybrid View

  1. #1
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Quote Originally Posted by tumbleweed View Post
    Also, if you're using a crystal then probing the OSC1 and OSC2 pins is going to throw things off, and could even make it stop oscillating.
    Usually with a 20M xtal you want smaller caps, not larger ones. You might get away with probing the OSC2 pin since that's the output drive...
    Yeah, I noticed that rather quickly on the Lab X1. But even probing only OSC2 on both setups, it quickly became apparent something was terribly wrong with the breadboard.

    I did get OSC1 to function while being probed on the X1. That's wht I wasn't really concerned when the intervals on both pins became "slightly irregular", but hey, the PIC still worked.

    I'm tempted to solder the cap right off the side of the 16F877.


    IMHO you're better off using the LABX1 instead of a breadboard. That ICS502 clock generator will give you a nice logic-level output.
    For the 18F4550 I'd set the CONFIG to use external clock mode, not xtal (EC, ECIO or ECPLL)
    Yeah, but this was just to see if the IC had a heartbeat.


    The PK4 can take a while to switch chips, and it's not great with some of those really old devices.
    Thing is, the PK4 took forever even if I was programming them sequentially in batch mode; keeping the 18F4550 separate.


    It's even been known to blow them up from time to time (the VPP generator can overshoot > 20V)
    You see, now that is very worrisome. Gonna go google voltage limiting. I remember seeing voltage clamps last time I was "electronically active".

    I just don't know to what limit I should set the clamp for. I suppose the datasheet will give me some indication in "maximum specs".

    Robert

  2. #2
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Eeeep, 20V That's a tad beyond max rating for a 16F877.

    Name:  16F877 max elect char.png
Views: 2733
Size:  98.4 KB


    Reading up on Zener Transient Suppression:

    https://www.electronics-tutorials.ws...ppression.html


    And then off to Digikey for a supply of Zs.

    Robert


    EDIT: These look nice:

    https://www.digikey.ca/en/products/detail/onsemi/1N5243BTR/977601
    Last edited by Demon; - 2nd May 2023 at 17:57.

  3. #3
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Looked up the 18F4550, and it's not better.

    Voltage on MCLR with respect to VSS (Note 2) .......................... 0V to +13.25V

    Note 2: ... a series resistor of 50-100Ω should be used when applying a “low” level to the MCLR/VPP/RE3 pin, rather than pulling this pin directly to VSS.

    Maybe I've just been lucky, or my PK4 has a thing against 16F pics.

    Either way, a little prevention added to my circuits shouldn't hurt; like a zener on MCLR, and 50-100R when pulled low.

    Robert
    My Creality Ender 3 S1 Plus is a giant paperweight that can't even be used as a boat anchor, cause I'd be fined for polluting our waterways with electronic devices.

    Not as dumb as yesterday, but stupider than tomorrow!

  4. #4
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    It's not letting me EDIT that post so I can fix the hyperink to the diodes.

    Zener Diode 13 V 500 mW ±5%

  5. #5
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,139


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    I guess you have biased the MCLR pin, right?

    Ioannis

  6. #6


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Why don't you get rid of the crystal and use the pic internal oscillator ? That should stop your hand capacitance causing problems on the crystal circuit.

  7. #7
    Join Date
    Aug 2011
    Posts
    455


    2 out of 2 members found this post helpful. Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Regarding the overshoot issue, if your PICkit 4 is serial number BUR20xxxxxxx or later (-R2) then it has a mod in it to reduce the overshoot so it's not as much of a problem. Before that, they used to recommend using a 470R in series with the PK4 MCLR connection to the target.

    From ETN37:
    Some PIC16/18 devices have options to use high voltage on VPP or NMCLR to program the device. On some
    devices, the VPP/NMCLR pin has special ESD protection. Overshoot on the pin can result in a reset condition or
    current consumption outside of the specification. To avoid this situation, the data sheets for these devices
    recommend the use of an RCR network with a pull-up, a power up charge capacitor and a series resistor
    configuration into VPP. A series resistor of 470 ohms is used to dampen any overshoot and to limit current into
    VPP/NMCLR

  8. #8
    Join Date
    Jan 2005
    Location
    Montreal, Quebec, Canada
    Posts
    3,172


    Did you find this post helpful? Yes | No

    Default Re: Going backwards, can't even get a basic blinky working now

    Quote Originally Posted by Ioannis View Post
    I guess you have biased the MCLR pin, right?

    Ioannis
    I don't know the term "bias" in relation to the MCLR pin; but if you mean put a zener upside down so it breaks down over a given voltage, then yes, I'm biasing the pin.

    Scroll down here to the paragraph called Zener Transient Suppression.

    https://www.electronics-tutorials.ws...ppression.html

    I'm going to go one step further with zener diodes. I'm gonna add a 1N5243BTR on MCLR to break down at 13 volts, and a ‎1N5232BTR on VDD to break down at 5.6 volts (specs say 5.5V is "max" - but I figure they're leaving a small margin for safety).

    Unless someone has a good reason why I shouldn't...?


    Why don't you get rid of the crystal and use the pic internal oscillator ? That should stop your hand capacitance causing problems on the crystal circuit.
    I'm not seeing an internal oscillator on the 16F877: LP, XT, HS and RC. If you mean RC, it uses a capacitor as well. Won't that cause the same issues? They also mention other issues, like accuracy/tolerance of the resistor and capacitor, as well as temperature.

    This will ultimately run a USB or USART connection as fast as I can.


    I've tested the new breadboard using two gold pins from a header as probes (those pins are thick, clean and square) and I'm still getting a lot of "looshish" spots in some areas. The much thinner pins on capacitors, oscillators and some resistors must definitely be messing up my circuit.


    Also, I think I have some capacitor/interference issue with my Lab X1 as well (probably not even related with my breadboard issues, just bad timing). Waving my hand over the X1 should not affect operations. It's possible it now has a defect; I bought it when they came out.


    I'm looking at using fiberglass breadboards and soldering my components. I've been thinking of making my own Arduino-ish circuits for testing for a very long time. This might be the time to give that a try.


    Side note: the tips on my Aoyue 738 soldering station are garbage. Bought some new ones on Amazon and they just don't last. One comment on the listing was "I've had packs of gum that lasted longer"; he wasn't exaggerating.

    I bought new soldering paste since mine was 20 years old and had spent winter in unheated garage. I've just received today one of those brass brush balls to clean the tip; hoping that works better than that water sponge (never liked that).

    Robert

Similar Threads

  1. DT_INTS-14 (Blinky Light) Help ?
    By andybarrett1 in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 4th November 2015, 21:28
  2. Replies: 3
    Last Post: - 15th April 2015, 04:58
  3. 12F683 - basic code not working
    By Scampy in forum mel PIC BASIC Pro
    Replies: 56
    Last Post: - 12th February 2014, 00:29
  4. Blinky not working with TOGGLE
    By AndrewC in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 22nd November 2008, 08:45
  5. My first Blinky!
    By nomad in forum mel PIC BASIC Pro
    Replies: 17
    Last Post: - 25th September 2007, 17:29

Members who have read this thread : 0

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