A clock frequence can be adjust from 100Mhz to 400Mhz step by 20Mhz?

Technical discussions around xCORE processors (e.g. General Purpose (L/G), xCORE-USB, xCORE-Analog, xCORE-XA).
Schatz143
Member++
Posts: 31
Joined: Mon Jan 20, 2020 9:54 am

Re: A clock frequence can be adjust from 100Mhz to 400Mhz step by 20Mhz?

Postby Schatz143 » Mon Mar 09, 2020 1:04 pm

if there is an ADC which has a feature "20-MHz Serial Interface".
Can i just configure configure_clock_rate(clk,100,5) in the master and syncronise ?
User avatar
mon2
XCore Legend
Posts: 1831
Joined: Thu Jun 10, 2010 11:43 am

Postby mon2 » Mon Mar 09, 2020 1:22 pm

I think there may be some confusion between the fixed clocks and serial communication clocks.

Can you post your exact ADC part number? Sounds like you are referencing the SPI SCLK value for the ADC?

If yes then the SPI master IP must be configured to generate this SCLK value at 20mhz.

See attached document on how to achieve this value.

XMOS-SPI-Component-Documentation_X3171A.pdf
You do not have the required permissions to view the files attached to this post.
Schatz143
Member++
Posts: 31
Joined: Mon Jan 20, 2020 9:54 am

Postby Schatz143 » Mon Mar 09, 2020 2:00 pm

Here is the ADC.Would like to interface this one .
http://www.ti.com/product/ADS7886
User avatar
mon2
XCore Legend
Posts: 1831
Joined: Thu Jun 10, 2010 11:43 am

Postby mon2 » Mon Mar 09, 2020 3:29 pm

Yes, SPI interface and IP can be used to communicate with this ADC. Google for the keywords "ADS7886 SPI" to review the code deployed by others using Arduino / STM32 and other CPUs.
Schatz143
Member++
Posts: 31
Joined: Mon Jan 20, 2020 9:54 am

Postby Schatz143 » Wed Mar 11, 2020 8:14 am

I am confused how to use serial data input( Mosi )for this ADC. Am i missing something here?
You do not have the required permissions to view the files attached to this post.
User avatar
mon2
XCore Legend
Posts: 1831
Joined: Thu Jun 10, 2010 11:43 am

Postby mon2 » Wed Mar 11, 2020 8:37 am

For this ADC, the MOSI pin not be used. You will use MISO (master in, slave out) and SCLK.

MISO = SDO

SCLK = SCLK

#CS = #CS
Schatz143
Member++
Posts: 31
Joined: Mon Jan 20, 2020 9:54 am

Postby Schatz143 » Wed Mar 11, 2020 9:07 am

is there any example code to understand the SPI Interface functionality for this ADC.I read interfacing high speed adc but slave module is in simulation and its has all the pins MISO;MOSI;SCLK;CS:
And i searched for ADS7886 SPI on google and code for Arduino / STM32 isnt helpful .have no idea in using that code in XC.Would appreciate little help in forming a simple code .

Who is online

Users browsing this forum: No registered users and 1 guest