Equipment: StarterWare_02_00_01_01, XDS100v2, Windows7, CCS6, BBB A6
Hi,
testing the GPIO performance with a BBB I wrote a function that contains 10 times the following code. The function runs in an infinite loop:
asm(" LDMIA r0!,{r3}"); // get the data addressed by r0 and load it to r3, increment r0
asm(" STR R3,[R1]"); // write to GPIO1_06
asm(" LDMIA r0!,{r3}");
asm(" STR R3,[R1]");
The value loaded to r3 in turn is either 0x40 or 0, i.e. GPIO_06 is alternately set HIGH and LOW.
What I saw on the scope was somewhat disappointing:
1. In most cases HIGH and LOW time had an equal value of 440ns, i.e. only about 1.136MHz for one on/off cycle.
I did not do any cache activation or fpu enabling. Should I?
I read that 10 to 15MHz shall be possible. How could that be achieved?
2. But the time for the LOW and HIGH signal was not always 440ns. Sometimes it was bigger: 688 or 888ns for instance (within a group of 10 on/offs).
That means something is disturbing the process.
I am aware that all other GPIO1 bits are cleared. But should that have any influence on the continuity of the outputs?
Can I do something to get higher output rates and a continuous signal?
(No, not by PRU. I need at least 16 output pins.)
Thank you!
Martin H.