* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
#include <config.h>
(void)cg;
- if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR_DEV_CLOSED;
-
devc = sdi->priv;
return sr_sw_limits_config_set(&devc->limits, key, data);
struct dev_context *devc;
struct sr_serial_dev_inst *serial;
- if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR_DEV_CLOSED;
-
devc = sdi->priv;
serial = sdi->conn;
return SR_OK;
}
-static int dev_acquisition_stop(struct sr_dev_inst *sdi)
-{
- return std_serial_dev_acquisition_stop(sdi, std_serial_dev_close,
- sdi->conn);
-}
-
#define SCALE(ID, CHIPSET, VENDOR, MODEL, CONN, BAUDRATE, PACKETSIZE, \
VALID, PARSE) \
&((struct scale_info) { \
.cleanup = std_cleanup, \
.scan = scan, \
.dev_list = std_dev_list, \
+ .dev_clear = std_dev_clear, \
.config_get = NULL, \
.config_set = config_set, \
.config_list = config_list, \
.dev_open = std_serial_dev_open, \
.dev_close = std_serial_dev_close, \
.dev_acquisition_start = dev_acquisition_start, \
- .dev_acquisition_stop = dev_acquisition_stop, \
+ .dev_acquisition_stop = std_serial_dev_acquisition_stop, \
.context = NULL, \
}, \
VENDOR, MODEL, CONN, BAUDRATE, PACKETSIZE, \