18c2ecf20Sopenharmony_ci 28c2ecf20Sopenharmony_ciAnalog Devices ADIS16480 and similar IMUs 38c2ecf20Sopenharmony_ci 48c2ecf20Sopenharmony_ciRequired properties for the ADIS16480: 58c2ecf20Sopenharmony_ci 68c2ecf20Sopenharmony_ci- compatible: Must be one of 78c2ecf20Sopenharmony_ci * "adi,adis16375" 88c2ecf20Sopenharmony_ci * "adi,adis16480" 98c2ecf20Sopenharmony_ci * "adi,adis16485" 108c2ecf20Sopenharmony_ci * "adi,adis16488" 118c2ecf20Sopenharmony_ci * "adi,adis16490" 128c2ecf20Sopenharmony_ci * "adi,adis16495-1" 138c2ecf20Sopenharmony_ci * "adi,adis16495-2" 148c2ecf20Sopenharmony_ci * "adi,adis16495-3" 158c2ecf20Sopenharmony_ci * "adi,adis16497-1" 168c2ecf20Sopenharmony_ci * "adi,adis16497-2" 178c2ecf20Sopenharmony_ci * "adi,adis16497-3" 188c2ecf20Sopenharmony_ci- reg: SPI chip select number for the device 198c2ecf20Sopenharmony_ci- spi-max-frequency: Max SPI frequency to use 208c2ecf20Sopenharmony_ci see: Documentation/devicetree/bindings/spi/spi-bus.txt 218c2ecf20Sopenharmony_ci- spi-cpha: See Documentation/devicetree/bindings/spi/spi-bus.txt 228c2ecf20Sopenharmony_ci- spi-cpol: See Documentation/devicetree/bindings/spi/spi-bus.txt 238c2ecf20Sopenharmony_ci- interrupts: interrupt mapping for IRQ, accepted values are: 248c2ecf20Sopenharmony_ci * IRQF_TRIGGER_RISING 258c2ecf20Sopenharmony_ci * IRQF_TRIGGER_FALLING 268c2ecf20Sopenharmony_ci 278c2ecf20Sopenharmony_ciOptional properties: 288c2ecf20Sopenharmony_ci 298c2ecf20Sopenharmony_ci- interrupt-names: Data ready line selection. Valid values are: 308c2ecf20Sopenharmony_ci * DIO1 318c2ecf20Sopenharmony_ci * DIO2 328c2ecf20Sopenharmony_ci * DIO3 338c2ecf20Sopenharmony_ci * DIO4 348c2ecf20Sopenharmony_ci If this field is left empty, DIO1 is assigned as default data ready 358c2ecf20Sopenharmony_ci signal. 368c2ecf20Sopenharmony_ci- reset-gpios: must be the device tree identifier of the RESET pin. As the line 378c2ecf20Sopenharmony_ci is active low, it should be marked GPIO_ACTIVE_LOW. 388c2ecf20Sopenharmony_ci- clocks: phandle to the external clock. Should be set according to 398c2ecf20Sopenharmony_ci "clock-names". 408c2ecf20Sopenharmony_ci If this field is left empty together with the "clock-names" field, then 418c2ecf20Sopenharmony_ci the internal clock is used. 428c2ecf20Sopenharmony_ci- clock-names: The name of the external clock to be used. Valid values are: 438c2ecf20Sopenharmony_ci * sync: In sync mode, the internal clock is disabled and the frequency 448c2ecf20Sopenharmony_ci of the external clock signal establishes therate of data 458c2ecf20Sopenharmony_ci collection and processing. See Fig 14 and 15 in the datasheet. 468c2ecf20Sopenharmony_ci The clock-frequency must be: 478c2ecf20Sopenharmony_ci * 3000 to 4500 Hz for adis1649x devices. 488c2ecf20Sopenharmony_ci * 700 to 2400 Hz for adis1648x devices. 498c2ecf20Sopenharmony_ci * pps: In Pulse Per Second (PPS) Mode, the rate of data collection and 508c2ecf20Sopenharmony_ci production is equal to the product of the external clock 518c2ecf20Sopenharmony_ci frequency and the scale factor in the SYNC_SCALE register, see 528c2ecf20Sopenharmony_ci Table 154 in the datasheet. 538c2ecf20Sopenharmony_ci The clock-frequency must be: 548c2ecf20Sopenharmony_ci * 1 to 128 Hz for adis1649x devices. 558c2ecf20Sopenharmony_ci * This mode is not supported by adis1648x devices. 568c2ecf20Sopenharmony_ci If this field is left empty together with the "clocks" field, then the 578c2ecf20Sopenharmony_ci internal clock is used. 588c2ecf20Sopenharmony_ci- adi,ext-clk-pin: The DIOx line to be used as an external clock input. 598c2ecf20Sopenharmony_ci Valid values are: 608c2ecf20Sopenharmony_ci * DIO1 618c2ecf20Sopenharmony_ci * DIO2 628c2ecf20Sopenharmony_ci * DIO3 638c2ecf20Sopenharmony_ci * DIO4 648c2ecf20Sopenharmony_ci Each DIOx pin supports only one function at a time (data ready line 658c2ecf20Sopenharmony_ci selection or external clock input). When a single pin has two 668c2ecf20Sopenharmony_ci two assignments, the enable bit for the lower priority function 678c2ecf20Sopenharmony_ci automatically resets to zero (disabling the lower priority function). 688c2ecf20Sopenharmony_ci Data ready has highest priority. 698c2ecf20Sopenharmony_ci If this field is left empty, DIO2 is assigned as default external clock 708c2ecf20Sopenharmony_ci input pin. 718c2ecf20Sopenharmony_ci 728c2ecf20Sopenharmony_ciExample: 738c2ecf20Sopenharmony_ci 748c2ecf20Sopenharmony_ci imu@0 { 758c2ecf20Sopenharmony_ci compatible = "adi,adis16495-1"; 768c2ecf20Sopenharmony_ci reg = <0>; 778c2ecf20Sopenharmony_ci spi-max-frequency = <3200000>; 788c2ecf20Sopenharmony_ci spi-cpol; 798c2ecf20Sopenharmony_ci spi-cpha; 808c2ecf20Sopenharmony_ci interrupts = <25 IRQF_TRIGGER_FALLING>; 818c2ecf20Sopenharmony_ci interrupt-parent = <&gpio>; 828c2ecf20Sopenharmony_ci interrupt-names = "DIO2"; 838c2ecf20Sopenharmony_ci clocks = <&adis16495_sync>; 848c2ecf20Sopenharmony_ci clock-names = "sync"; 858c2ecf20Sopenharmony_ci adi,ext-clk-pin = "DIO1"; 868c2ecf20Sopenharmony_ci }; 87