Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Peripheral Clock
PostPosted: Mon Mar 15, 2010 6:52 pm 
Offline

Joined: Mon Mar 08, 2010 7:38 pm
Posts: 6
You can set the Peripheral Clock with a divider?
I would decrease the speed of the SPI bus under Mhz but with the log SCBR I can get only up to 1 MHz.


Top
 Profile  
 
 Post subject: Re: Peripheral Clock
PostPosted: Wed Mar 17, 2010 4:38 pm 
Offline

Joined: Thu Jan 28, 2010 10:30 am
Posts: 5
If your are using the spidev driver you can set the SPI CLK in the spidev_test.c program.

*******************************
* spidev_test.c
*******************************
static uint8_t bits = 8;
static uint32_t speed = 500000; // 500 kHz
static uint16_t delay;
*******************************

Michael


Top
 Profile  
 
 Post subject: Re: Peripheral Clock
PostPosted: Thu Mar 18, 2010 4:57 pm 
Offline

Joined: Mon Mar 08, 2010 7:38 pm
Posts: 6
I need the prescaler, if seven to 500kHz the device returns an error of spi
MAIN-CLK is 400mhz then 400/255-> 1MHz for the SPI device.
but in theory it would be possible to use a custom clk?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: