board: Factor out Chunithm slider

This commit is contained in:
Tau
2019-01-17 14:07:59 -05:00
parent 6416ef6e95
commit 8036ff71ec
6 changed files with 10 additions and 9 deletions

25
board/slider-frame.h Normal file
View File

@ -0,0 +1,25 @@
#pragma once
#include <windows.h>
#include <stddef.h>
#include <stdint.h>
#include "hook/iobuf.h"
enum {
SLIDER_FRAME_SYNC = 0xFF,
};
struct slider_hdr {
uint8_t sync;
uint8_t cmd;
uint8_t nbytes;
};
HRESULT slider_frame_decode(struct iobuf *dest, struct iobuf *src);
HRESULT slider_frame_encode(
struct iobuf *dest,
const void *ptr,
size_t nbytes);