75 lines
2.2 KiB
C

/*******************************************************************************
* *
* Copyright 2010 Rheinmetall Canada Inc. *
* *
* No part of this document may be reproduced, stored in *
* a retrieval system, or transmitted, in any form or by any means, *
* electronic, mechanical, photocopying, recording, or otherwise, *
* without the prior written permission of Rheinmetall Canada Inc. *
* *
*******************************************************************************/
/*
Description:
This is a template file for standard C code file.
*/
/* ************************************************************************** */
/* ¤Revision:
000 20100616 JFM,
Original version.
### YYYYMMDD Initial, Bug Identification
Change description.
*/
/* ************************************************************************** */
/* Includes */
#include "DigitalIO.h"
#include "define.h"
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
void InitDigitalIO(void)
{
HEARTBEAT_LED_1_PIN_DIR = PIN_OUTPUT;
HEARTBEAT_LED_2_PIN_DIR = PIN_OUTPUT;
HEARTBEAT_LED_2_PIN = LED_OFF;
HEARTBEAT_LED_1_PIN = LED_OFF;
// SD_SPI_CS_PIN_DIR = PIN_OUTPUT;
// SD_SPI_CS_PIN = 1;
// SD_SPI_SDI_PIN_DIR = PIN_INPUT;
// DOOR_PAD_D0_PIN_DIR = PIN_INPUT;
// DOOR_PAD_D1_PIN_DIR
// DOOR_PAD_D1_PIN
// //Wifi chip IRQ
// IEC0bits.INT0IE = 0;
// IFS0bits.INT0IF = 0;
// INTCONbits.INT0EP = 0; //Rising edge
// IPC0bits.INT0IP = 3;
// IPC0bits.INT0IS = 0;
// IEC0bits.INT0IE = 1;
//
// //Wifi chip SPI
// SPI2CON = 0;
// SPI2CONbits.MSTEN = 1;
// SPI2CONbits.CKE = 1;
// SPI2CONbits.SMP = 0;
// SPI2CONbits.CKP = 0;
// SPI2BRG = SPICalculateBRG(PERIPHERAL_FREQ, 10000000);
// SPI2CONbits.ON = 1;
}
//EOF