diff options
author | Dean Camera <dean@fourwalledcubicle.com> | 2010-02-18 02:19:43 +0000 |
---|---|---|
committer | Dean Camera <dean@fourwalledcubicle.com> | 2010-02-18 02:19:43 +0000 |
commit | 3b6987bca3ef746fd9a5d4baec6d40b65c9b4101 (patch) | |
tree | cd2c69da65d47a0bba638c07431cfc893422be87 /Projects/TemperatureDataLogger | |
parent | c77b30e9e6069c893b8461e104e7893762ed81a7 (diff) | |
download | lufa-3b6987bca3ef746fd9a5d4baec6d40b65c9b4101.tar.gz lufa-3b6987bca3ef746fd9a5d4baec6d40b65c9b4101.tar.bz2 lufa-3b6987bca3ef746fd9a5d4baec6d40b65c9b4101.zip |
Add uIP-split code to the Webserver project, so that each packet is split in half to avoid the delayed-ACK problem when communicating with other devices. Condense HTTP server code, so that the HTTP headers are all sent from the one state. Make default filename append to any directory URI, rather than just the root directory.
Diffstat (limited to 'Projects/TemperatureDataLogger')
-rw-r--r-- | Projects/TemperatureDataLogger/TempDataLogger.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Projects/TemperatureDataLogger/TempDataLogger.c b/Projects/TemperatureDataLogger/TempDataLogger.c index 7d26ee25d..955359d45 100644 --- a/Projects/TemperatureDataLogger/TempDataLogger.c +++ b/Projects/TemperatureDataLogger/TempDataLogger.c @@ -110,6 +110,7 @@ ISR(TIMER1_COMPA_vect, ISR_BLOCK) /* Reset log tick counter to prepare for next logging interval */
CurrentLoggingTicks = 0;
+ /* Only log when not connected to a USB host */
if (USB_DeviceState == DEVICE_STATE_Unattached)
{
uint8_t Day, Month, Year;
@@ -139,15 +140,15 @@ int main(void) /* Fetch logging interval from EEPROM */
LoggingInterval500MS_SRAM = eeprom_read_byte(&LoggingInterval500MS_EEPROM);
- LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY);
-
SetupHardware();
+ LEDs_SetAllLEDs(LEDMASK_USB_NOTREADY);
+
/* Mount and open the log file on the dataflash FAT partition */
OpenLogFile();
/* Discard the first sample from the temperature sensor, as it is generally incorrect */
- uint8_t Dummy = Temperature_GetTemperature();
+ volatile uint8_t Dummy = Temperature_GetTemperature();
(void)Dummy;
for (;;)
|