Please refer to the PSoC 5LP Architecture TRM (Technical Reference Manual)
Chapter 19 is I/O System
Each 8 GPIOs are controlled as group of "Port".
And in your case GPIOs P4, P4, P4, P4, P4 are all belonging to the Port 4.
So I think that when one of the pin in that port caused some critical situation,
the port got shutdown, and all the pins in the port P4 ~ P4 are affected by that.
Meantime, I would recommend you to get PSoC 5LP : CY8C58LP Family Datasheet
In the chapter 11. Electrical Specifications.
11.1 Absolute Maximum Ratings
IGPIO (GPIO Current) is stated as -30 ~ 41 mA.
If your application requires close to it or more, adding additional driver(s) to the pin(s) will be required.
What is the voltage you are supplying to VDDD of the PSoC5?
What is the value of the series current limiting resistor you are using to feed the base of the MMBT3904TT1G?
Moto, thanks very much for the confirmation! We also assumed that the entire port shuts down.
We supply 3.3V; the resistor value is 33K.
With PSoC GPIO pin driving 33k resistor in series with 3904 base, GPIO current is around 78uA. So, we know the GPIO is not trying to source very much current. This doesn't sound like the source of the fault causing the entire port to shut down. The design has very good isolation between PSoC and camera by using 3904.
It was mentioned the camera is 'detected'. How is this implemented?
And, what action does s/w perform when a camera is not detected? Could it be shutting down entire port and not just the 1 GPIO port pin?
We send the "power enable" command to the PSoC to enable 3.3V at DF58-4P-1.2V(21). At high temperatures, the entire GPIO port (though we enable 3.3V only for one camera) shuts down and the power enable pin(s) stay(s) low. As a result, the Raspberry Pi does not detect either of the cameras at the USB interface.
When the camera is not detected, the SW does nothing but returns the error message to the user. Yes, you are exactly right -- the entire port shuts down, not just an individual GPIO pin.
Interestingly, if we don't continuously enable 3.3V (just keep it high at all times), high temperatures do not cause the entire port to shut down.
With VDDD = 3.3V and an assumed 1.0V drop at the base of the MMBT3904TT1G, the current flow through the base is:
(3.3-1.0)V / 33K) = 70uA.
Assuming you're driving 5 port pins high simultaneously, that is 70 * 5 uA =
3.5mA. Not much to worry about here.
With a DC gain (Hfe) of 100, you're allowing 7 mA to flow through to the SI2399DS-T1-GE3. Is this enough current?
This is getting a bit confusing without seeing a schematic of these connections. Maybe you could post a pdf capture of just the PSoC with it's connections to the 3904 and SI2399DS, so we can see what we're trying to diagnose.
(edit: corrected number of ports pins to 5)
My understanding is:
- there are 5 cameras
- there are 5x 33k resistors connected, one to each associated P4 GPIO
- there are 5 MMBT3904TT1G
- there are 5 SI2399DS-T1-GE3
When the command to enable a camera is sent through connector DF58-4P-1.2V(21), is this a single logic HI (or LOW) signal or a serial bit stream like SPI, I2C, UART? Are all the grounds connected together?
When you say:
"if we don't continuously enable 3.3V (just keep it high at all times), high temperatures do not cause the entire port to shut down."
which "enable" are you referring to? The base of 3904? The gate of SI2399DS? What is meant by "just keep it high at all times"..., what signal are you referencing? I'm confused here, sorry.
Does the circuit have a pull-up resistor on 3904 collector?
Does the camera have it's own 3.3V power supply separate from PSoC 3.3V supply? If camera and PSoC are powered from same source, turning the camera ON could result in a sudden voltage dip that causes PSoC to lock up. High temperature could make this situation worse. Maybe try a test with separate 3.3V power supplies.
BTW, measure the voltage at Vccd. It should be 1.8V and should only have a single capacitor, 1uF, connected to this pin (when the rest of PSoC is powered from 3.3V). Vccd should not be tied to any other signal or voltage rail. Just to a single capacitor.
Sorry for all the questions, but we're guessing about your setup.
Yes, 7mA is enough current.
I will later answer your questions. In the meantime, I am curious about the symptoms that we observed:
1) When the PSoC shuts down one of the ports (say, due to inrush current), is there any way to get it out of this state besides power cycling?
2) Is there any way to read the failure bit to understand why the PSoC shut down that port?
I had some doubts, which were cleared going through the thread again I guess. What is the high temperature range the device is going ? Is it within the device temperature limits ? Additionally are the port pins are within the VDDIO quadrant current limit ? In 100-pin or 68-pin devices it is 100mA per VDDIO quadrant. Where as for 48-pin it is 100 mA for VDDIO0+VDDIO2 and 100 mA for VDDIO1+VDDIO3. This needs to be on check. Using the device above the maximum absolute values can even damage the device too.