Forums - [MDM9607] Adding a clock for a crystal oscillator in the device tree

3 posts / 0 new
Last post
[MDM9607] Adding a clock for a crystal oscillator in the device tree
pradeep.mohan
Join Date: 29 Jun 18
Posts: 1
Posted: Sun, 2018-07-01 09:58

Hello,

I'm not really sure if this is the correct forum, my apologies in advance if it isn't. We are currently using a Qualcomm MDM9607 based chipset for our telematics device. We are trying to interface with Microchip MCP2515 via SPI. The CAN SPI driver for the MCP2515 is already available in the SDK, it only needs the device tree to be adjusted for the driver to work. Using a solution similar to that recommended by one user on the Dragonboard Forums, I'm trying to get it working on our board too. 

This is the code from the user on the forum

clocks 
{ 
clk16m: oscillator 
{ #clock-cells = <0>;
  compatible = "fixed-clock"; 
 clock-frequency = <16000000>; 
}; 
}; 
 

However it seems qcom's implementation of the clocks are slightly different to that of native linux implementation. I've been trying to assign a fixed-clock to the MCP2515 without no results.  

I found the Peripheral Programming Guide, for Dragonboard. I see examples of how to add clock for UART etc, but I'm just wondering if I'm on the right track at all.. 

How would I create such a fixed clock for an external oscillator?  What changes do I make to the clock-gcc-mdm9607.c file? 

 

  • Up1
  • Down0
johnparker242018
Join Date: 23 Jul 18
Posts: 1
Posted: Mon, 2018-07-23 12:39

Yes, the code given is slightly different from native Linux implementation.  You can create a fixed clock for an external oscillator by clicking 

Bitdefender Error 1020 you will get the code which will work. you can install  SPI driver for the MCP2515 which are available in the SDK.

 

  • Up1
  • Down0
sharat.kulkarni
Join Date: 16 Mar 20
Posts: 2
Posted: Tue, 2021-01-26 21:44

Hi @pradeep.mohan ,

I was trying out a similar implementation on mdm chipset but while testing with a PEAK CAN USB Adapter  It was noticed that CAN messages were being dropped . For the 100% bus load at 250kbps, Theoretically 2000 CAN frames can be transmitted on the bus per second. I am transferring 10 CAN frames at 10ms in burst mode. There is still the data loss on the same

Did you / anyone here in the forum face this issue at your end ? If so any solutions to overcome the same ?

The issue is also discussed in below link

 => https://turlucode.com/nvidia-jetson-tk1-spi-to-can-interface-mcp251x-mcp...

 

 

Thanks & Regards

- Sharat S Kulkarni

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.