• AVR Freaks

AnsweredHot!PIC32MZ stuck in APP_STATE_WAIT_FOR_CONFIGURATION state

Author
bblessing
Super Member
  • Total Posts : 741
  • Reward points : 0
  • Joined: 2008/12/04 06:44:21
  • Location: Cincinnati, OH
  • Status: offline
2019/12/12 14:22:21 (permalink)
0

PIC32MZ stuck in APP_STATE_WAIT_FOR_CONFIGURATION state

Background: PIC32MZ2048EFH064, XC32 v2.10, Harmony v2.05, MPLAB X IDE v4.15, Windows 10 Professional
 
I'm seeing the device stuck in the APP_STATE_WAIT_FOR_CONFIGURATION state, as per the cdc_com_port_single sample firmware. Also, I keep seeing a popup that says the following: USB device not recognized. The last USB device you connected to this computer malfunctioned, and Windows does not recognize it. In Device Manager it looks like it's showing up as the following under Universal Serial Bus controllers: Unknown USB Device (Device Descriptor Request Failed). I'm reasonably sure the clock and configuration bit settings are correct for my project, which uses an 8 MHz crystal instead of a 24 MHz oscillator, and my modbus RS-485 port works just fine, as does the EEPROM.
 
Additionally, this exact same circuit works fine with our boards that use a PIC32MX430F064H processor. The connector type for both projects is micro USB type AB. I've attached the relevant portion of the circuit.
 
I've tried several things, like enabling a pull down on USBID, but nothing seems to get it out of this state. I'm sure the solution is probably that I missed something obvious, but I'm stuck and felt it was time to reach out.
 
Edit: I should also point out that I've tried messing with RF3 as per this post - https://www.microchip.com/forums/m1118560.aspx - but to no avail.
post edited by bblessing - 2019/12/12 14:35:31

Attached Image(s)

#1
Paul PortSol
Super Member
  • Total Posts : 553
  • Reward points : 0
  • Joined: 2015/07/03 11:52:03
  • Location: Newfoundland, Canada
  • Status: offline
Re: PIC32MZ stuck in APP_STATE_WAIT_FOR_CONFIGURATION state 2019/12/13 05:21:04 (permalink)
0
I've heard that HarmonyV2.04 may be necessary for some USB stuff (bugs in later versions?)
Paul
#2
jdeguire
Super Member
  • Total Posts : 489
  • Reward points : 0
  • Joined: 2012/01/13 07:48:44
  • Location: United States
  • Status: offline
Re: PIC32MZ stuck in APP_STATE_WAIT_FOR_CONFIGURATION state 2019/12/13 11:20:25 (permalink) ☼ Best Answerby bblessing 2019/12/13 13:36:00
5 (3)
If I remember correctly, you MUST use a 12MHz or 24MHz clock/crystal on the PIC32MZ if you are using USB.  This limitation did not exist on the PIC32MX because it has a different USB module (USB High-speed on the MZ vs. Full-speed on the MX).
 
Edit:  Yup, see Section 11 in the PIC32MZ EF datasheet.  You must use a 12MHz or 24MHz clock for the primary oscillator (POSC).
post edited by jdeguire - 2019/12/13 11:22:39
#3
bblessing
Super Member
  • Total Posts : 741
  • Reward points : 0
  • Joined: 2008/12/04 06:44:21
  • Location: Cincinnati, OH
  • Status: offline
Re: PIC32MZ stuck in APP_STATE_WAIT_FOR_CONFIGURATION state 2019/12/13 13:37:21 (permalink)
5 (1)
jdeguire
If I remember correctly, you MUST use a 12MHz or 24MHz clock/crystal on the PIC32MZ if you are using USB.  This limitation did not exist on the PIC32MX because it has a different USB module (USB High-speed on the MZ vs. Full-speed on the MX).
 
Edit:  Yup, see Section 11 in the PIC32MZ EF datasheet.  You must use a 12MHz or 24MHz clock for the primary oscillator (POSC).


Wow! I would have never caught that one. Thank you very, very much!
#4
Jump to:
© 2020 APG vNext Commercial Version 4.5