gcc toolchain on Ubuntu and quickstart board -- success
manitou
Posts: 29
Built various demos on Ubuntu 12.04 with QuickStart board. Here is simple C program to read buttons and turn on touched LEDs.
I got all of the fibo demos to work excpet xmm?? -- it loaded but nothing was printed to terminal ?? (xmmc worked)
Here are some simple "speed" tests.
How fast can I read CNT (e.g. t1=CNT; t2= CNT-t1; )
recursive fibonacci (fibo(26))
// quickstart board resistive buttons 0-7 LEDs 16-23 // bring pad HIGH, touching button brings it LOW #include <propeller.h> #define BUTTONS (0xff) #define LEDS (0xff<<16) int main() { DIRA |= BUTTONS | LEDS; // output OUTA |= BUTTONS; // bring high while(1) { DIRA |= BUTTONS; // output DIRA &= ~BUTTONS; // input mode waitcnt(CNT + CLKFREQ/1000); // ms wait OUTA &= ~LEDS; // clear LEDs OUTA |= ((~( INA & BUTTONS)) << 16) & LEDS; // in,flip,shift,mask } return 0; }
I got all of the fibo demos to work excpet xmm?? -- it loaded but nothing was printed to terminal ?? (xmmc worked)
Here are some simple "speed" tests.
How fast can I read CNT (e.g. t1=CNT; t2= CNT-t1; )
gcc 16 cycles
catalina-3.6 112 cycles (with external CNT)
spin 368 cycles
presumably PASM could do it in 4 cycles.
catalina-3.6 112 cycles (with external CNT)
spin 368 cycles
presumably PASM could do it in 4 cycles.
recursive fibonacci (fibo(26))
catalina 3.6 5342 ms
gcc cog 486 ms
gcc lmm 927 ms
arduino uno (16MHz) 32-bit int's 927 ms
maple (72MHz) 104 ms
beaglebone (720MHz) 8.2 ms
ubuntu/i3-2370M (2.4GHz) 1.2ms
MD5 (KBs == 1024 bytes/second)
gcc cog 486 ms
gcc lmm 927 ms
arduino uno (16MHz) 32-bit int's 927 ms
maple (72MHz) 104 ms
beaglebone (720MHz) 8.2 ms
ubuntu/i3-2370M (2.4GHz) 1.2ms
spin 7 KBs catalina 84 KBs gcc 222 KBs (lmm)
arduino 48 KBs
maple 1937 KBs
beaglebone 13755 KBs
ubuntu 187958 KBs
arduino 48 KBs
maple 1937 KBs
beaglebone 13755 KBs
ubuntu 187958 KBs
Comments
Thanks,
--Steve
http://www.ietf.org/rfc/rfc1321.txt
spin code http://obex.parallax.com/objects/321/
gcc 47ms
catalina-3.6 410ms
arduino UNO can't do it (only 2K sram)
maple 8 ms
beaglebone 0.375 ms (had to do it 1000 times to exceed a ms, then divide out 1000)
ubuntu 0.053ms (needed 1000 iterations)