SPI CAN Transceiver (MCP25625) - MISO not responding

Thread Starter

alexx_88

Joined May 24, 2010
28
Hi,

As per title, the MCP25625, which is a CAN transceiver commanded over an SPI interface, it's not responding to any commands received over SPI. I'm trying to send a simple 'READ' (0x03) command to the device and get the contents of the CANCTRL register (0x0F). I even moved past our project board and bought Microchip's development board for the MCP25625 to rule out any weird HW design issue. In both cases I've measured the CLKOUT pin using my oscilloscope and it's correctly reading 2.5MHz (20MHz crystal / 8 default prescaler), suggesting that the chip it's clocked correctly and, presumably (datasheet is unclear about this), alive and working.

The only odd thing about both my setups is that I'm powering VDD from 3V3 and Vdda from 5V.

SPI MISO is pulled high using a 10K resistor to 3V3. SPI is running in mode 0,0 with data valid on the clock's leading edge, as per the picture attached. I tried everything so far:
1. Disconnected the MISO line from the MCU. Tried both pulling it up and leaving it floating. Same result (0xFF when it's pulled up, 0x00 when it's left floating).
2. Tried all SPI modes.

I'm genuinely out of ideas, the SPI data looks correct, but the chip isn't replying at all.

Happy to try anything at this point and thanks for any idea you throw at me, no matter how crazy it might sound!
 

Attachments

Thread Starter

alexx_88

Joined May 24, 2010
28
hi alex,
I would use a PIO pin for the RESET, note the Section 5.1 regarding resetting.
E
View attachment 197045
Thanks for the suggestion. Unfortunately I'm really I/O constrained at this stage. However, I did consider your idea, hence testing with Microchip's development board. That has a reset switch that I'm using manually to reset the MCP25625, then try to talk to it after about 2-3s by sending the 'READ' command.
 

Thread Starter

alexx_88

Joined May 24, 2010
28
Quite a major development. :)

Have discovered that, as soon as SPI is enabled and configured on the processor (Kinetis MKW41Z), the high voltage of all SPI lines controlled by the peripheral drops to 1.9V. I'm using 10K 3V3 pull-ups on all SPI lines, so now trying to figure out what would cause that to happen.
 

ericgibbs

Joined Jan 29, 2010
18,766
hi alex,
I checked your circuit connections against the MCP d/s they looked OK.
Is there an equivalent state for the MCP, like Sleep or Disable thats being set.?
If so, that would explain the 1.9v outputs.
E
 

Thread Starter

alexx_88

Joined May 24, 2010
28
I disconnected the pin from the MCP and it's still going to 1.8V after the SPI peripheral is enabled. All eyes on MCU configuration registers right now. Being a low power chip that's designed to work at 1.8V, I reckon it's something in those registers.
 

Thread Starter

alexx_88

Joined May 24, 2010
28
So the whole problem was coming from the MKW41Z. Its internal DC regulator was in the wrong mode and essentially powering the chip at 1.8V. As soon as I (temporarily) managed to increase its voltage through SW to 2.2V, the MCP25625 started responding and sending out data like clockwork.

Thanks to everyone who came up with ideas!
 
Top