Dear pgo,
I don't know if the problem is in the BDM code, or elsewhere, but I have found that the USBDM does not drop the 12V Vpp after programming the RS08KA8.
I have got around it by adding FLASH12V_OFF() after VPP_OFF() in CmdProcessing.h after line 893,
"case CMD_FLASH_DLEND:"
VPP_OFF(); // Turn Proramming voltage off FLASH12V_OFF();// KAM Turn off charge pump
The code is inserted twice.
Thanks,
Kevin
Solved! Go to Solution.
Dear marksl,
I'll look at this in more detail later - I'm rather busy at the moment.
Some comments:
Even with a blocking diode you may still have voltage fed through the pull-up resistors on the HC125 outputs if there is no load?
The HC125 is not a suitable device as it is not rated to have 5V in/out when running on a lower rail voltage. A 74LC125A is pin compatible and can be used instead. You can use the two spare gates to eliminate Q2 if RST_IN and RST_OUT are separated.
I can only suggest removing the HC125 and confirm that the problem goes away, then try without the pull-ups.
bye
Dear marksl.
This shouln't be necessary. VPP_OFF() should turn off the Vpp voltage via an isolating transistor (BSS84). FLASH12V_OFF() turns off the charge pump and should be redundant. It's there really as a safety precaution so that Vpp=12V can't be applied to other than RS08 devices (the pump is off for all other devices).
Can I just check is this the JB16 or JMxx version of USBDM? If you let me know I'll check these in case I've broken something in a software revision.
In the mean time, check the above switching transistor or the port pin controlling it. If it is not working correctly there may still be problems with excessive current flow when resetting the target.
bye.
Dear pgo,
I am using the JB16 version.
I have also discovered that I made a mistake transcribing your circuit - it seems I swapped drain and source of MOSFET Q3. I don't know what effect that has, perhaps this is what is causing the 12V to still be present when VPP is turned off.
The circuit works at present, but for two issues:
1) I had to include the above mentioned code to fully turn off Vpp after flash write (on the KA8), and
2) I can't get Vdd to turn off properly. There is always at least 3V present. I use the USBDM test program, with commands "debug 9", "debug 10", etc.
Sincerely,
Kevin
Dear marksl,
Transposing D & S will cause the 12V to be always present since the D-S diode will be forward biased. Best to fix this
The 3V should be switchable- check that the control input to the regulator is changing when Vdd is switched on and off using the debug commands.
Good luck.
bye
marksl wrote:
I've discovered that the 3V present on Vdd_BDM is coming from the Philips 74HC125N buffer I'm having to wire onto the board (I don't have any 74LVC2G125D's yet). For some reason, that IC is outputting 3V from its Vcc pin. I can try replacing the Philips version with a TI version, and see if anything changes. Hopefully the 74LVC2G125D won't present the same problem.
I recently placed a diode between the Vcc rail and the Vcc pin on the HC125 buffer, and the Vdd_BDM still would not drop to 0V. If I use my own inserted debug commands to force the BDM_DRV and BDM_OUT to known levels, I can get Vdd_BDM to 0V.
To repeat: I can raise Vdd_BDM to 3.3V and 5V, but I can not force it back to 0V without manually resetting the BDM_* control lines.
I have attached my schematic.
Do you have any suggestions/comments?
Sincerely,
Kevin
Dear marksl,
I'll look at this in more detail later - I'm rather busy at the moment.
Some comments:
Even with a blocking diode you may still have voltage fed through the pull-up resistors on the HC125 outputs if there is no load?
The HC125 is not a suitable device as it is not rated to have 5V in/out when running on a lower rail voltage. A 74LC125A is pin compatible and can be used instead. You can use the two spare gates to eliminate Q2 if RST_IN and RST_OUT are separated.
I can only suggest removing the HC125 and confirm that the problem goes away, then try without the pull-ups.
bye
Dear pgo,
It works!
Thanks, it seems that the problem was with the HC125 buffers. Using the LVC2G125 everything works fine - I've got full control over Vdd_BDM - 0, 3.3 and 5V.
Sincerely,
Kevin
Dear pgo,
With the HC125 removed (or even just un-powered), the problem is no longer present. Which pullups are you referring to? R1 & R17?
I shall make up another board using a LVC2G125 I recently received from Farnell. Hopefully the problem is only in the buffer, and not in the rest of circuitry.
I appreciate your attention.
Sincerely,
Kevin
Dear marksl,
R17 would be the one I had in mind.
bye
Dear pgo,
Funny, but it seems like I left off R17 during transcription...
I'm building a new board today. I'll keep you informed.
Thanks,
Kevin