OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [rtos/] [rtems/] [c/] [src/] [libchip/] [serial/] [mc68681_baud.c] - Blame information for rev 587

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 30 unneback
/*
2
 *  MC68681 Default Baud Rate Table
3
 *
4
 *  $Id: mc68681_baud.c,v 1.2 2001-09-27 12:01:42 chris Exp $
5
 */
6
 
7
#include <rtems.h>
8
#include <libchip/serial.h>
9
#include <libchip/mc68681.h>
10
 
11
/* major index of 0 : ACR[7] = 0, X = 0 -- 68c681 only has these */
12
/* major index of 1 : ACR[7] = 1, X = 0 -- 68c681 only has these */
13
/* major index of 2 : ACR[7] = 0, X = 1 */
14
/* major index of 3 : ACR[7] = 1, X = 1 */
15
 
16
/* mc68681_baud_table_t mc68681_baud_rate_table[4] = { */
17
mc68681_baud_t mc68681_baud_rate_table[4][RTEMS_TERMIOS_NUMBER_BAUD_RATES] = {
18
  { /* ACR[7] = 0, X = 0 */
19
    MC68681_BAUD_NOT_VALID,    /* B0 */
20
    0x00,                      /* B50 */
21
    MC68681_BAUD_NOT_VALID,    /* B75 */
22
    0x01,                      /* B110 */
23
    0x02,                      /* B134 */
24
    MC68681_BAUD_NOT_VALID,    /* B150 */
25
    0x03,                      /* B200 */
26
    0x04,                      /* B300 */
27
    0x05,                      /* B600 */
28
    0x06,                      /* B1200 */
29
    MC68681_BAUD_NOT_VALID,    /* B1800 */
30
    0x08,                      /* B2400 */
31
    0x09,                      /* B4800 */
32
    0x0B,                      /* B9600 */
33
    MC68681_BAUD_NOT_VALID,    /* B19200 */
34
    0x0C,                      /* B38400 */
35
    MC68681_BAUD_NOT_VALID,    /* B57600 */
36
    MC68681_BAUD_NOT_VALID,    /* B115200 */
37
    MC68681_BAUD_NOT_VALID,    /* B230400 */
38
    MC68681_BAUD_NOT_VALID     /* B460800 */
39
  },
40
  { /* ACR[7] = 1, X = 0 */
41
    MC68681_BAUD_NOT_VALID,    /* B0 */
42
    MC68681_BAUD_NOT_VALID,    /* B50 */
43
    0x00,                      /* B75 */
44
    0x01,                      /* B110 */
45
    0x02,                      /* B134 */
46
    0x03,                      /* B150 */
47
    MC68681_BAUD_NOT_VALID,    /* B200 */
48
    0x04,                      /* B300 */
49
    0x05,                      /* B600 */
50
    0x06,                      /* B1200 */
51
    0x0A,                      /* B1800 */
52
    0x08,                      /* B2400 */
53
    0x09,                      /* B4800 */
54
    0x0B,                      /* B9600 */
55
    0x0C,                      /* B19200 */
56
    MC68681_BAUD_NOT_VALID,    /* B38400 */
57
    MC68681_BAUD_NOT_VALID,    /* B57600 */
58
    MC68681_BAUD_NOT_VALID,    /* B115200 */
59
    MC68681_BAUD_NOT_VALID,    /* B230400 */
60
    MC68681_BAUD_NOT_VALID     /* B460800 */
61
  },
62
  { /* ACR[7] = 0, X = 1 */
63
    MC68681_BAUD_NOT_VALID,    /* B0 */
64
    MC68681_BAUD_NOT_VALID,    /* B50 */
65
    0x00,                      /* B75 */
66
    0x01,                      /* B110 */
67
    0x02,                      /* B134 */
68
    0x03,                      /* B150 */
69
    MC68681_BAUD_NOT_VALID,    /* B200 */
70
    MC68681_BAUD_NOT_VALID,    /* B300 */
71
    MC68681_BAUD_NOT_VALID,    /* B600 */
72
    MC68681_BAUD_NOT_VALID,    /* B1200 */
73
    0x0A,                      /* B1800 */
74
    MC68681_BAUD_NOT_VALID,    /* B2400 */
75
    0x08,                      /* B4800 */
76
    0x0B,                      /* B9600 */
77
    0x0C,                      /* B19200 */
78
    MC68681_BAUD_NOT_VALID,    /* B38400 */
79
    0x07,                      /* B57600 */
80
    0x08,                      /* B115200 */
81
    MC68681_BAUD_NOT_VALID,    /* B230400 */
82
    MC68681_BAUD_NOT_VALID     /* B460800 */
83
  },
84
  { /* ACR[7] = 1, X = 1 */
85
    MC68681_BAUD_NOT_VALID,    /* B0 */
86
    0x00,                      /* B50 */
87
    MC68681_BAUD_NOT_VALID,    /* B75 */
88
    0x01,                      /* B110 */
89
    0x02,                      /* B134 */
90
    MC68681_BAUD_NOT_VALID,    /* B150 */
91
    0x03,                      /* B200 */
92
    MC68681_BAUD_NOT_VALID,    /* B300 */
93
    MC68681_BAUD_NOT_VALID,    /* B600 */
94
    MC68681_BAUD_NOT_VALID,    /* B1200 */
95
    MC68681_BAUD_NOT_VALID,    /* B1800 */
96
    MC68681_BAUD_NOT_VALID,    /* B2400 */
97
    0x09,                      /* B4800 */
98
    0x0B,                      /* B9600 */
99
    MC68681_BAUD_NOT_VALID,    /* B19200 */
100
    0x0C,                      /* B38400 */
101
    0x07,                      /* B57600 */
102
    0x08,                      /* B115200 */
103
    MC68681_BAUD_NOT_VALID,    /* B230400 */
104
    MC68681_BAUD_NOT_VALID     /* B460800 */
105
  },
106
};
107
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.