Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
pump.h
00001 #ifndef PUMP_H 00002 #define PUMP_H 00003 00004 // Pump PercentPump (0-100%) 00005 // 0% - pump is off 00006 // 100% - pump is on with max speed 00007 #define PUMP_MIN_INTENSITY 2 00008 #define PUMP_MAX_INTENSITY 100 00009 #define PUMP_OFF_INTENSITY 0 00010 00011 /** 00012 * Initialize pump. 00013 * Turns pump off on the start of the board. 00014 */ 00015 void pumpInit(void); 00016 00017 /** 00018 * Set pump PercentPump. 00019 * 00020 * @param PercentPump Pump intensity in percents. 00021 */ 00022 void pumpSet(float PercentPump); 00023 00024 /** 00025 * Check pump. 00026 * 00027 * @return true if pump is on, false - otherwise. 00028 */ 00029 bool pumpOn(void); 00030 00031 /** 00032 * Get pump PercentPump. 00033 * 00034 * @return pump PercentPump in percents. 00035 */ 00036 unsigned char pumpCurrentIntensity(void); 00037 00038 /** 00039 * Calculate current pump speed using RPM feedback. 00040 * 00041 * @return current pump speed. 00042 */ 00043 unsigned int pumpSpeed(void); 00044 00045 /** 00046 * Set pump PercentPump according to desired RPM value. 00047 * 00048 * @param rpm Desired RPM value. 00049 */ 00050 void pumpSetRpm(int rpm); 00051 00052 /** 00053 * Get pump polynom coefficients. 00054 * 00055 * @param[out] aValue Polynom coefficient 00056 * @param[out] bValue Polynom coefficient 00057 * @param[out] cValue Polynom coefficient 00058 */ 00059 void pumpGetParams(float* aValue, float* bValue, float* cValue); 00060 00061 /** 00062 * Set pump polynom coefficients. 00063 * 00064 * @param aValue Polynom coefficient 00065 * @param bValue Polynom coefficient 00066 * @param cValue Polynom coefficient 00067 */ 00068 void pumpSetParams(float aValue, float bValue, float cValue); 00069 00070 #endif
Generated on Fri Sep 23 2022 19:29:17 by
 1.7.2
 1.7.2