X-Git-Url: http://git.linex4red.de/pub/USBasp.git/blobdiff_plain/db420853ce1a7c4545c443b9b7e9925fac3fbbb5..a9e0935a90346beb0c981924becc1f55d969a08b:/Projects/Webserver/Webserver.h diff --git a/Projects/Webserver/Webserver.h b/Projects/Webserver/Webserver.h index f3aa8d7b8..4fb5b37b4 100644 --- a/Projects/Webserver/Webserver.h +++ b/Projects/Webserver/Webserver.h @@ -41,53 +41,40 @@ #include #include #include + #include #include - #include #include + #include + #include #include - #include - #include - #include - #include - - #include "Lib/WebserverApp.h" + #include "USBDeviceMode.h" + #include "USBHostMode.h" /* Macros: */ - /** IP address that the webserver should use once connected to a RNDIS device. */ - #define DEVICE_IP_ADDRESS 192, 168, 1, 10 - - /** Netmask that the webserver should once connected to a RNDIS device. */ - #define DEVICE_NETMASK 255, 255, 255, 0 - - /** IP address of the default gateway the webserver should use when routing outside the local subnet. */ - #define DEVICE_GATEWAY 192, 168, 1, 1 - /** LED mask for the library LED driver, to indicate that the USB interface is not ready. */ - #define LEDMASK_USB_NOTREADY LEDS_LED1 + #define LEDMASK_USB_NOTREADY LEDS_LED1 /** LED mask for the library LED driver, to indicate that the USB interface is enumerating. */ - #define LEDMASK_USB_ENUMERATING (LEDS_LED2 | LEDS_LED3) + #define LEDMASK_USB_ENUMERATING (LEDS_LED1 | LEDS_LED2) /** LED mask for the library LED driver, to indicate that the USB interface is ready. */ - #define LEDMASK_USB_READY (LEDS_LED2 | LEDS_LED4) + #define LEDMASK_USB_READY LEDS_LED2 /** LED mask for the library LED driver, to indicate that an error has occurred in the USB interface. */ - #define LEDMASK_USB_ERROR (LEDS_LED1 | LEDS_LED3) + #define LEDMASK_USB_ERROR (LEDS_LED1 | LEDS_LED3) /** LED mask for the library LED driver, to indicate that the USB interface is busy. */ - #define LEDMASK_USB_BUSY LEDS_LED2 - + #define LEDMASK_USB_BUSY (LEDS_LED1 | LEDS_LED3 | LEDS_LED4) + + /** LED mask for the uIP stack idling with no IP configuration */ + #define LEDMASK_UIP_READY_NOCONFIG LEDS_LED3 + + /** LED mask for the uIP stack idling with a valid IP configuration */ + #define LEDMASK_UIP_READY_CONFIG LEDS_LED4 + /* Function Prototypes: */ void SetupHardware(void); - void ProcessIncommingPacket(void); - void ManageConnections(void); - - void EVENT_USB_Host_HostError(const uint8_t ErrorCode); - void EVENT_USB_Host_DeviceAttached(void); - void EVENT_USB_Host_DeviceUnattached(void); - void EVENT_USB_Host_DeviceEnumerationFailed(const uint8_t ErrorCode, const uint8_t SubErrorCode); - void EVENT_USB_Host_DeviceEnumerationComplete(void); #endif