mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-24 07:29:42 +00:00
clean up gpio and leds
This commit is contained in:
parent
e825aa8bc9
commit
1522b72b1e
@ -1,4 +1,8 @@
|
||||
#ifndef BOARD_REDBEE_DEV_H
|
||||
#define BOARD_REDBEE_DEV_H
|
||||
|
||||
#define LED_RED (1 << 23)
|
||||
#define LED_GREEN (1 << 24)
|
||||
#define LED_BLUE (1 << 25)
|
||||
|
||||
#endif
|
||||
|
8
board/redbee-r1.h
Normal file
8
board/redbee-r1.h
Normal file
@ -0,0 +1,8 @@
|
||||
#ifndef BOARD_REDBEE_R1_H
|
||||
#define BOARD_REDBEE_R1_H
|
||||
|
||||
#define LED_RED (1 << 8)
|
||||
#define LED_GREEN (1 << 9)
|
||||
#define LED_BLUE (1 << 10)
|
||||
|
||||
#endif
|
@ -3,5 +3,6 @@
|
||||
|
||||
#include "types.h"
|
||||
#include "isr.h"
|
||||
#include "gpio.h"
|
||||
|
||||
#endif
|
||||
|
@ -1,12 +1,8 @@
|
||||
#include <mc1322x.h>
|
||||
|
||||
#define MBAR_GPIO 0x80000000
|
||||
#define GPIO_PAD_DIR0 ((volatile uint32_t *) 0x80000000)
|
||||
#define GPIO_DATA0 ((volatile uint32_t *) 0x80000008)
|
||||
#define UART1_DATA ((volatile uint32_t *) 0x80005008)
|
||||
#define DELAY 400000
|
||||
|
||||
//#define LED_BITS LED_RED
|
||||
#define LED_BITS LED_RED
|
||||
|
||||
__attribute__ ((section ("startup")))
|
||||
void main(void) {
|
||||
@ -14,7 +10,6 @@ void main(void) {
|
||||
|
||||
// *GPIO_PAD_DIR0 = LED_BITS;
|
||||
|
||||
|
||||
while(1) {
|
||||
|
||||
// *GPIO_DATA0 = LED_BITS;
|
||||
|
Loading…
Reference in New Issue
Block a user