LPC11xx DPI driver working, demo updated.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@2286 35acf78f-673a-0410-8e92-d51de3d6d3f4
This commit is contained in:
parent
af0921235f
commit
da7438dffe
|
@ -53,7 +53,8 @@
|
|||
*/
|
||||
#define VAL_GPIO1DIR PAL_PORT_BIT(GPIO1_LED3B) | \
|
||||
PAL_PORT_BIT(GPIO1_LED3R) | \
|
||||
PAL_PORT_BIT(GPIO1_LED3G)
|
||||
PAL_PORT_BIT(GPIO1_LED3G) | \
|
||||
PAL_PORT_BIT(GPIO1_SPI0SEL)
|
||||
#define VAL_GPIO1DATA 0x00000000
|
||||
|
||||
/*
|
||||
|
|
|
@ -21,10 +21,14 @@
|
|||
#include "hal.h"
|
||||
#include "test.h"
|
||||
|
||||
static void endsend(SPIDriver *spip) {
|
||||
|
||||
spiUnselect(spip);
|
||||
}
|
||||
|
||||
/* Maximum speed SPI configuration (1MHz, CPHA=0, CPOL=0).*/
|
||||
static SPIConfig spicfg = {
|
||||
NULL,
|
||||
endsend,
|
||||
GPIO1,
|
||||
GPIO1_SPI0SEL,
|
||||
CR0_DSS8BIT | CR0_FRFSPI | CR0_CLOCKRATE(0),
|
||||
|
@ -40,6 +44,7 @@ static msg_t Thread1(void *arg) {
|
|||
|
||||
(void)arg;
|
||||
while (TRUE) {
|
||||
spiSelect(&SPID1);
|
||||
spiStartSend(&SPID1, 1, &digit);
|
||||
digit++;
|
||||
palClearPad(GPIO0, GPIO0_LED2);
|
||||
|
|
|
@ -119,6 +119,7 @@
|
|||
new SPI device driver model.
|
||||
- NEW: Improved AT91SAM7 SPI driver, now it uses IRQs and DMAs, it implements
|
||||
the new SPI device driver model.
|
||||
- NEW: New LPC11xx SPI driver.
|
||||
- NEW: Added a simple STM32 ADC demo under ./testhal/STM32/ADC.
|
||||
- NEW: Added a simple STM32 CAN demo under ./testhal/STM32/CAN.
|
||||
- NEW: Added a simple STM32 PWM demo under ./testhal/STM32/PWM.
|
||||
|
|
Loading…
Reference in New Issue