kashifaslam Member K Join Date Oct 2010 Location houston Posts 2 Oct 25, 2010 #1 Can anyone help me writing a test C program to check if it runs in the SixNet RTU. Any program will do(as simple as addition), I just need to test the loading of C program into RTU.
Can anyone help me writing a test C program to check if it runs in the SixNet RTU. Any program will do(as simple as addition), I just need to test the loading of C program into RTU.
Dravik Member D Join Date Jun 2008 Location New York Posts 1,650 Oct 25, 2010 #2 Code: #include <stdio.h> void main() { printf("\nHello World\n"); } Last edited: Oct 25, 2010
504bloke Lifetime Supporting Member Join Date Jan 2005 Location Down South Posts 2,721 Oct 25, 2010 #3 Code: #include <stdio.h> #define Max 10 int main() { int i, sum = 0; for ( i = 1; i <= Max; i++ ) { sum += i; } printf("sum = %d\n", sum); return 0; } Last edited: Oct 25, 2010
Code: #include <stdio.h> #define Max 10 int main() { int i, sum = 0; for ( i = 1; i <= Max; i++ ) { sum += i; } printf("sum = %d\n", sum); return 0; }