1 1.2 jruoho /* $NetBSD: zl10353var.h,v 1.2 2011/08/29 11:16:36 jruoho Exp $ */ 2 1.1 jruoho 3 1.1 jruoho /*- 4 1.1 jruoho * Copyright (c) 2011 The NetBSD Foundation, Inc. 5 1.1 jruoho * All rights reserved. 6 1.1 jruoho * 7 1.1 jruoho * This code is derived from software contributed to The NetBSD Foundation 8 1.1 jruoho * by Jukka Ruohonen. 9 1.1 jruoho * 10 1.1 jruoho * Redistribution and use in source and binary forms, with or without 11 1.1 jruoho * modification, are permitted provided that the following conditions 12 1.1 jruoho * are met: 13 1.1 jruoho * 14 1.1 jruoho * 1. Redistributions of source code must retain the above copyright 15 1.1 jruoho * notice, this list of conditions and the following disclaimer. 16 1.1 jruoho * 2. Redistributions in binary form must reproduce the above copyright 17 1.1 jruoho * notice, this list of conditions and the following disclaimer in the 18 1.1 jruoho * documentation and/or other materials provided with the distribution. 19 1.1 jruoho * 20 1.1 jruoho * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 21 1.1 jruoho * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 22 1.1 jruoho * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 23 1.1 jruoho * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 24 1.1 jruoho * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 25 1.1 jruoho * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 26 1.1 jruoho * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 27 1.1 jruoho * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 28 1.1 jruoho * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 1.1 jruoho * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 1.1 jruoho * SUCH DAMAGE. 31 1.1 jruoho */ 32 1.1 jruoho #ifndef _DEV_I2C_ZL10353VAR_H_ 33 1.1 jruoho #define _DEV_I2C_ZL10353VAR_H_ 34 1.1 jruoho 35 1.1 jruoho struct zl10353 { 36 1.1 jruoho device_t zl_parent; 37 1.1 jruoho const char *zl_name; 38 1.1 jruoho i2c_tag_t zl_i2c; 39 1.1 jruoho i2c_addr_t zl_i2c_addr; 40 1.1 jruoho uint32_t zl_clock; 41 1.1 jruoho uint16_t zl_freq; 42 1.1 jruoho uint8_t zl_bw; 43 1.1 jruoho }; 44 1.1 jruoho 45 1.1 jruoho struct zl10353 *zl10353_open(device_t, i2c_tag_t, i2c_addr_t); 46 1.1 jruoho void zl10353_close(struct zl10353 *); 47 1.1 jruoho void zl10353_get_devinfo(struct dvb_frontend_info *); 48 1.1 jruoho int zl10353_set_params(struct zl10353 *, 49 1.1 jruoho const struct dvb_frontend_parameters *); 50 1.1 jruoho int zl10353_set_fsm(struct zl10353 *); 51 1.1 jruoho int zl10353_set_gate(void *, bool); 52 1.1 jruoho fe_status_t zl10353_get_status(struct zl10353 *); 53 1.1 jruoho uint16_t zl10353_get_signal_strength(struct zl10353 *); 54 1.1 jruoho uint16_t zl10353_get_snr(struct zl10353 *); 55 1.1 jruoho 56 1.1 jruoho #endif /* !_DEV_I2C_ZL10353VAR_H */ 57