I have identified the cause of the problem which occasionally causes the Hydra to hang when USB is connected. I believe this is the same issue RedNifre described in his “Problems connecting the Hydra to the PC” post (http://forums.parallax.com/showthread.php?p=648112
) and is very likely the issue Brian Beckius recently described in his “hydra can’t be programmed” post (http://forums.parallax.com/showthread.php?p=657119
If you look at the following schematic you will see that the EEPROM serial data line (SDA) is pulled up to the reset net (RESn) with a 10k resistor.
I’m not sure what the original intent of this connection was. Possibly it was intended to allow a reset to force an I2C START (SDA falling edge while SCK high) followed by and I2C STOP (SDA rising edge while SCK high) in order to “reset” the EEPROM device. What ends up happening though is that SDA ends up pulling the reset net (RESn) down.
Since BOen on the Propeller is tied to ground the Prop has an internal 5k pullup (to 3.3.V) on RESn. That means that whenever SDA is low, RESn sits in the middle of a 5K/10K voltage divider and gets pulled down to nominally 3.3 * 10K/(5K + 10K) = 2.2V. Due to the tolerances of the resistor values (I’m guessing the 5K in the prop is not very accurate) I see an actual voltage during the contention of 1.83V.
Here is a picture of the Hydra resetting when the USB cable is inserted into my PC:
Blue is the base of Q5 (the transistor which pulls RESn low to create the reset)
Green is P29 (the Propeller pin which drives the EEPROM’s SDA line)
Pink is RESn (the Propeller reset line)
SDA goes high on reset, so it is not fighting against RESn and the initial reset pulse happens pretty normally. I don’t particularly care for the use of C15 to couple the DTR pulse into Q5. It barely makes 1.1V and barely manages to turn on the transistor, but it seems to work pretty repeatably. Parallax uses this same coupling method on their demo board. [noparse][[/noparse]I changed my mind about this. See later posting]
Now, here is a picture of the Hydra beginning its first EEPROM access
Yikes!. As you can see, the SDA transitions cause weird behavior on RESn, often dragging it down roughly 1/3 to about 1.8V. In some cases the Hydra will bang around a bunch, resetting a few times and eventually coming out of its “funk”, but sometimes it will get hung in a steady state condition which looks like this:
RESn is stuck at 1.8 and nothing is happening. The Hydra appears hung, and attempts to download code from the prop IDE will result in the “No propeller chip found on any COM port. Scanned COM3” error.
This also explains why I have had very good success clearing the “hung” state by hot-inserting a cartridge into the cartridge slot; undoubtedly the insertion glitch on SDA knocks RESn out of its hung state.
The solution is to pull SDA up to 3.3V. This can be accomplished very easily by anyone skilled in surface mount rework. Rotate the 10K pullup resistor R21 so that it is no longer connected to the right hand pad, and then solder a rework wire from the far side of R21 to the right side of R41 (3.3V).
After the fix the USB-insertion reset looks like this:
And the initial EEPROM access looks like this:
And USB insertion/download no longer hangs the device.
Post Edited (epmoyer) : 7/7/2007 3:22:43 PM GMT