Author: jaguarondi
Date: 2008-08-21 18:24:55 +0200 (Thu, 21 Aug 2008)
New Revision: 1565
Modified:
firmware/rf/trunk/interface.c
firmware/rf/trunk/rf_ctrl.c
firmware/rf/trunk/varis.c
firmware/rf/trunk/varis.h
Log:
* Small naming cleanup.
Modified: firmware/rf/trunk/interface.c
===================================================================
--- firmware/rf/trunk/interface.c 2008-08-21 16:05:14 UTC (rev 1564)
+++ firmware/rf/trunk/interface.c 2008-08-21 16:24:55 UTC (rev 1565)
@@ -76,7 +76,7 @@
/* As we send the previous audio frame, we have to reconfigure the audio
* bit in the config byte. */
- if (checksum1 == 0)
+ if (good_frame_received)
{
prev_audio = spi_out[SPI_CONFIG_OFFSET] & CFG_SECBUF_MK;
frame_dropped = 0;
@@ -98,7 +98,7 @@
/* The frame idx indicates in which buffer the audio is, but if we don't
* get a frame, just use the alternate buffer of the previous frame. */
- if (checksum1 == 0)
+ if (good_frame_received)
second_buffer = spi_out[SPI_IDX_OFFSET] & 0x01;
else
second_buffer = !second_buffer;
Modified: firmware/rf/trunk/rf_ctrl.c
===================================================================
--- firmware/rf/trunk/rf_ctrl.c 2008-08-21 16:05:14 UTC (rev 1564)
+++ firmware/rf/trunk/rf_ctrl.c 2008-08-21 16:24:55 UTC (rev 1565)
@@ -80,11 +80,11 @@
rf_buffer_rx_full = p;
//PORTD ^= 0x08; // XXX DEBUG
}
- checksum1 = checksum;
+ good_frame_received = true;
}
else
{
- checksum1 = 10; /* or whatever value */
+ good_frame_received = false; /* or whatever value */
if (connected)
{
if (!--connected)
Modified: firmware/rf/trunk/varis.c
===================================================================
--- firmware/rf/trunk/varis.c 2008-08-21 16:05:14 UTC (rev 1564)
+++ firmware/rf/trunk/varis.c 2008-08-21 16:24:55 UTC (rev 1565)
@@ -106,7 +106,7 @@
volatile uint8_t rf_rx_state;
//State of the RX interrupt
volatile uint8_t checksum;
-volatile uint8_t checksum1;
+volatile bool good_frame_received;
//Checksum => 0x00 => okay
Modified: firmware/rf/trunk/varis.h
===================================================================
--- firmware/rf/trunk/varis.h 2008-08-21 16:05:14 UTC (rev 1564)
+++ firmware/rf/trunk/varis.h 2008-08-21 16:24:55 UTC (rev 1565)
@@ -70,7 +70,7 @@
extern volatile uint8_t rf_rx_counter;
extern volatile uint8_t rf_rx_state;
extern volatile uint8_t checksum;
-extern volatile uint8_t checksum1;
+extern volatile bool good_frame_received;
extern volatile uint8_t trial_cnt;
extern volatile uint16_t ts;
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn