CHG: revert old fiddeling, I should not touch the HIDflasher.

This commit is contained in:
iceman1001 2016-02-19 22:32:38 +01:00
commit e66ff99cc9
2 changed files with 5 additions and 15 deletions

View file

@ -13,7 +13,7 @@
#include <stdint.h> #include <stdint.h>
#include <stdbool.h> #include <stdbool.h>
#include <usb.h> //#include <usb.h>
#include "usb_cmd.h" #include "usb_cmd.h"
extern unsigned char return_on_error; extern unsigned char return_on_error;

View file

@ -23,24 +23,14 @@ typedef BYTE uint8_t;
#define PACKED __attribute__((packed)) #define PACKED __attribute__((packed))
#endif #endif
#define USB_CMD_DATA_SIZE 512
typedef struct { typedef struct {
uint64_t cmd; uint32_t cmd;
uint64_t arg[3]; uint32_t arg[3];
union { union {
uint8_t asBytes[USB_CMD_DATA_SIZE]; uint8_t asBytes[48];
uint32_t asDwords[USB_CMD_DATA_SIZE/4]; uint32_t asDwords[12];
} d; } d;
} PACKED UsbCommand; } PACKED UsbCommand;
// A struct used to send sample-configs over USB
typedef struct{
uint8_t decimation;
uint8_t bits_per_sample;
bool averaging;
int divisor;
int trigger_threshold;
} sample_config;
// For the bootloader // For the bootloader
#define CMD_DEVICE_INFO 0x0000 #define CMD_DEVICE_INFO 0x0000