Pynq-z2 board crashing/freezing

Hi all,

I have designed a pcb shield that fits on the Arduino headers of the Pynq-z2 board. It contains a PD-chip negotiating 9V which is used to power the Pynq board via VIN/CU_CK pin, as well as the stepper motors, for which drivers are also included on the board. Lastly the board contains an IMU and a magnetometer, which are communicating with the board via I2C. The analog ports and the AR0-7 ports are broken out but not connected to anything. “Hardware” blocks are designed in Vivado, but most of the software is done in Vitis by programming a microBlaze.

My problem is as follows: when I power the Pynq board using the programming usb port (USB power) everything works super steady, however when I swap the jumper from USB to REG, and the program keeps freezing, and during debug, it looks like the I2C ports just stop working. The powerlines are rock solid, no problem there. But I have no clue on what could be causing this. If anyone has an idea I would be very grateful.

Are you able to test this using the barrel connector only?
Have you tried connect a USB terminal during the freeze to check if the board is responding at all?
Does it always freeze at the same point in debug, and are you able to measure voltage/current/power at that point?


Yes, this also happens when only the barrel jack is connected, and I can connect a usb cable to read out serial data. It does not always stop at the same point but it does always stop when there is I2C communication. It seems to hang at either of these two points in the iic_l.c code:

  1. while ((StatusReg & XIIC_SR_BUS_BUSY_MASK) == 0) {
  2. while (1) {
    if (XIic_ReadIisr(BaseAddress) & XIIC_INTR_BNB_MASK) {
    All voltage lines are nice and clean, with very little distortion, and there are no problems with power.
    From what I was able to find out today, the Zynq sends 1 or 2 clocks too few, causing it to never get a stop signal. But why this happens only when the system is powered via the barrel jack…

I also had almost similar problem to your situation with a custom board running pynq. It was solved using a lower pull-up register. It might be a different problem in your case, just sharing my experience.