Elisa3
|
Utility module. More...
#include "variables.h"
#include <avr\io.h>
#include <avr\interrupt.h>
#include <avr\sleep.h>
#include <avr\eeprom.h>
#include "ports_io.h"
#include "adc.h"
#include "motors.h"
#include "leds.h"
#include "spi.h"
#include "mirf.h"
#include "usart.h"
#include "sensors.h"
#include "ir_remote_control.h"
#include "eepromIO.h"
Go to the source code of this file.
Functions | |
unsigned char | getSelector () |
Return the current selector postion. | |
void | initPeripherals () |
Initialize all the port pins and peripherals calling their "init" functions. | |
void | sleep (unsigned char seconds) |
Let the roboot go in extended standby mode. | |
unsigned long int | getTime100MicroSec () |
A global variable "clockTick" is incremented at each adc interrupt; this variable is used as base time (104 us resolution). This function is useful for instance to create non-blocking delays, calling the function at start of delay and then re-calling it to check when the desired delay is passed. | |
void | readBatteryLevel () |
Simply set the flag that indicates when the battery has to be read. | |
void | resetOdometry () |
Utility module.
The module contains various functions that aren't related to any other module, they are instead of general use.
unsigned char getSelector | ( | ) |
Return the current selector postion.
unsigned long int getTime100MicroSec | ( | ) |
A global variable "clockTick" is incremented at each adc interrupt; this variable is used as base time (104 us resolution). This function is useful for instance to create non-blocking delays, calling the function at start of delay and then re-calling it to check when the desired delay is passed.
void initPeripherals | ( | ) |
Initialize all the port pins and peripherals calling their "init" functions.
void readBatteryLevel | ( | ) |
Simply set the flag that indicates when the battery has to be read.
void resetOdometry | ( | ) |
void sleep | ( | unsigned char | seconds | ) |
Let the roboot go in extended standby mode.
seconds | number of seconds to stay in sleep |