X-Git-Url: http://git.linex4red.de/pub/USBasp.git/blobdiff_plain/8f6b4ddf764c3a54e42d00a7502c82c5c3e71b1c..6a8e27f7ee43169b9f6eb928b12e00d6306618ff:/Demos/Host/StillImageHost/StillImageHost.c diff --git a/Demos/Host/StillImageHost/StillImageHost.c b/Demos/Host/StillImageHost/StillImageHost.c index d9dd7ce3f..ca5292ba2 100644 --- a/Demos/Host/StillImageHost/StillImageHost.c +++ b/Demos/Host/StillImageHost/StillImageHost.c @@ -39,8 +39,8 @@ /* Scheduler Task List */ TASK_LIST { - { Task: USB_USBTask , TaskStatus: TASK_STOP }, - { Task: USB_SImage_Host , TaskStatus: TASK_STOP }, + { .Task = USB_USBTask , .TaskStatus = TASK_STOP }, + { .Task = USB_SImage_Host , .TaskStatus = TASK_STOP }, }; @@ -151,13 +151,13 @@ TASK(USB_SImage_Host) { case HOST_STATE_Addressed: /* Standard request to set the device configuration to configuration 1 */ - USB_HostRequest = (USB_Host_Request_Header_t) + USB_ControlRequest = (USB_Request_Header_t) { - bmRequestType: (REQDIR_HOSTTODEVICE | REQTYPE_STANDARD | REQREC_DEVICE), - bRequest: REQ_SetConfiguration, - wValue: 1, - wIndex: 0, - wLength: 0, + .bmRequestType = (REQDIR_HOSTTODEVICE | REQTYPE_STANDARD | REQREC_DEVICE), + .bRequest = REQ_SetConfiguration, + .wValue = 1, + .wIndex = 0, + .wLength = 0, }; /* Select the control pipe for the request transfer */ @@ -211,11 +211,11 @@ TASK(USB_SImage_Host) PIMA_SendBlock = (PIMA_Container_t) { - DataLength: PIMA_COMMAND_SIZE(0), - Type: CType_CommandBlock, - Code: PIMA_OPERATION_GETDEVICEINFO, - TransactionID: 0x00000000, - Params: {}, + .DataLength = PIMA_COMMAND_SIZE(0), + .Type = CType_CommandBlock, + .Code = PIMA_OPERATION_GETDEVICEINFO, + .TransactionID = 0x00000000, + .Params = {}, }; /* Send the GETDEVICEINFO block */ @@ -290,11 +290,11 @@ TASK(USB_SImage_Host) PIMA_SendBlock = (PIMA_Container_t) { - DataLength: PIMA_COMMAND_SIZE(1), - Type: CType_CommandBlock, - Code: PIMA_OPERATION_OPENSESSION, - TransactionID: 0x00000000, - Params: {0x00000001}, + .DataLength = PIMA_COMMAND_SIZE(1), + .Type = CType_CommandBlock, + .Code = PIMA_OPERATION_OPENSESSION, + .TransactionID = 0x00000000, + .Params = {0x00000001}, }; /* Send the OPENSESSION block, open a session with an ID of 0x0001 */ @@ -318,11 +318,11 @@ TASK(USB_SImage_Host) PIMA_SendBlock = (PIMA_Container_t) { - DataLength: PIMA_COMMAND_SIZE(1), - Type: CType_CommandBlock, - Code: PIMA_OPERATION_CLOSESESSION, - TransactionID: 0x00000001, - Params: {0x00000001}, + .DataLength = PIMA_COMMAND_SIZE(1), + .Type = CType_CommandBlock, + .Code = PIMA_OPERATION_CLOSESESSION, + .TransactionID = 0x00000001, + .Params = {0x00000001}, }; /* Send the CLOSESESSION block, close the session with an ID of 0x0001 */ @@ -417,7 +417,7 @@ void UpdateStatus(uint8_t CurrentStatus) /** Displays a PIMA command error via the device's serial port. * * \param ErrorCode Error code of the function which failed to complete successfully - * \param ResponseErrorCode Indicates if the error is due to a command failed indication from the device, or a communication failure + * \param ResponseCodeError Indicates if the error is due to a command failed indication from the device, or a communication failure */ void ShowCommandError(uint8_t ErrorCode, bool ResponseCodeError) {