//------------------------------------------------------------------------------
//  @fn main
//!
//! Core of "main_can_sensor_node_example.c".
//!
//! This program performs a response to an remote frame of a master.
//! The response is a data frame that contents (in the order) the local
//! temperature, the local luminosity and the local VCC values.
//!
//! @warning - Use DVK90CAN1 board,
//!          - Define CAN_BAUDRATE in "config.h".
//!
//! @param  none
//!
//! @return  Integer 0
//!
//------------------------------------------------------------------------------
int main (void)
{   
    CLKPR = 0x80;  CLKPR = 0x00;  //-- Clock prescaler Reset       
    MCUSR = 0;      //-- Clear all reset flags - needed by IAP
    audio_init();
    led_init(); write_led(MY_ID_TAG);   //-- Display MY_ID_TAG on LEDs
    can_init(0);
    send_sensor_values();
    while(1);
    return 0;
}
Пример #2
0
// Sends the calibated sensor values.
void send_calibrated_sensor_values()
{
	send_sensor_values(1);
}
Пример #3
0
// Sends the raw (uncalibrated) sensor values.
void send_raw_sensor_values()
{
	send_sensor_values(0);
}