Project

General

Profile

Revision 249

implementing uart. done with basic functions, still planning protocol

View differences:

proj.c
30 30
#include "list.h"
31 31

  
32 32
#ifdef DIOGO
33
    #include "uart_macros.h"
34 33
    #include "test7.h"
35 34
#endif
36 35

  
......
159 158
        //UART
160 159
        unsigned long bits = 8;
161 160
        unsigned long stop = 2;
162
        long parity = -1;
161
        long parity = 0;
163 162
        unsigned long rate = 9600;
164
        unsigned char tx = 0;
163
        unsigned char tx = 1;
165 164
        int stringc = 2;
166
        char *strings[] = {"Hello", "world"};
167
        if((r = ser_test_conf(COM1_ADDR))) return r;
168
        if((r = ser_test_set(COM1_ADDR, bits, stop, parity, rate))) return r;
165
        char *strings[] = {"Hello", "world"}; (void)strings;
166
        //if((r = ser_test_conf(COM1_ADDR))) return r;
167
        //if((r = ser_test_set(COM1_ADDR, bits, stop, parity, rate))) return r;
169 168
        if((r = ser_test_poll(COM1_ADDR, tx, bits, stop, parity, rate, stringc, strings))) return r;
169
        printf("DONE\n");
170 170
    #endif
171 171
    #ifndef DIOGO
172 172
        ent_set_scale(DEFAULT_SCALE);

Also available in: Unified diff