Changeset - cadd69fc3fad
[Not reviewed]
default
2 6 2
kripperger@CL-SEC241-09.cedarville.edu - 13 years ago 2012-11-07 19:55:15
kripperger@CL-SEC241-09.cedarville.edu
File Rename
8 files changed with 37 insertions and 29 deletions:
0 comments (0 inline, 0 general)
master/master/master.c
Show inline comments
 
/*
 
 * Master Firmware
 
 *
 
 * Wireless Observational Modular Aerial Network
 
 * 
 
 * Ethan Zonca
 
 * Matthew Kanning
 
 * Kyle Ripperger
 
 * Matthew Kroening
 
 *
 
 */
 
 
 
#include "config.h"
 
 
#include <avr/io.h>
 
#include <util/delay.h>
 
 
#include "lib/serial.h"
 
#include "lib/afsk.h"
 
#include "lib/led.h"
 
 
void micro_setup() {
 
	// Generic microcontroller config options
 
	
 
}
 
 
int main(void)
 
{
 
	// Initialize
 
	micro_setup();
 
	led_setup();
 
	serial_setup(); // Config serial ports
 
	afsk_setup();
 
	
 
    while(1)
 
    {
 
		afsk_test();
 
        //serial_SendCommand('0','A',0,0);
 
    }
 
}
 
\ No newline at end of file
slave/slave/config.h
Show inline comments
 
/*
 
 * config.h
 
 *
 
 * Created: 10/25/2012 10:00:09 PM
 
 *  Author: mkanning
 
 */
 
 
 
 #ifndef CONFIG_H_
 
 #define CONFIG_H_
 
 
 #define F_CPU 11059200
 
 #define USART_BAUDRATE 19200
 
 #define MODULE_ID '2'			//TEMP
 
 
 
 #endif /* CONFIG_H_ */
 
\ No newline at end of file
slave/slave/lib/inputOutput.c
Show inline comments
 
file renamed from slave/slave/lib/io.c to slave/slave/lib/inputOutput.c
 
/*
 
 * io.c
 
 *
 
 * Created: 11/7/2012 7:17:52 PM
 
 *  Author: kripperger
 
 */ 
 
 
 #include <avr/io.h>
 
 
 
 uint8_t io_getModuleId() {
 
	//get ID from rotary dip and return it. 
 
	
 
	uint8_t id;
 
 
	id = 0; //DEBUG
 
 
	return id;
 
 }
 
\ No newline at end of file
slave/slave/lib/inputOutput.h
Show inline comments
 
file renamed from slave/slave/lib/io.h to slave/slave/lib/inputOutput.h
 
/*
 
 * io.h
 
 *
 
 * Created: 11/7/2012 7:18:08 PM
 
 *  Author: kripperger
 
 */ 
 
 
 
#ifndef IO_H_
 
#define IO_H_
 
 #ifndef IO_H_
 
 #define IO_H_
 
 
 uint8_t io_getModuleId();	//get ID from rotary dip and return it.
 
 
 
 
 
 
#endif /* IO_H_ */
 
\ No newline at end of file
 
 #endif /* IO_H_ */
 
\ No newline at end of file
slave/slave/lib/led.c
Show inline comments
 
/*
 
 * led.c
 
 *
 
 * Created: 10/25/2012 10:03:22 PM
 
 *  Author: mkanning
 
 */
 
 
 #include <avr/io.h>
 
 
 void led_Configure() {
 
 void led_configure() {
 
	 // Configure ports/pins for LEDs
 
 }
 
 
 void led_On(uint8_t led) {
 
 void led_on(uint8_t led) {
 
	 // Turn the specified LED on
 
 }
 
 
 void led_Off(uint8_t led) {
 
 void led_off(uint8_t led) {
 
	 // Turn the specified LED off
 
 }
 
 
 void led_Toggle(uint8_t led) {
 
 void led_toggle(uint8_t led) {
 
	 // Toggle the specified LED
 
 }
 
\ No newline at end of file
slave/slave/lib/led.h
Show inline comments
 
/*
 
 * led.h
 
 *
 
 * Created: 10/25/2012 10:01:29 PM
 
 *  Author: mkanning
 
 */
 
 
 
 #ifndef LED_H_
 
 #define LED_H_
 
 
 #define POWER 1
 
 #define ERROR 2
 
 #define STAT 3
 
 #define OK 4
 
 
 void led_Configure();
 
 void led_On(uint8_t led);
 
 void led_Off(uint8_t led);
 
 void led_Toggle(uint8_t led);
 
 void led_configure();
 
 void led_on(uint8_t led);
 
 void led_off(uint8_t led);
 
 void led_toggle(uint8_t led);
 
 
 
 #endif /* LED_H_ */
slave/slave/slave.c
Show inline comments
 
/*
 
 * Slave Firmware
 
 *
 
 * Wireless Observational Modular Aerial Network
 
 * 
 
 * Ethan Zonca
 
 * Matthew Kanning
 
 * Kyle Ripperger
 
 * Matthew Kroening
 
 *
 
 */
 
 
 
#include "config.h"
 
 
#include <avr/io.h>
 
#include <util/delay.h>
 
 
#include "lib/serial.h"
 
//#include "lib/serial.h"
 
#include "lib/led.h"
 
 
void micro_setup() {
 
	// Generic microcontroller config options
 
	
 
}
 
 
 
 
int main(void)
 
{
 
	// Initialize
 
	micro_setup();
 
	led_setup();
 
	serial_setup(); // Config serial ports
 
	led_configure();
 
	//serial_setup(); // Config serial ports
 
	uint8_t moduleID = io_getModuleId(); //Slave Module ID from rotary dip switch
 
	
 
	
 
    while(1)
 
    {
 
        //serial_SendCommand('0','A',0,0);
 
    }
 
	
 
	return 0;
 
}
 
\ No newline at end of file
slave/slave/slave.cproj
Show inline comments
 
@@ -62,48 +62,36 @@
 
        </avrgcc.linker.libraries.Libraries>
 
        <avrgcc.assembler.debugging.DebugLevel>Default (-Wa,-g)</avrgcc.assembler.debugging.DebugLevel>
 
      </AvrGcc>
 
    </ToolchainSettings>
 
  </PropertyGroup>
 
  <ItemGroup>
 
    <Compile Include="config.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\i2c.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\i2c.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\io.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\io.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\led.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\serial.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\serial.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\led.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\serparser.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="lib\serparser.h">
 
      <SubType>compile</SubType>
 
    </Compile>
 
    <Compile Include="slave.c">
 
      <SubType>compile</SubType>
 
    </Compile>
 
  </ItemGroup>
 
  <ItemGroup>
 
    <Folder Include="lib" />
 
  </ItemGroup>
 
  <Import Project="$(AVRSTUDIO_EXE_PATH)\\Vs\\Compiler.targets" />
 
</Project>
 
\ No newline at end of file
0 comments (0 inline, 0 general)