You say:
Now let's say you want to make a clk output that's as fast as possible. It will take a minimum of 4 instructions. One to turn the Pin ON, one to turn it off, and a GOTO (2 cycles) to create a loop."
-> Well, I also thought that the clock rising and falling was hardware controled (on the SCK pin of the pic), so there is no need to set the pin high then low by software to create a clock. Again, in the datasheet of the pic, at the section dedicated to MSSP, it is told that the clock can be as fast as 10MHz (FOSC/4) = 10Mpbs.
It seems the more I try to understand the less I do.
My problem is
1- to undestand the way things really work
2- make sure that with a 1ms delay I will have enough to transfer my 256 bytes array into the EEPROM page array if I'm using the HSPLL setting with a 10MHz xtal.
As with the send file from hyperterminal I have no flow control I unfortunately have a fixed inter-character delay of, let's say, 1ms, this is the time I have to transfer my array of 256 byte to the serial eeprom buffer and then initiate a page write that can take up to 10ms but then I don't care bescause while the 256 next bytes are received by the usart, I can wait for the write to be finished.
Norm did a project similar to mine (except he is using a 50MHz serial eeprom) and he is using flow control as he wrote a PC program to manage the character output.
My wish is to be able to transfer an pcm wave file to the eeprom then output is to a 16 bits dac. Timing seems somehow crucial in this project and this I need to understand.
Is there a way to know exactly how long it takes to transfer my 256 bytes array to the eeprom buffer?
You say:
"If you have a PIC with a 40mhz OSC, then the processor is running at FOSC/4, or 10mhz."
-> Then what is the PLL supposed to do. It should work as a clock multiplier so we get 40MHz out of a 10MHz xtal?
Bookmarks