source: rtems/c/src/lib/libbsp/arm/tms570/include/tms570-sci.h @ 991fdb33

4.11
Last change on this file since 991fdb33 was 4407ee6, checked in by Premysl Houdek <kom541000@…>, on Aug 20, 2014 at 3:24:23 PM

BSP for TMS570LS31x Hercules Development Kit from TI (TMS570LS3137)

Included variants:

tms570ls3137_hdk_intram - place code and data into internal SRAM
tms570ls3137_hdk_sdram - place code into external SDRAM and data to SRAM
tms570ls3137_hdk - variant prepared for stand-alone RTEMS aplication

stored and running directly from flash. Not working yet.

Chip initialization code not included in BSP.
External startup generated by TI's HalCoGen? was used for
testing and debugging.

More information about TMS570 BSP can be found at

http://www.rtems.org/wiki/index.php/Tms570

Patch version 2

  • most of the formatting suggestion applied.
  • BSP converted to use clock shell
  • console driver "set attributes" tested. Baudrate change working

Patch version 3

  • more formatting changes.
  • removed leftover defines and test functions

Todo:

refactor header files (name register fields)

  • Property mode set to 100644
File size: 2.3 KB
RevLine 
[4407ee6]1/**
2 * @file tms570-sci.h
3 *
4 * @ingroup tms570
5 *
6 * @brief Serial Communication Interface (SCI) header file.
7 */
8
9/*
10 * Copyright (c) 2014 Premysl Houdek <kom541000@gmail.com>
11 *
12 * Google Summer of Code 2014 at
13 * Czech Technical University in Prague
14 * Zikova 1903/4
15 * 166 36 Praha 6
16 * Czech Republic
17 *
18 * Based on LPC24xx and LPC1768 BSP
19 * by embedded brains GmbH and others
20 *
21 * The license and distribution terms for this file may be
22 * found in the file LICENSE in this distribution or at
23 * http://www.rtems.org/license/LICENSE.
24 */
25
26#ifndef LIBBSP_ARM_TMS570_SCI_H
27#define LIBBSP_ARM_TMS570_SCI_H
28
29#include <libchip/serial.h>
30
31#include <rtems.h>
32#include <stdint.h>
33
34#ifdef __cplusplus
35extern "C" {
36#endif /* __cplusplus */
37
38typedef struct {
39  uint32_t SCIGCR0;         /*SCIGlobalControlRegister0*/
40  uint32_t SCIGCR1;         /*SCIGlobalControlRegister1*/
41  uint32_t reserved1 [0x4/4];
42  uint32_t SCISETINT;       /*SCISetInterruptRegister*/
43  uint32_t SCICLEARINT;     /*SCIClearInterruptRegister*/
44  uint32_t SCISETINTLVL;    /*SCISetInterruptLevelRegister*/
45  uint32_t SCICLEARINTLVL;  /*SCIClearInterruptLevelRegister*/
46  uint32_t SCIFLR;          /*SCIFlagsRegister*/
47  uint32_t SCIINTVECT0;     /*SCIInterruptVectorOffset0*/
48  uint32_t SCIINTVECT1;     /*SCIInterruptVectorOffset1*/
49  uint32_t SCIFORMAT;       /*SCIFormatControlRegister*/
50  uint32_t BRS;             /*BaudRateSelectionRegister*/
51  uint32_t SCIED;           /*ReceiverEmulationDataBuffer*/
52  uint32_t SCIRD;           /*ReceiverDataBuffer*/
53  uint32_t SCITD;           /*TransmitDataBuffer*/
54  uint32_t SCIPIO0;         /*SCIPinI/OControlRegister0*/
55  uint32_t SCIPIO1;         /*SCIPinI/OControlRegister1*/
56  uint32_t SCIPIO2;         /*SCIPinI/OControlRegister2*/
57  uint32_t SCIPIO3;         /*SCIPinI/OControlRegister3*/
58  uint32_t SCIPIO4;         /*SCIPinI/OControlRegister4*/
59  uint32_t SCIPIO5;         /*SCIPinI/OControlRegister5*/
60  uint32_t SCIPIO6;         /*SCIPinI/OControlRegister6*/
61  uint32_t SCIPIO7;         /*SCIPinI/OControlRegister7*/
62  uint32_t SCIPIO8;         /*SCIPinI/OControlRegister8*/
63  uint32_t reserved2 [0x30/4];
64  uint32_t IODFTCTRL;       /*Input/OutputErrorEnableRegister*/
65}tms570_sci_t;
66
67#define TMS570_SCI (*(volatile tms570_sci_t*)0xFFF7E400U)
68#define TMS570_SCI2 (*(volatile tms570_sci_t*)0xFFF7E500U)
69
70/** @} */
71
72#ifdef __cplusplus
73}
74#endif /* __cplusplus */
75
76#endif
Note: See TracBrowser for help on using the repository browser.