Skip to content

Merge common files between LPC11XX and LPC11CXX #79

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
LPC1114 Port
LPC1114/LPC11C24 Port
--------------
A port of the MBED SDK to the NXP LPC1114 by Yoshihiro Tsuboi, Toyomasa Watarai and Matthew Else.
Extra, LPC11C24-specific things added by Joris Aerts.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,17 @@
#include "pinmap.h"
#include "error.h"

#include "adc_pinmap.h"
static const PinMap PinMap_ADC[] = {
{P0_11, ADC0_0, 2},
{P1_0 , ADC0_1, 2},
{P1_1 , ADC0_2, 2},
{P1_2 , ADC0_3, 2},
// {P1_3 , ADC0_4, 2}, -- should be mapped to SWDIO only
{P1_4 , ADC0_5, 1},
{P1_10, ADC0_6, 1},
{P1_11, ADC0_7, 1},
{NC , NC , 0}
};

#define ANALOGIN_MEDIAN_FILTER 1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,11 @@ struct spi_s {
LPC_SSP_TypeDef *spi;
};

#if DEVICE_CAN
struct can_s {
int index;
};
#endif

#include "gpio_object.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,31 @@
#include "pinmap.h"
#include "error.h"

#include "spi_pinmap.h"
static const PinMap PinMap_SPI_SCLK[] = {
{P0_6 , SPI_0, 0x02},
// {P0_10, SPI_0, 0x02}, -- should be mapped to SWCLK only
{P2_11, SPI_0, 0x01},
{P2_1 , SPI_1, 0x02},
{NC , NC , 0}
};

static const PinMap PinMap_SPI_MOSI[] = {
{P0_9 , SPI_0, 0x01},
{P2_3 , SPI_1, 0x02},
{NC , NC , 0}
};

static const PinMap PinMap_SPI_MISO[] = {
{P0_8 , SPI_0, 0x01},
{P2_2 , SPI_1, 0x02},
{NC , NC , 0}
};

static const PinMap PinMap_SPI_SSEL[] = {
{P0_2 , SPI_0, 0x01},
{P2_0 , SPI_1, 0x02},
{NC , NC , 0}
};

static inline int ssp_disable(spi_t *obj);
static inline int ssp_enable(spi_t *obj);
Expand Down