/** * @file hx710a.h * * @param Project DEVICE_GENERAL_ATY_LIB * * @author ATY * * @copyright * - Copyright 2017 - 2026 MZ-ATY * - This code follows: * - MZ-ATY Various Contents Joint Statement - * * https://mengze.top/MZ-ATY_VCJS * - CC 4.0 BY-NC-SA - * * https://creativecommons.org/licenses/by-nc-sa/4.0/ * - Your use will be deemed to have accepted the terms of this statement. * * @brief functions of HX710A for C platform * * @version * - 1_01_251112 > ATY * -# Add Dev-style interface aligned to LED_ATY ******************************************************************************** */ #ifndef __HX710A_H #define __HX710A_H #include "INCLUDE_ATY.h" /******************************* For user *************************************/ /******************************************************************************/ struct HX710A_ATY_Dev { void (*sckSet)(uint8_t level); uint8_t (*doutRead)(void); void (*delay_ms)(uint16_t ms); // optional uint8_t lock; uint8_t debugEnable; void (*LOG)(const char*, ...); }; uint8_t HX710A_InitDev(struct HX710A_ATY_Dev* dev); uint8_t HX710A_IsReadyDev(struct HX710A_ATY_Dev* dev); uint8_t HX710A_ReadRawDev(uint8_t p, uint32_t* raw, struct HX710A_ATY_Dev* dev); #endif /* __HX710A_H */ /******************************** End Of File *********************************/