Initial commit: TXW82x FPV v2.7.0.7-42229 SDK + project sources

This commit is contained in:
2026-07-06 11:30:13 +08:00
commit e76462eeb7
3451 changed files with 1415300 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
#ifndef _RING_BUFFER_H_
#define _RING_BUFFER_H_
typedef struct RINGBUF {
uint8_t *data;
uint32_t front;
uint32_t rear;
uint32_t elementsize;
uint32_t elementcount;
} RINGBUF;
RINGBUF *ringbuf_Init(uint8_t elementsize, uint32_t elementcount);
int32_t ringbuf_read_available(RINGBUF *ringbuf);
int32_t ringbuf_write_available(RINGBUF *ringbuf);
int32_t ringbuf_read(RINGBUF *ringbuf, void *data, uint32_t elementcount);
int32_t ringbuf_write(RINGBUF *ringbuf, void *data, uint32_t elementcount);
int32_t ringbuf_move_readptr(RINGBUF *ringbuf, int32_t elementcount);
int32_t ringbuf_read_nomove(RINGBUF *ringbuf, void *data, uint32_t elementcount);
void ringbuf_clean(RINGBUF *ringbuf);
void ringbuf_del(RINGBUF *ringbuf);
#endif