I program the fuses of an AtMega for, say, 8 Mhz internal clock with a clock divider of 8 (giving a 'final' clock frequency of 1 Mhz), what will the SPI.setClockDivider() be based on? The 8 Mhz or the 1 Mhz?
What is the difference between running a chip at 8 Mhz with a clock divider of 8 and running the chip at 1 Mhz with no clock divider?
Should there be any difference in power consumption?
I program the fuses of an AtMega for, say, 8 Mhz internal clock with a clock divider of 8 (giving a 'final' clock frequency of 1 Mhz), what will the SPI.setClockDivider() be based on? The 8 Mhz or the 1 Mhz?
The final clock speed (1 MHz).
What is the difference between running a chip at 8 Mhz with a clock divider of 8 and running the chip at 1 Mhz with no clock divider?
The reason I ask is that I am using a Hope RFM22 SPI transceiver (RFM22B-S2 SMD Wireless Transceiver - 434MHz - WRL-10153 - SparkFun Electronics) and it doesn't state the SPI speeds that it can handle. I am running an Atmega 328p in low power mode (3.3v, 8mhz/1Mhz internal) and it is hanging intermittently. I have tried different chips. I was wondering whether the comms between the two is the problem and what I should set the SPI speed at.
Can you run to slow a speed with SPI? How can you tell if you are running too fast? (I haven't got an oscilloscope)
The SCLK rate is flexible with a maximum rate of 10 MHz.
SPI is self-clocked so the speed shouldn't be critical. Since the device can handle 10 MHz there is no particular reason to divide the SPI clock. You may have coding or electrical issues.
lemming , do you resolve this problem? I have also problem with Arduino pro mini (3.3v/8MHz) and rfm22. When arduino is supplied via arduino uno or computer power supply (3.3V) all is ok, but when arduino is connected to battery (18650 -3.7V) or any power supply, working about 10sec. How to solve the problem?