2 Star 1 Fork 1

976717326 / Teacup_Firmware

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
dda_queue.h 1023 Bytes
一键复制 编辑 原始数据 按行查看 历史
Markus Hitter 提交于 2013-12-13 14:34 . Remove attribute((hot)).
#ifndef _DDA_QUEUE
#define _DDA_QUEUE
#include "dda.h"
#include "timer.h"
#define HEATER_WAIT_TIMEOUT 1000 MS
/*
variables
*/
// this is the ringbuffer that holds the current and pending moves.
extern uint8_t mb_head;
extern uint8_t mb_tail;
extern DDA movebuffer[MOVEBUFFER_SIZE];
/*
methods
*/
// queue status methods
uint8_t queue_full(void);
uint8_t queue_empty(void);
DDA *queue_current_movement(void);
// take one step
void queue_step(void);
// add a new target to the queue
// t == NULL means add a wait for target temp to the queue
void enqueue_home(TARGET *t, uint8_t endstop_check, uint8_t endstop_stop_cond);
static void enqueue(TARGET *) __attribute__ ((always_inline));
inline void enqueue(TARGET *t) {
enqueue_home(t, 0, 0);
}
// called from step timer when current move is complete
void next_move(void);
// print queue status
void print_queue(void);
// flush the queue for eg; emergency stop
void queue_flush(void);
// wait for queue to empty
void queue_wait(void);
#endif /* _DDA_QUEUE */
C
1
https://gitee.com/rhh/Teacup_Firmware.git
git@gitee.com:rhh/Teacup_Firmware.git
rhh
Teacup_Firmware
Teacup_Firmware
master

搜索帮助