Shop OBEX P1 Docs P2 Docs Learn Events
SX Key Error: Vpp generation failed ? — Parallax Forums

SX Key Error: Vpp generation failed ?

T&E EngineerT&E Engineer Posts: 1,396
edited 2006-08-13 21:01 in General Discussion
I made a soldered circuit version almost identical to Gunthers·schematic in his book: Programming the SX Microcontroller (p. 6). The SX-Key program comes up with an error: Vpp generation failed. when it attemps to program the SX-28. However, the SX-key programs the SX-28 fine in my PDB. I have a 5v regulator (7805) circuit with capacitors as normal on my circuit with 4.98 vdc.·Gunther's circuit is not that difficult to build but it always·comes up with the error when trying to program the SX-28. I have tried 2 chips and both program fine on the PDB.

I have checked my circuit many times and don't see any bridges or solder problems.

Any help here?

Thanks.·

Comments

  • NateNate Posts: 154
    edited 2006-08-12 21:54
    Typically the "Vpp generation failed" error happens when the 5V power supply powering the SX-Key cannot supply enough power for the SX-key to generate the needed 12V programming voltage.· Check the·output of·your·7805 under load (say 0.5A)·- is the voltage sagging?·

    If it is, is the power supply powering the 7805 delivering enough voltage and/or amperage?· If the power supply is only delivering slightly above the dropout voltage of the 7805, under load this voltage can drop, causing the 7805 to stop regulating.· If the power supply capable, the problem may lie with your 7805 and/or regulating circuit.



    Nate
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-12 22:10
    I am using a standard Parallax 7.5vdc (1000 mA) wall transformer that I also use on my Professional Development Board which works fine for SX-Key programming. I read 4.98vdc on the SX-key pins and pins 2 and 4 of the SX-28 and the·software in the SX-28·runs fine. I just can't program it with the SX-Key on my soldered board version of Gunther's SX-28 circuit. I read 10.28vdc on the wall transformer comming into the 7805 circuit. I have a 100 uf cap on the input and ground of the 7805. I have a 10 uf and 0.001 uf cap on the output (5v) of the 7805.

    http://forums.parallax.com/showthread.php?p=600796

    This is my circuit.
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2006-08-12 23:22
    It looks from your pictures that the distance between the sxkey pinheader, the resonator
    and the sx28 is substantial. It is best to mount the resonator as close as possible
    to the sx28 osc pins, and the sxkey pin header right next to that.
    That is how I always setup a sx and never have had this error.
    Also, keep any wires as short as possible.

    regards peter

    Post Edited (Peter Verkaik) : 8/12/2006 11:25:47 PM GMT
  • BeanBean Posts: 8,129
    edited 2006-08-12 23:56
    Try putting a 0.1uF cap as close as possible to the sx-key header on your board.

    As Peter has said, either the supply is sagging (4.9V won't work), or one of the OSC pins cannot be brought to 12V (this usually happens when you have an oscillator clocking the SX).

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com

    "You're braver than you believe, stronger than you seem, and smarter than you think" Christopher Robin to Pooh
    ·
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-13 00:54
    I·soldered a·0.01 uf cap·on the project soldered board·SX Key header accross VDD and VSS. I still get the Vpp error. What else should I look at. I measured 4.96vdc on the VDD and VSS pins on the PDB (which does program correctly). I measured 4.98vdc accross VDD and VSS on the new 0.01uf cap (VDD and VSS). I'm not sure but something doesn't sound right in what you are saying.

    I can also take the resonator out of the project soldered board socket and it still gets the error too.

    Other ideas to try?
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-13 01:22
    I soldered the resonator on the bottom soldered side of the board - directly accross OSC1 and OSC 2 (pins 27 and 26 with the middle connector to ground) on the SX-28. and it is still not working. I don't think I can get the oscillator circuitry much closer than this. The 0.01uf is accross VDD and VSS on the SX Key header (solder side).

    ???
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2006-08-13 02:32
    From your picture it looks like the sx28 is in a socket in your breadboard.
    To be clear, you can program that sx28 using the DPB, but not when it
    is inserted in your breadboard, right?
    Then, after you programmed it in the PDB, and reinserted in your breadboard,
    does it then run as you expect (with sxkey not connected to the header)?
    If it does then the resonator circuitry is working. If not, there is something
    really wrong with your breadboard resonator cicuitry. Bad resonator perhaps?

    regards peter
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-13 02:47
    The resonator was used with the PDB and it was required if the SK-Key's clock was not set to 20 MHz - as Bean described to me in an earlier post (However, the resonator is not used when I program on the PDB).

    I can program the SX-28 in the PDB with or without the resonator. I take the SX-28 out of the PDB and put it into my socket on the soldered board I made in the picture. It runs fine then. If I try to connect the SX-Key to program a SX-28 (with or without a resonator) (on my soldered circuit board)·- I get the error. The programming works on the PDB but not on my soldered board. It doesn't make any sense to me.
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2006-08-13 04:43
    Looks like it could be the sxkey header on your soldered circuit.
    Are the pins from that header all making good contact with
    the sxkey (eg. pins not too thin)?
    Have you measered the headerpins connections to the sx28
    with a multimeter? That should give all zero ohms if all headerpins are correct.
    (power off before measuring).
    Edit: you do have a pullup resistor on the mclr pin?
    Its just there seems not to be looking at·the picture.
    A pullup resistor on the rtcc pin is also recommended.

    regards peter

    Post Edited (Peter Verkaik) : 8/13/2006 5:20:08 AM GMT
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-13 12:20
    I tried using the pin header that came with the SX-Key and it is still a no go. The PDB programs fine but the soldered board does not with the Vpp error. I also measured 0.8 ohms (~0) on the OSC pins back to the SX-28 OSC pins. I have a 10K resistor pulled up on the /MCLR pin but nothing on the RTCC (as the PDB schematic does not show anything to this pin).

    I think I am going to rebuild this on a solderless breadboard and then try another solder breadboard (if it works) unless any more answers can be found. My circuit is identical to the PDB schematics. The PDB still has no Vpp error so I know the SX-Key is good.
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2006-08-13 13:11
    I wouldn't give up on the board just now.
    Your sxkey if fine, but also is your board, as a programmed chip runs fine.
    So I suggest you just remove the entire sxkey header,
    that includes ALL header wires, inclusive VSS and VDD.
    After removing the sxkey header parts, check if the programmed
    chip still runs fine, then resolder the sxkey header (or a new header).
    If the chip then still does not program, then perhaps a new board.

    regards peter
  • T&E EngineerT&E Engineer Posts: 1,396
    edited 2006-08-13 18:57
    I found the reason for the Vpp Error. OSC1 and OSC2 pins on the SX-Key header were wired in reverse going back to OSC1 and OSC2 pins on the SX-28. I probably thought that it did not mater which way for the resonator but it certainly would make sense for the SX-Key.

    All is working!

    Thanks again Peter and Bean!
  • BeanBean Posts: 8,129
    edited 2006-08-13 19:50
    Ah yes, that would do it.

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Cheap 4-digit LED display with driver IC·www.hc4led.com

    Low power SD Data Logger www.sddatalogger.com

    "You're braver than you believe, stronger than you seem, and smarter than you think" Christopher Robin to Pooh
    ·
  • Guenther DaubachGuenther Daubach Posts: 1,321
    edited 2006-08-13 21:01
    T&E Engineer,

    although I'm a bit late, as you altready have fixed the problem, let me add some details concerning the "Vpp generation failed" error message:

    The SX-Key has an on-board generator for the 12V programming voltage required to erase and program the SX, and the on-board SX checks if this voltage is available. When this is not the case, the SX-Key returns an error status to the IDE which then shows the "Vpp generation failed" error message.

    Reasons for a missing (or too little) Vpp can be:

    - SX-Key supply voltage too low.
    - Too much load on the SX-Key's OSC 1 pin. This can be caused by a short, and external component attached to the OSC1 pin, like a clock generator, or OSC1 and OSC2 pins interchanged, as in your case.
    - SX-Key defective.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Greetings from Germany,

    G
Sign In or Register to comment.