Library to access LPC17xx peripherals. It uses static inline functions, constant propagation and dead code elimination to be as fast as possible.
Dependents: Chua-VGA Wolfram-1D-VGA WolframRnd-1D-VGA Basin-VGA ... more
ssp.h@2:148b9af2b336, 2012-01-04 (annotated)
- Committer:
- Ivop
- Date:
- Wed Jan 04 01:42:56 2012 +0000
- Revision:
- 2:148b9af2b336
- Parent:
- 1:bc492a93e116
fixed bug in fl_uart_send_byte. thanks to smayr for finding it
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Ivop | 1:bc492a93e116 | 1 | /* Copyright (C) 2011 by Ivo van Poorten <ivop@euronet.nl> |
Ivop | 1:bc492a93e116 | 2 | * This file is licensed under the terms of the GNU Lesser |
Ivop | 1:bc492a93e116 | 3 | * General Public License, version 3. |
Ivop | 1:bc492a93e116 | 4 | */ |
Ivop | 1:bc492a93e116 | 5 | |
Ivop | 1:bc492a93e116 | 6 | #ifndef FASTLIB_SSP_H |
Ivop | 1:bc492a93e116 | 7 | #define FASTLIB_SSP_H |
Ivop | 1:bc492a93e116 | 8 | |
Ivop | 1:bc492a93e116 | 9 | #include "fastlib/common.h" |
Ivop | 1:bc492a93e116 | 10 | |
Ivop | 1:bc492a93e116 | 11 | #define FL_SSP0 ((volatile uint32_t *) 0x40088000) |
Ivop | 1:bc492a93e116 | 12 | #define FL_SSP1 ((volatile uint32_t *) 0x40030000) |
Ivop | 1:bc492a93e116 | 13 | |
Ivop | 1:bc492a93e116 | 14 | #define FL_SSP_CR0 0x00 |
Ivop | 1:bc492a93e116 | 15 | #define FL_SSP_CR1 0x04 |
Ivop | 1:bc492a93e116 | 16 | #define FL_SSP_DR 0x08 |
Ivop | 1:bc492a93e116 | 17 | #define FL_SSP_SR 0x0C |
Ivop | 1:bc492a93e116 | 18 | #define FL_SSP_CPSR 0x10 |
Ivop | 1:bc492a93e116 | 19 | #define FL_SSP_IMSC 0x14 |
Ivop | 1:bc492a93e116 | 20 | #define FL_SSP_RIS 0x18 |
Ivop | 1:bc492a93e116 | 21 | #define FL_SSP_MIS 0x1C |
Ivop | 1:bc492a93e116 | 22 | #define FL_SSP_ICR 0x20 |
Ivop | 1:bc492a93e116 | 23 | #define FL_SSP_DMACR 0x24 |
Ivop | 1:bc492a93e116 | 24 | |
Ivop | 1:bc492a93e116 | 25 | #define FL_SSP(num, reg) (FL_SSP##num + (volatile unit32_t *)FL_SSP_##reg) |
Ivop | 1:bc492a93e116 | 26 | |
Ivop | 1:bc492a93e116 | 27 | // NOT FINISHED YET |
Ivop | 1:bc492a93e116 | 28 | |
Ivop | 1:bc492a93e116 | 29 | #endif |