hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 10:00 am

Hello, we are waveshare, how can I add two SC16IS752,
I added the following in config.txt:
dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c
and i reboot raspberryPi
I am running
ls /dev/tty
https://user-images.githubusercontent.c ... 657060.png
But ttySC2 and ttySC3 did not appear
anybody help me?

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 10:09 am

There are a few things that could be going wrong, but let's start with the hardware.

1) Does "i2c-detect -y 1" show both devices?

2) Comment out the second dtoverlay, reboot and test it - does an interface appear?

3) Uncomment the second overlay, comment out the first dtoverlay, reboot and test it - does an interface appear?

User avatar
DougieLawson
Posts: 36179
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 10:13 am

What's your wiring for pin A0 and pin A1 on each of your SC16IS752 chips. That's what defines the I2C address

A0=Vdd A1=Vdd gives a write address of 0x90 and a read address of 0x48.
A0=Vss A1=Vdd gives a write address of 0x98 and a read address of 0x4C.

Datasheet is here: https://www.nxp.com/docs/en/data-sheet/ ... 6IS762.pdf
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:17 am

This is our product.
https://www.waveshare.com/serial-expansion-hat.htm
If only one is plugged in, it can be used. Now it is found that once two overlays are used, and two boards are connected through the DuPont line to ensure that the INT pins are inconsistent, finally only the module will work, view the I2C address and /dev/tty* found that ttySC2 and ttySC3 were not generated

Code: Select all

[email protected]:~ $ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- 48 -- -- -- UU -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --                         
[email protected]:~ $ 
config.txt

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c
/dev/tty*

Code: Select all

[email protected]:~ $ ls /dev/tty*
/dev/tty    /dev/tty13  /dev/tty19  /dev/tty24  /dev/tty3   /dev/tty35  /dev/tty40  /dev/tty46  /dev/tty51  /dev/tty57  /dev/tty62    /dev/ttyprintk
/dev/tty0   /dev/tty14  /dev/tty2   /dev/tty25  /dev/tty30  /dev/tty36  /dev/tty41  /dev/tty47  /dev/tty52  /dev/tty58  /dev/tty63    /dev/ttyS0
/dev/tty1   /dev/tty15  /dev/tty20  /dev/tty26  /dev/tty31  /dev/tty37  /dev/tty42  /dev/tty48  /dev/tty53  /dev/tty59  /dev/tty7     /dev/ttySC0
/dev/tty10  /dev/tty16  /dev/tty21  /dev/tty27  /dev/tty32  /dev/tty38  /dev/tty43  /dev/tty49  /dev/tty54  /dev/tty6   /dev/tty8     /dev/ttySC1
/dev/tty11  /dev/tty17  /dev/tty22  /dev/tty28  /dev/tty33  /dev/tty39  /dev/tty44  /dev/tty5   /dev/tty55  /dev/tty60  /dev/tty9
/dev/tty12  /dev/tty18  /dev/tty23  /dev/tty29  /dev/tty34  /dev/tty4   /dev/tty45  /dev/tty50  /dev/tty56  /dev/tty61  /dev/ttyAMA0
Last edited by hnwangkg163 on Tue Mar 12, 2019 11:28 am, edited 1 time in total.

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:27 am

Now try steps 2) and 3).

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:33 am

Step 2:
config.txt:

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
#dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c

Code: Select all

[email protected]:~ $ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- UU -- -- -- 4c -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- 
 
ls /dev/ttySC*

Code: Select all

[email protected]:~ $ ls /dev/ttySC*
/dev/ttySC0  /dev/ttySC1
Step 3:
config.txt:

Code: Select all

#dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c

Code: Select all

[email protected]:~ $ i2cdetect -y 1
[email protected]:~ $ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- 48 -- -- -- UU -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- 
 
ls /dev/ttySC*

Code: Select all

[email protected]:~ $ ls /dev/ttySC*
/dev/ttySC0  /dev/ttySC1

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:34 am

What I want is that both are connected, and then I can generate 4 devices, ttySC0 ttySC1, ttySC2 ttySC3.

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:36 am

The hardware does appear to be detectable - with both dtoverlay lines enabled, what does "dmesg" report after booting?

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:39 am

The strange thing is that both of us use

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c
I2C found that only one device is working

Code: Select all

[email protected]:~ $ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- 48 -- -- -- UU -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- -- 
It seems that only the device with the address 0x4c at the back works.

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 11:40 am

Code: Select all

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.14.50-v7+ ([email protected]) (gcc version 4.9.3 (crosstool-NG crosstool-ng-1.22.0-88-g8460611)) #1122 SMP Tue Jun 19 18
[    0.000000] CPU: ARMv7 Processor [410fd034] revision 4 (ARMv7), cr=10c5383d
[    0.000000] CPU: div instructions available: patching division code
[    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
[    0.000000] OF: fdt: Machine model: Raspberry Pi 3 Model B Rev 1.2
[    0.000000] Memory policy: Data cache writealloc
[    0.000000] cma: Reserved 8 MiB at 0x37800000
[    0.000000] On node 0 totalpages: 229376
[    0.000000] free_area_init_node: node 0, pgdat 80c85000, node_mem_map b7016000
[    0.000000]   Normal zone: 2016 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 229376 pages, LIFO batch:31
[    0.000000] percpu: Embedded 17 pages/cpu @b6fbf000 s38720 r8192 d22720 u69632
[    0.000000] pcpu-alloc: s38720 r8192 d22720 u69632 alloc=17*4096
[    0.000000] pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3 
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 227360
[    0.000000] Kernel command line: 8250.nr_uarts=1 bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416 bcm2708_fb.fbswap=1 vc_mem.mem_base=0x3ec00000 vc_met
[    0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
[    0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Memory: 887456K/917504K available (7168K kernel code, 575K rwdata, 2072K rodata, 1024K init, 706K bss, 21856K reserved, 8192K cma-reserv)
[    0.000000] Virtual kernel memory layout:
                   vector  : 0xffff0000 - 0xffff1000   (   4 kB)
                   fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
                   vmalloc : 0xb8800000 - 0xff800000   (1136 MB)
                   lowmem  : 0x80000000 - 0xb8000000   ( 896 MB)
                   modules : 0x7f000000 - 0x80000000   (  16 MB)
                     .text : 0x80008000 - 0x80800000   (8160 kB)
                     .init : 0x80b00000 - 0x80c00000   (1024 kB)
                     .data : 0x80c00000 - 0x80c8fef4   ( 576 kB)
                      .bss : 0x80c96f40 - 0x80d478b4   ( 707 kB)
[    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] ftrace: allocating 25253 entries in 75 pages
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000] arch_timer: cp15 timer(s) running at 19.20MHz (phys).
[    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff max_cycles: 0x46d987e47, max_idle_ns: 440795202767 ns
[    0.000007] sched_clock: 56 bits at 19MHz, resolution 52ns, wraps every 4398046511078ns
[    0.000023] Switching to timer-based delay loop, resolution 52ns
[    0.000271] Console: colour dummy device 80x30
[    0.000805] console [tty1] enabled
[    0.000846] Calibrating delay loop (skipped), value calculated using timer frequency.. 38.40 BogoMIPS (lpj=192000)
[    0.000886] pid_max: default: 32768 minimum: 301
[    0.001217] Mount-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.001250] Mountpoint-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.002210] Disabling memory control group subsystem
[    0.002305] CPU: Testing write buffer coherency: ok
[    0.002721] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
[    0.003116] Setting up static identity map for 0x100000 - 0x10003c
[    0.003248] Hierarchical SRCU implementation.
[    0.003897] smp: Bringing up secondary CPUs ...
[    0.004601] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
[    0.005352] CPU2: thread -1, cpu 2, socket 0, mpidr 80000002
[    0.006090] CPU3: thread -1, cpu 3, socket 0, mpidr 80000003
[    0.006193] smp: Brought up 1 node, 4 CPUs
[    0.006265] SMP: Total of 4 processors activated (153.60 BogoMIPS).
[    0.006286] CPU: All CPU(s) started in HYP mode.
[    0.006304] CPU: Virtualization extensions available.
[    0.007163] devtmpfs: initialized
[    0.017146] random: get_random_u32 called from bucket_table_alloc+0xfc/0x24c with crng_init=0
[    0.017816] VFP support v0.3: implementor 41 architecture 3 part 40 variant 3 rev 4
[    0.018067] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.018111] futex hash table entries: 1024 (order: 4, 65536 bytes)
[    0.018691] pinctrl core: initialized pinctrl subsystem
[    0.019440] NET: Registered protocol family 16
[    0.022049] DMA: preallocated 1024 KiB pool for atomic coherent allocations
[    0.026819] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 watchpoint registers.
[    0.026851] hw-breakpoint: maximum watchpoint size is 8 bytes.
[    0.027066] Serial: AMBA PL011 UART driver
[    0.028702] bcm2835-mbox 3f00b880.mailbox: mailbox enabled
[    0.029175] uart-pl011 3f201000.serial: could not find pctldev for node /soc/[email protected]/uart0_pins, deferring probe
[    0.060997] bcm2835-dma 3f007000.dma: DMA legacy API manager at b8813000, dmachans=0x1
[    0.062439] SCSI subsystem initialized
[    0.062680] usbcore: registered new interface driver usbfs
[    0.062750] usbcore: registered new interface driver hub
[    0.062862] usbcore: registered new device driver usb
[    0.070075] raspberrypi-firmware soc:firmware: Attached to firmware from 2018-06-07 15:31
[    0.071377] clocksource: Switched to clocksource arch_sys_counter
[    0.148324] VFS: Disk quotas dquot_6.6.0
[    0.148436] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    0.148640] FS-Cache: Loaded
[    0.148852] CacheFiles: Loaded
[    0.157633] NET: Registered protocol family 2
[    0.158370] TCP established hash table entries: 8192 (order: 3, 32768 bytes)
[    0.158501] TCP bind hash table entries: 8192 (order: 4, 65536 bytes)
[    0.158703] TCP: Hash tables configured (established 8192 bind 8192)
[    0.158849] UDP hash table entries: 512 (order: 2, 16384 bytes)
[    0.158910] UDP-Lite hash table entries: 512 (order: 2, 16384 bytes)
[    0.159154] NET: Registered protocol family 1
[    0.159597] RPC: Registered named UNIX socket transport module.
[    0.159621] RPC: Registered udp transport module.
[    0.159640] RPC: Registered tcp transport module.
[    0.159659] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.161148] hw perfevents: enabled with armv7_cortex_a7 PMU driver, 7 counters available
[    0.163976] workingset: timestamp_bits=14 max_order=18 bucket_order=4
[    0.171935] FS-Cache: Netfs 'nfs' registered for caching
[    0.172543] NFS: Registering the id_resolver key type
[    0.172596] Key type id_resolver registered
[    0.172616] Key type id_legacy registered
[    0.172644] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    0.174532] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 251)
[    0.174684] io scheduler noop registered
[    0.174706] io scheduler deadline registered (default)
[    0.174994] io scheduler cfq registered
[    0.175016] io scheduler mq-deadline registered
[    0.175036] io scheduler kyber registered
[    0.177757] BCM2708FB: allocated DMA memory f7910000
[    0.177801] BCM2708FB: allocated DMA channel 0 @ b8813000
[    0.186334] Console: switching to colour frame buffer device 82x26
[    0.193751] Serial: 8250/16550 driver, 1 ports, IRQ sharing enabled
[    0.197434] bcm2835-rng 3f104000.rng: hwrng registered
[    0.199920] vc-mem: phys_addr:0x00000000 mem_base=0x3ec00000 mem_size:0x40000000(1024 MiB)
[    0.205042] vc-sm: Videocore shared memory driver
[    0.207616] gpiomem-bcm2835 3f200000.gpiomem: Initialised: Registers at 0x3f200000
[    0.221842] brd: module loaded
[    0.232782] loop: module loaded
[    0.235149] Loading iSCSI transport class v2.0-870.
[    0.238101] libphy: Fixed MDIO Bus: probed
[    0.240456] usbcore: registered new interface driver lan78xx
[    0.242795] usbcore: registered new interface driver smsc95xx
[    0.245002] dwc_otg: version 3.00a 10-AUG-2012 (platform bus)
[    0.475306] Core Release: 2.80a
[    0.477534] Setting default values for core params
[    0.479846] Finished setting default values for core params
[    0.682491] Using Buffer DMA mode
[    0.684814] Periodic Transfer Interrupt Enhancement - disabled
[    0.687257] Multiprocessor Interrupt Enhancement - disabled
[    0.689683] OTG VER PARAM: 0, OTG VER FLAG: 0
[    0.692079] Dedicated Tx FIFOs mode
[    0.694770] WARN::dwc_otg_hcd_init:1046: FIQ DMA bounce buffers: virt = 0xb7904000 dma = 0xf7904000 len=9024
[    0.699467] FIQ FSM acceleration enabled for :
               Non-periodic Split Transactions
               Periodic Split Transactions
               High-Speed Isochronous Endpoints
               Interrupt/Control Split Transaction hack enabled
[    0.710507] dwc_otg: Microframe scheduler enabled
[    0.710562] WARN::hcd_init_fiq:459: FIQ on core 1 at 0x805e7d20
[    0.712846] WARN::hcd_init_fiq:460: FIQ ASM at 0x805e8088 length 36
[    0.715110] WARN::hcd_init_fiq:486: MPHI regs_base at 0xb887e000
[    0.717381] dwc_otg 3f980000.usb: DWC OTG Controller
[    0.719697] dwc_otg 3f980000.usb: new USB bus registered, assigned bus number 1
[    0.722078] dwc_otg 3f980000.usb: irq 62, io mem 0x00000000
[    0.724403] Init: Port Power? op_state=1
[    0.726660] Init: Power Port (0)
[    0.729043] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    0.731356] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    0.733687] usb usb1: Product: DWC OTG Controller
[    0.735937] usb usb1: Manufacturer: Linux 4.14.50-v7+ dwc_otg_hcd
[    0.738212] usb usb1: SerialNumber: 3f980000.usb
[    0.741061] hub 1-0:1.0: USB hub found
[    0.743289] hub 1-0:1.0: 1 port detected
[    0.745855] dwc_otg: FIQ enabled
[    0.745860] dwc_otg: NAK holdoff enabled
[    0.745865] dwc_otg: FIQ split-transaction FSM enabled
[    0.745874] Module dwc_common_port init
[    0.746090] usbcore: registered new interface driver usb-storage
[    0.748389] mousedev: PS/2 mouse device common for all mice
[    0.750610] IR NEC protocol handler initialized
[    0.752802] IR RC5(x/sz) protocol handler initialized
[    0.755009] IR RC6 protocol handler initialized
[    0.757186] IR JVC protocol handler initialized
[    0.759263] IR Sony protocol handler initialized
[    0.761352] IR SANYO protocol handler initialized
[    0.763460] IR Sharp protocol handler initialized
[    0.765457] IR MCE Keyboard/mouse protocol handler initialized
[    0.767487] IR XMP protocol handler initialized
[    0.770180] bcm2835-wdt 3f100000.watchdog: Broadcom BCM2835 watchdog timer
[    0.772560] bcm2835-cpufreq: min=600000 max=1200000
[    0.775022] sdhci: Secure Digital Host Controller Interface driver
[    0.777149] sdhci: Copyright(c) Pierre Ossman
[    0.779584] mmc-bcm2835 3f300000.mmc: could not get clk, deferring probe
[    0.782078] sdhost-bcm2835 3f202000.mmc: could not get clk, deferring probe
[    0.784377] sdhci-pltfm: SDHCI platform and OF driver helper
[    0.788008] ledtrig-cpu: registered to indicate activity on CPUs
[    0.790432] hidraw: raw HID events driver (C) Jiri Kosina
[    0.792926] usbcore: registered new interface driver usbhid
[    0.795233] usbhid: USB HID core driver
[    0.798076] vchiq: vchiq_init_state: slot_zero = b7980000, is_master = 0
[    0.801827] [vc_sm_connected_init]: start
[    0.810601] [vc_sm_connected_init]: end - returning 0
[    0.813527] Initializing XFRM netlink socket
[    0.815919] NET: Registered protocol family 17
[    0.818376] Key type dns_resolver registered
[    0.821146] Registering SWP/SWPB emulation handler
[    0.824208] registered taskstats version 1
[    0.832598] uart-pl011 3f201000.serial: cts_event_workaround enabled
[    0.835165] 3f201000.serial: ttyAMA0 at MMIO 0x3f201000 (irq = 87, base_baud = 0) is a PL011 rev2
[    0.841644] console [ttyS0] disabled
[    0.844091] 3f215040.serial: ttyS0 at MMIO 0x0 (irq = 166, base_baud = 31250000) is a 16550
[    0.961473] Indeed it is in host mode hprt0 = 00021501
[    1.161407] usb 1-1: new high-speed USB device number 2 using dwc_otg
[    1.164899] Indeed it is in host mode hprt0 = 00001101
[    1.422388] usb 1-1: New USB device found, idVendor=0424, idProduct=9514
[    1.422398] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    1.427904] hub 1-1:1.0: USB hub found
[    1.432961] hub 1-1:1.0: 5 ports detected
[    1.831403] usb 1-1.1: new high-speed USB device number 3 using dwc_otg
[    1.941174] console [ttyS0] enabled
[    1.948120] mmc-bcm2835 3f300000.mmc: mmc_debug:0 mmc_debug2:0
[    1.956525] mmc-bcm2835 3f300000.mmc: DMA channel allocated
[    1.964832] usb 1-1.1: New USB device found, idVendor=0424, idProduct=ec00
[    1.974281] usb 1-1.1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    1.986686] smsc95xx v1.0.6
[    2.022163] sdhost: log_buf @ b7907000 (f7907000)
[    2.051991] random: fast init done
[    2.070816] mmc1: queuing unknown CIS tuple 0x80 (2 bytes)
[    2.080381] mmc1: queuing unknown CIS tuple 0x80 (3 bytes)
[    2.089997] mmc1: queuing unknown CIS tuple 0x80 (3 bytes)
[    2.099447] smsc95xx 1-1.1:1.0 eth0: register 'smsc95xx' at usb-3f980000.usb-1.1, smsc95xx USB 2.0 Ethernet, b8:27:eb:0f:e5:20
[    2.100863] mmc1: queuing unknown CIS tuple 0x80 (7 bytes)
[    2.131398] mmc0: sdhost-bcm2835 loaded - DMA enabled (>1)
[    2.140423] of_cfs_init
[    2.145312] of_cfs_init: OK
[    2.150956] Waiting for root device PARTUUID=e47f2642-02...
[    2.208655] mmc0: host does not support reading read-only switch, assuming write-enable
[    2.224072] mmc0: new high speed SDHC card at address 59b4
[    2.232602] mmcblk0: mmc0:59b4 USD   14.7 GiB
[    2.240937]  mmcblk0: p1 p2
[    2.258886] mmc1: new high speed SDIO card at address 0001
[    2.282709] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    2.295628] VFS: Mounted root (ext4 filesystem) readonly on device 179:2.
[    2.313160] devtmpfs: mounted
[    2.321572] Freeing unused kernel memory: 1024K
[    2.755576] systemd[1]: System time before build time, advancing clock.
[    2.897778] NET: Registered protocol family 10
[    2.906278] Segment Routing with IPv6
[    2.921974] ip_tables: (C) 2000-2006 Netfilter Core Team
[    2.947478] random: systemd: uninitialized urandom read (16 bytes read)
[    2.962198] systemd[1]: systemd 232 running in system mode. (+PAM +AUDIT +SELINUX +IMA +APPARMOR +SMACK +SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT +GNUT)
[    2.989369] systemd[1]: Detected architecture arm.
[    3.032337] systemd[1]: Set hostname to <raspberrypi>.
[    3.073757] random: systemd: uninitialized urandom read (16 bytes read)
[    3.118964] random: systemd-gpt-aut: uninitialized urandom read (16 bytes read)
[    3.489972] systemd[1]: Listening on udev Control Socket.
[    3.531951] systemd[1]: Started Forward Password Requests to Wall Directory Watch.
[    3.581791] systemd[1]: Listening on Syslog Socket.
[    3.621697] systemd[1]: Listening on Journal Socket (/dev/log).
[    3.662192] systemd[1]: Created slice System Slice.
[    3.704487] systemd[1]: Mounting POSIX Message Queue File System...
[    3.742452] systemd[1]: Created slice system-getty.slice.
[    4.255097] i2c /dev entries driver
[    4.812239] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[    5.174848] systemd-journald[89]: Received request to flush runtime journal from PID 1
[    5.583538] snd_bcm2835: module is from the staging directory, the quality is unknown, you have been warned.
[    5.586552] bcm2835_alsa bcm2835_alsa: card created with 8 channels
[    5.761536] brcmfmac: F1 signature read @0x18000000=0x1541a9a6
[    5.768949] brcmfmac: brcmf_fw_map_chip_to_name: using brcm/brcmfmac43430-sdio.bin for chip 0x00a9a6(43430) rev 0x000001
[    5.769207] usbcore: registered new interface driver brcmfmac
[    6.002614] brcmfmac: brcmf_c_preinit_dcmds: Firmware version = wl0: Oct 23 2017 03:55:53 version 7.45.98.38 (r674442 CY) FWID 01-e58d219f
[    6.003754] brcmfmac: brcmf_c_preinit_dcmds: CLM version = API: 12.2 Data: 7.11.15 Compiler: 1.24.2 ClmImport: 1.24.1 Creation: 2014-05-26 10:53:55  
[    6.970219] uart-pl011 3f201000.serial: no DMA platform data
[    7.165042] Adding 102396k swap on /var/swap.  Priority:-2 extents:1 across:102396k SSFS
[    7.297039] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[    7.297149] brcmfmac: power management disabled
[    7.642644] smsc95xx 1-1.1:1.0 eth0: hardware isn't capable of remote wakeup
[    9.173897] smsc95xx 1-1.1:1.0 eth0: link up, 100Mbps, full-duplex, lpa 0x4DE1
[   11.374741] Bluetooth: Core ver 2.22
[   11.374821] NET: Registered protocol family 31
[   11.374828] Bluetooth: HCI device and connection manager initialized
[   11.374850] Bluetooth: HCI socket layer initialized
[   11.374863] Bluetooth: L2CAP socket layer initialized
[   11.374896] Bluetooth: SCO socket layer initialized
[   11.387027] Bluetooth: HCI UART driver ver 2.3
[   11.387045] Bluetooth: HCI UART protocol H4 registered
[   11.387051] Bluetooth: HCI UART protocol Three-wire (H5) registered
[   11.387288] Bluetooth: HCI UART protocol Broadcom registered
[   11.565078] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
[   11.565089] Bluetooth: BNEP filters: protocol multicast
[   11.565108] Bluetooth: BNEP socket layer initialized
[   74.980392] random: crng init done
[   74.980403] random: 7 urandom warning(s) missed due to ratelimiting

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 12, 2019 4:54 pm

That is strange - others have had success with two SC16IS752 over I2C.

Can you run "dtc -I fs /proc/device-tree | pastebinit" and post the link? You may need to "sudo apt-get install pastebinit".

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 1:13 am

Code: Select all

[email protected]:~ $ dtc -I fs /proc/device-tree | pastebinit
<stdout>: Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/vchiq has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/gpiomem has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/axiperf has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /memory has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /axi/vc_mem has a reg or ranges property, but no unit name
<stdout>: Warning (avoid_default_addr_size): Relying on default #address-cells value for /axi/vc_mem
<stdout>: Warning (avoid_default_addr_size): Relying on default #size-cells value for /axi/vc_mem
Failed to contact the server: [Errno socket error] _ssl.c:704: The handshake operation timed out

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 8:36 am

Ha ha. If you don't have an internet connection, use your preferred method to log the output of "dtc -I fs /proc/device-tree" and upload it somewhere I can see it.

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:14 am

Code: Select all

<stdout>: Warning (unit_address_vs_reg): Node /soc has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/vchiq has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/gpiomem has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /soc/axiperf has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /memory has a reg or ranges property, but no unit name
<stdout>: Warning (unit_address_vs_reg): Node /axi/vc_mem has a reg or ranges property, but no unit name
<stdout>: Warning (avoid_default_addr_size): Relying on default #address-cells value for /axi/vc_mem
<stdout>: Warning (avoid_default_addr_size): Relying on default #size-cells value for /axi/vc_mem
/dts-v1/;

/ {
	compatible = "raspberrypi,3-model-b", "brcm,bcm2837";
	serial-number = "00000000010fe520";
	model = "Raspberry Pi 3 Model B Rev 1.2";
	memreserve = <0x38000000 0x8000000>;
	interrupt-parent = <0x1>;
	#address-cells = <0x1>;
	#size-cells = <0x1>;

	clocks {
		compatible = "simple-bus";
		#address-cells = <0x1>;
		#size-cells = <0x0>;

		[email protected] {
			compatible = "fixed-clock";
			#clock-cells = <0x0>;
			phandle = <0x4>;
			reg = <0x3>;
			clock-output-names = "osc";
			clock-frequency = <0x124f800>;
		};

		[email protected] {
			compatible = "fixed-clock";
			#clock-cells = <0x0>;
			phandle = <0x18>;
			reg = <0x4>;
			clock-output-names = "otg";
			clock-frequency = <0x1c9c3800>;
		};
	};

	__overrides__ {
		pwr_led_gpio = "", "", "", "0gpios:4";
		i2c1 = "", "", "", "$status";
		i2c_vc = "", "", "", "#status";
		sd_overclock = "", "", "", "(brcm,overclock-50:0";
		sdio_overclock = "", "", "", ")brcm,overclock-50:0";
		i2c0_baudrate = "", "", "", "#clock-frequency:0";
		sd_pio_limit = "", "", "", "(brcm,pio-limit:0";
		act_led_trigger = "", "", "", "/linux,default-trigger";
		audio = "", "", "", "%status";
		sd_debug = "", "", "", "(brcm,debug";
		cache_line_size = [00 00 00 1e 63 61 63 68 65 2d 6c 69 6e 65 2d 73 69 7a 65 3a 30 00];
		i2c1_baudrate = "", "", "", "$clock-frequency:0";
		spi = "", "", "", "\"status";
		i2c_arm = "", "", "", "$status";
		pwr_led_activelow = "", "", "", "0gpios:8";
		uart0 = [00 00 00 1f 73 74 61 74 75 73 00];
		i2c2_iknowwhatimdoing = [00 00 00 15 73 74 61 74 75 73 00];
		i2s = "", "", "", "!status";
		i2c0 = "", "", "", "#status";
		arm_freq = "", "", "", "+clock-frequency:0", "", "", "", ",clock-frequency:0", "", "", "", "-clock-frequency:0", "", "", "", ".clock-fr;
		watchdog = "", "", "", "&status";
		i2c_baudrate = "", "", "", "$clock-frequency:0";
		i2c_vc_baudrate = "", "", "", "#clock-frequency:0";
		axiperf = "", "", "", "*status";
		act_led_activelow = "", "", "", "/gpios:8";
		i2c2_baudrate = [00 00 00 15 63 6c 6f 63 6b 2d 66 72 65 71 75 65 6e 63 79 3a 30 00];
		sd_force_pio = "", "", "", "(brcm,force-pio?";
		pwr_led_trigger = "", "", "", "0linux,default-trigger";
		uart1 = "", "", "", " status";
		i2c_arm_baudrate = "", "", "", "$clock-frequency:0";
		random = "", "", "", "'status";
		act_led_gpio = "", "", "", "/gpios:4";
		i2c = "", "", "", "$status";
	};

	system {
		linux,serial = <0x0 0x10fe520>;
		linux,revision = <0xa22082>;
	};

	__symbols__ {
		uart0_gpio14 = "/soc/[email protected]/uart0_gpio14";
		pwm = "/soc/[email protected]";
		gpclk1_gpio5 = "/soc/[email protected]/gpclk1_gpio5";
		clk_usb = "/clocks/[email protected]";
		pixelvalve0 = "/soc/[email protected]";
		uart0_ctsrts_gpio30 = "/soc/[email protected]/uart0_ctsrts_gpio30";
		uart1_ctsrts_gpio16 = "/soc/[email protected]/uart1_ctsrts_gpio16";
		uart0_gpio32 = "/soc/[email protected]/uart0_gpio32";
		intc = "/soc/[email protected]";
		spi2 = "/soc/[email protected]";
		jtag_gpio4 = "/soc/[email protected]/jtag_gpio4";
		dsi1 = "/soc/[email protected]";
		clocks = "/soc/[email protected]";
		i2c1 = "/soc/[email protected]";
		i2c_vc = "/soc/[email protected]";
		firmwarekms = "/soc/[email protected]";
		smi = "/soc/[email protected]";
		uart1_ctsrts_gpio42 = "/soc/[email protected]/uart1_ctsrts_gpio42";
		spi0 = "/soc/[email protected]";
		thermal = "/soc/[email protected]";
		vdd_5v0_reg = "/fixedregulator_5v0";
		vchiq = "/soc/vchiq";
		sdhost = "/soc/[email protected]";
		aux = "/soc/[email protected]";
		gpio = "/soc/[email protected]";
		gpclk0_gpio4 = "/soc/[email protected]/gpclk0_gpio4";
		pwm0_gpio12 = "/soc/[email protected]/pwm0_gpio12";
		pwm1_gpio19 = "/soc/[email protected]/pwm1_gpio19";
		pwm0_gpio40 = "/soc/[email protected]/pwm0_gpio40";
		gpclk2_gpio43 = "/soc/[email protected]/gpclk2_gpio43";
		dpi = "/soc/[email protected]";
		vcsm = "/soc/vcsm";
		v3d = "/soc/[email protected]";
		audio = "/soc/audio";
		vdd_3v3_reg = "/fixedregulator_3v3";
		uart1_ctsrts_gpio30 = "/soc/[email protected]/uart1_ctsrts_gpio30";
		dma = "/soc/[email protected]";
		spidev1 = "/soc/[email protected]/[email protected]";
		spi0_gpio35 = "/soc/[email protected]/spi0_gpio35";
		vc4 = "/soc/gpu";
		pwm1_gpio45 = "/soc/[email protected]/pwm1_gpio45";
		cpu3 = "/cpus/[email protected]";
		pcm_gpio28 = "/soc/[email protected]/pcm_gpio28";
		dpi_gpio0 = "/soc/[email protected]/dpi_gpio0";
		power = "/soc/power";
		soc = "/soc";
		i2c0_gpio0 = "/soc/[email protected]/i2c0_gpio0";
		pcm_gpio18 = "/soc/[email protected]/pcm_gpio18";
		leds = "/leds";
		i2s_pins = "/soc/[email protected]/i2s";
		firmware = "/soc/firmware";
		cpu1 = "/cpus/[email protected]";
		mmc = "/soc/[email protected]";
		usbphy = "/phy";
		pixelvalve1 = "/soc/[email protected]";
		spi = "/soc/[email protected]";
		spi0_pins = "/soc/[email protected]/spi0_pins";
		i2c_arm = "/soc/[email protected]";
		clk_osc = "/clocks/[email protected]";
		ethernet = "/soc/[email protected]/[email protected]/[email protected]";
		uart0 = "/soc/[email protected]";
		pwm1_gpio13 = "/soc/[email protected]/pwm1_gpio13";
		i2c1_pins = "/soc/[email protected]/i2c1";
		cpu_thermal = "/thermal-zones/cpu-thermal";
		fb = "/soc/fb";
		pwm1_gpio41 = "/soc/[email protected]/pwm1_gpio41";
		sdhost_pins = "/soc/[email protected]/sdhost_gpio48";
		spi0_gpio7 = "/soc/[email protected]/spi0_gpio7";
		i2c2 = "/soc/[email protected]";
		uart1_pins = "/soc/[email protected]/uart1_pins";
		i2c1_gpio44 = "/soc/[email protected]/i2c1_gpio44";
		i2c0_gpio28 = "/soc/[email protected]/i2c0_gpio28";
		i2c_slave_gpio18 = "/soc/[email protected]/i2c_slave_gpio18";
		i2s = "/soc/[email protected]";
		emmc_gpio48 = "/soc/[email protected]/emmc_gpio48";
		spi1 = "/soc/[email protected]";
		virtgpio = "/soc/virtgpio";
		usb = "/soc/[email protected]";
		dsi0 = "/soc/[email protected]";
		i2c1_gpio2 = "/soc/[email protected]/i2c1_gpio2";
		expgpio = "/soc/expgpio";
		uart0_ctsrts_gpio38 = "/soc/[email protected]/uart0_ctsrts_gpio38";
		audio_pins = "/soc/[email protected]/audio_pins";
		i2c0 = "/soc/[email protected]";
		spi1_gpio16 = "/soc/[email protected]/spi1_gpio16";
		i2c0_pins = "/soc/[email protected]/i2c0";
		pwr_led = "/leds/pwr";
		watchdog = "/soc/[email protected]";
		jtag_gpio22 = "/soc/[email protected]/jtag_gpio22";
		spi2_gpio40 = "/soc/[email protected]/spi2_gpio40";
		uart0_pins = "/soc/[email protected]/uart0_pins";
		vec = "/soc/[email protected]";
		local_intc = "/soc/[email protected]";
		i2c0_gpio44 = "/soc/[email protected]/i2c0_gpio44";
		axiperf = "/soc/axiperf";
		spi0_cs_pins = "/soc/[email protected]/spi0_cs_pins";
		sound = "/soc/sound";
		hvs = "/soc/[email protected]";
		uart0_ctsrts_gpio16 = "/soc/[email protected]/uart0_ctsrts_gpio16";
		act_led = "/leds/act";
		gpclk2_gpio6 = "/soc/[email protected]/gpclk2_gpio6";
		spidev0 = "/soc/[email protected]/[email protected]";
		sdhost_gpio48 = "/soc/[email protected]/sdhost_gpio48";
		bt_pins = "/soc/[email protected]/bt_pins";
		emmc_gpio34 = "/soc/[email protected]/emmc_gpio34";
		gpclk1_gpio44 = "/soc/[email protected]/gpclk1_gpio44";
		uart1_gpio14 = "/soc/[email protected]/uart1_gpio14";
		uart0_gpio36 = "/soc/[email protected]/uart0_gpio36";
		sdio_pins = "/soc/[email protected]/sdio_pins";
		cpus = "/cpus";
		cpu2 = "/cpus/[email protected]";
		uart1_gpio32 = "/soc/[email protected]/uart1_gpio32";
		hdmi = "/soc/[email protected]";
		pixelvalve2 = "/soc/[email protected]";
		pwm0_gpio18 = "/soc/[email protected]/pwm0_gpio18";
		gpclk1_gpio42 = "/soc/[email protected]/gpclk1_gpio42";
		mailbox = "/soc/[email protected]";
		uart1_gpio40 = "/soc/[email protected]/uart1_gpio40";
		emmc_gpio22 = "/soc/[email protected]/emmc_gpio22";
		uart1 = "/soc/[email protected]";
		random = "/soc/[email protected]";
		i2c = "/soc/[email protected]";
		cpu0 = "/cpus/[email protected]";
	};

	soc {
		compatible = "simple-bus";
		ranges = <0x7e000000 0x3f000000 0x1000000 0x40000000 0x40000000 0x1000>;
		#address-cells = <0x1>;
		#size-cells = <0x1>;
		phandle = <0x32>;
		dma-ranges = <0xc0000000 0x0 0x3f000000>;

		[email protected] {
			compatible = "brcm,bcm2835-pl011", "arm,pl011", "arm,primecell";
			clocks = <0x8 0x13 0x8 0x14>;
			clock-names = "uartclk", "apb_pclk";
			status = "okay";
			interrupts = <0x2 0x19>;
			phandle = <0x1f>;
			arm,primecell-periphid = <0x241011>;
			reg = <0x7e201000 0x1000>;
			pinctrl-0 = <0x9 0xa>;
			cts-event-workaround;
			pinctrl-names = "default";
		};

		[email protected] {
			compatible = "brcm,bcm2835-pixelvalve1";
			status = "disabled";
			interrupts = <0x2 0xe>;
			phandle = <0x61>;
			reg = <0x7e207000 0x100>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-cprman";
			clocks = <0x4 0x5 0x0 0x5 0x1 0x5 0x2 0x6 0x0 0x6 0x1 0x6 0x2>;
			firmware = <0x7>;
			#clock-cells = <0x1>;
			phandle = <0x8>;
			reg = <0x7e101000 0x2000>;
		};

		[email protected] {
			compatible = "brcm,bcm2837-thermal";
			clocks = <0x8 0x1b>;
			#thermal-sensor-cells = <0x0>;
			status = "okay";
			phandle = <0x2>;
			reg = <0x7e212000 0x8>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-hvs";
			status = "disabled";
			interrupts = <0x2 0x1>;
			phandle = <0x65>;
			reg = <0x7e400000 0x6000>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-gpio";
			gpio-controller;
			#interrupt-cells = <0x2>;
			interrupts = <0x2 0x11 0x2 0x12>;
			phandle = <0x10>;
			reg = <0x7e200000 0xb4>;
			#gpio-cells = <0x2>;
			interrupt-controller;

			uart0_gpio14 {
				brcm,pins = <0xe 0xf>;
				phandle = <0x52>;
				brcm,function = <0x4>;
			};

			gpclk1_gpio5 {
				brcm,pins = <0x5>;
				phandle = <0x38>;
				brcm,function = <0x4>;
			};

			uart0_ctsrts_gpio30 {
				brcm,pins = <0x1e 0x1f>;
				phandle = <0x54>;
				brcm,function = <0x7>;
			};

			uart1_ctsrts_gpio16 {
				brcm,pins = <0x10 0x11>;
				phandle = <0x59>;
				brcm,function = <0x2>;
			};

			uart0_gpio32 {
				brcm,pins = <0x20 0x21>;
				phandle = <0x55>;
				brcm,function = <0x7>;
			};

			jtag_gpio4 {
				brcm,pins = <0x4 0x5 0x6 0xc 0xd>;
				phandle = <0x43>;
				brcm,function = <0x2>;
			};

			i2c1 {
				brcm,pins = <0x2 0x3>;
				phandle = <0x14>;
				brcm,function = <0x4>;
			};

			uart1_ctsrts_gpio42 {
				brcm,pins = <0x2a 0x2b>;
				phandle = <0x5d>;
				brcm,function = <0x2>;
			};

			gpclk0_gpio4 {
				brcm,pins = <0x4>;
				phandle = <0x37>;
				brcm,function = <0x4>;
			};

			pwm0_gpio12 {
				brcm,pins = <0xc>;
				phandle = <0x47>;
				brcm,function = <0x4>;
			};

			pwm1_gpio19 {
				brcm,pins = <0x13>;
				phandle = <0x4b>;
				brcm,function = <0x2>;
			};

			pwm0_gpio40 {
				brcm,pins = <0x28>;
				phandle = <0x49>;
				brcm,function = <0x4>;
			};

			gpclk2_gpio43 {
				brcm,pins = <0x2b>;
				phandle = <0x3c>;
				brcm,function = <0x4>;
			};

			uart1_ctsrts_gpio30 {
				brcm,pins = <0x1e 0x1f>;
				phandle = <0x5b>;
				brcm,function = <0x2>;
			};

			spi0_gpio35 {
				brcm,pins = <0x23 0x24 0x25 0x26 0x27>;
				phandle = <0x4f>;
				brcm,function = <0x4>;
			};

			pwm1_gpio45 {
				brcm,pins = <0x2d>;
				phandle = <0x4d>;
				brcm,function = <0x4>;
			};

			pcm_gpio28 {
				brcm,pins = <0x1c 0x1d 0x1e 0x1f>;
				phandle = <0x46>;
				brcm,function = <0x6>;
			};

			dpi_gpio0 {
				brcm,pins = <0x0 0x1 0x2 0x3 0x4 0x5 0x6 0x7 0x8 0x9 0xa 0xb 0xc 0xd 0xe 0xf 0x10 0x11 0x12 0x13 0x14 0x15 0x16 0x17 0x;
				phandle = <0x33>;
				brcm,function = <0x6>;
			};

			i2c0_gpio0 {
				brcm,pins = <0x0 0x1>;
				phandle = <0x3d>;
				brcm,function = <0x4>;
			};

			pcm_gpio18 {
				brcm,pins = <0x12 0x13 0x14 0x15>;
				phandle = <0x45>;
				brcm,function = <0x4>;
			};

			spi0_pins {
				brcm,pins = <0x9 0xa 0xb>;
				phandle = <0xe>;
				brcm,function = <0x4>;
			};

			pwm1_gpio13 {
				brcm,pins = <0xd>;
				phandle = <0x4a>;
				brcm,function = <0x4>;
			};

			pwm1_gpio41 {
				brcm,pins = <0x29>;
				phandle = <0x4c>;
				brcm,function = <0x4>;
			};

			spi0_gpio7 {
				brcm,pins = <0x7 0x8 0x9 0xa 0xb>;
				phandle = <0x4e>;
				brcm,function = <0x4>;
			};

			uart1_pins {
				brcm,pins;
				phandle = <0x13>;
				brcm,pull;
				brcm,function;
			};

			i2c1_gpio44 {
				brcm,pins = <0x2c 0x2d>;
				phandle = <0x41>;
				brcm,function = <0x6>;
			};

			i2c0_gpio28 {
				brcm,pins = <0x1c 0x1d>;
				phandle = <0x3e>;
				brcm,function = <0x4>;
			};

			i2c_slave_gpio18 {
				brcm,pins = <0x12 0x13 0x14 0x15>;
				phandle = <0x42>;
				brcm,function = <0x7>;
			};

			i2s {
				brcm,pins = <0x12 0x13 0x14 0x15>;
				phandle = <0xd>;
				brcm,function = <0x4>;
			};

			emmc_gpio48 {
				brcm,pins = <0x30 0x31 0x32 0x33 0x34 0x35>;
				phandle = <0x36>;
				brcm,function = <0x7>;
			};

			i2c1_gpio2 {
				brcm,pins = <0x2 0x3>;
				phandle = <0x40>;
				brcm,function = <0x4>;
			};

			uart0_ctsrts_gpio38 {
				brcm,pins = <0x26 0x27>;
				phandle = <0x57>;
				brcm,function = <0x6>;
			};

			audio_pins {
				brcm,pins = <0x28 0x29>;
				phandle = <0x1c>;
				brcm,function = <0x4>;
			};

			i2c0 {
				brcm,pins = <0x0 0x1>;
				phandle = <0x11>;
				brcm,function = <0x4>;
			};

			spi1_gpio16 {
				brcm,pins = <0x10 0x11 0x12 0x13 0x14 0x15>;
				phandle = <0x50>;
				brcm,function = <0x3>;
			};

			jtag_gpio22 {
				brcm,pins = <0x16 0x17 0x18 0x19 0x1a 0x1b>;
				phandle = <0x44>;
				brcm,function = <0x3>;
			};

			spi2_gpio40 {
				brcm,pins = <0x28 0x29 0x2a 0x2b 0x2c 0x2d>;
				phandle = <0x51>;
				brcm,function = <0x3>;
			};

			uart0_pins {
				brcm,pins = <0x20 0x21>;
				phandle = <0x9>;
				brcm,pull = <0x0 0x2>;
				brcm,function = <0x7>;
			};

			i2c0_gpio44 {
				brcm,pins = <0x2c 0x2d>;
				phandle = <0x3f>;
				brcm,function = <0x5>;
			};

			spi0_cs_pins {
				brcm,pins = <0x8 0x7>;
				phandle = <0xf>;
				brcm,function = <0x1>;
			};

			uart0_ctsrts_gpio16 {
				brcm,pins = <0x10 0x11>;
				phandle = <0x53>;
				brcm,function = <0x7>;
			};

			gpclk2_gpio6 {
				brcm,pins = <0x6>;
				phandle = <0x3b>;
				brcm,function = <0x4>;
			};

			sdhost_gpio48 {
				brcm,pins = <0x30 0x31 0x32 0x33 0x34 0x35>;
				phandle = <0xc>;
				brcm,function = <0x4>;
			};

			bt_pins {
				brcm,pins = <0x2b>;
				phandle = <0xa>;
				brcm,pull = <0x0>;
				brcm,function = <0x4>;
			};

			emmc_gpio34 {
				brcm,pins = <0x22 0x23 0x24 0x25 0x26 0x27>;
				phandle = <0x35>;
				brcm,pull = <0x0 0x2 0x2 0x2 0x2 0x2>;
				brcm,function = <0x7>;
			};

			gpclk1_gpio44 {
				brcm,pins = <0x2c>;
				phandle = <0x3a>;
				brcm,function = <0x4>;
			};

			uart1_gpio14 {
				brcm,pins = <0xe 0xf>;
				phandle = <0x58>;
				brcm,function = <0x2>;
			};

			uart0_gpio36 {
				brcm,pins = <0x24 0x25>;
				phandle = <0x56>;
				brcm,function = <0x6>;
			};

			sdio_pins {
				brcm,pins = <0x22 0x23 0x24 0x25 0x26 0x27>;
				phandle = <0x1a>;
				brcm,pull = <0x0 0x2 0x2 0x2 0x2 0x2>;
				brcm,function = <0x7>;
			};

			uart1_gpio32 {
				brcm,pins = <0x20 0x21>;
				phandle = <0x5a>;
				brcm,function = <0x2>;
			};

			pwm0_gpio18 {
				brcm,pins = <0x12>;
				phandle = <0x48>;
				brcm,function = <0x2>;
			};

			gpclk1_gpio42 {
				brcm,pins = <0x2a>;
				phandle = <0x39>;
				brcm,function = <0x4>;
			};

			uart1_gpio40 {
				brcm,pins = <0x28 0x29>;
				phandle = <0x5c>;
				brcm,function = <0x2>;
			};

			emmc_gpio22 {
				brcm,pins = <0x16 0x17 0x18 0x19 0x1a 0x1b>;
				phandle = <0x34>;
				brcm,function = <0x7>;
			};
		};

		[email protected] {
			compatible = "brcm,bcm2835-pixelvalve2";
			status = "disabled";
			interrupts = <0x2 0xa>;
			phandle = <0x67>;
			reg = <0x7e807000 0x100>;
		};

		[email protected] {
			power-domains = <0x16 0xa>;
			compatible = "brcm,vc4-v3d";
			status = "disabled";
			interrupts = <0x1 0xa>;
			phandle = <0x6b>;
			reg = <0x7ec00000 0x1000>;
		};

		gpu {
			compatible = "brcm,bcm2835-vc4";
			status = "disabled";
			phandle = <0x6c>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-mmc", "brcm,bcm2835-sdhci";
			clocks = <0x8 0x1c>;
			status = "okay";
			interrupts = <0x2 0x1e>;
			brcm,overclock-50 = <0x0>;
			bus-width = <0x4>;
			dma-names = "rx-tx";
			phandle = <0x29>;
			reg = <0x7e300000 0x100>;
			pinctrl-0 = <0x1a>;
			dmas = <0xb 0xb>;
			non-removable;
			pinctrl-names = "default";
		};

		arm-pmu {
			compatible = "arm,cortex-a7-pmu";
			interrupt-parent = <0x3>;
			interrupts = <0x9>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-spi";
			clocks = <0x8 0x14>;
			status = "okay";
			#address-cells = <0x1>;
			interrupts = <0x2 0x16>;
			cs-gpios = <0x10 0x8 0x1 0x10 0x7 0x1>;
			#size-cells = <0x0>;
			dma-names = "tx", "rx";
			phandle = <0x22>;
			reg = <0x7e204000 0x1000>;
			pinctrl-0 = <0xe 0xf>;
			dmas = <0xb 0x6 0xb 0x7>;
			pinctrl-names = "default";

			[email protected] {
				compatible = "spidev";
				#address-cells = <0x1>;
				#size-cells = <0x0>;
				phandle = <0x5f>;
				reg = <0x1>;
				spi-max-frequency = <0x7735940>;
			};

			[email protected] {
				compatible = "spidev";
				#address-cells = <0x1>;
				#size-cells = <0x0>;
				phandle = <0x5e>;
				reg = <0x0>;
				spi-max-frequency = <0x7735940>;
			};
		};

		vchiq {
			compatible = "brcm,bcm2835-vchiq";
			cache-line-size = <0x40>;
			firmware = <0x7>;
			interrupts = <0x0 0x2>;
			phandle = <0x1e>;
			reg = <0x7e00b840 0xf>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-i2c";
			clocks = <0x8 0x14>;
			status = "okay";
			#address-cells = <0x1>;
			interrupts = <0x2 0x15>;
			#size-cells = <0x0>;
			phandle = <0x24>;
			reg = <0x7e804000 0x1000>;
			clock-frequency = <0x186a0>;
			pinctrl-0 = <0x14>;
			pinctrl-names = "default";

			[email protected] {
				compatible = "nxp,sc16is752";
				clocks = <0x7a>;
				gpio-controller;
				status = "okay";
				i2c-max-frequency = <0x61a80>;
				interrupt-parent = <0x10>;
				interrupts = <0x19 0x2>;
				phandle = <0x7b>;
				reg = <0x4c>;
				#gpio-cells = <0x0>;

				sc16is752_clk {
					compatible = "fixed-clock";
					#clock-cells = <0x0>;
					phandle = <0x7a>;
					clock-frequency = <0xe10000>;
				};
			};

			[email protected] {
				compatible = "nxp,sc16is752";
				clocks = <0x77>;
				gpio-controller;
				status = "okay";
				i2c-max-frequency = <0x61a80>;
				interrupt-parent = <0x10>;
				interrupts = <0x12 0x2>;
				phandle = <0x78>;
				reg = <0x48>;
				#gpio-cells = <0x0>;

				sc16is752_clk {
					compatible = "fixed-clock";
					#clock-cells = <0x0>;
					phandle = <0x77>;
					clock-frequency = <0xe10000>;
				};
			};
		};

		vcsm {
			compatible = "raspberrypi,bcm2835-vcsm";
			firmware = <0x7>;
			status = "okay";
			phandle = <0x71>;
		};

		audio {
			brcm,pwm-channels = <0x8>;
			compatible = "brcm,bcm2835-audio";
			status = "disabled";
			phandle = <0x25>;
			pinctrl-0 = <0x1c>;
			pinctrl-names = "default";
		};

		[email protected] {
			compatible = "brcm,bcm2835-i2s";
			clocks = <0x8 0x1f>;
			#sound-dai-cells = <0x0>;
			status = "disabled";
			dma-names = "tx", "rx";
			phandle = <0x21>;
			reg = <0x7e203000 0x24>;
			pinctrl-0 = <0xd>;
			dmas = <0xb 0x2 0xb 0x3>;
			pinctrl-names = "default";
		};

		[email protected] {
			compatible = "brcm,bcm2835-mbox";
			#mbox-cells = <0x0>;
			interrupts = <0x0 0x1>;
			phandle = <0x1b>;
			reg = <0x7e00b880 0x40>;
		};

		gpiomem {
			compatible = "brcm,bcm2835-gpiomem";
			reg = <0x7e200000 0x1000>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-vec";
			clocks = <0x8 0x18>;
			status = "disabled";
			interrupts = <0x2 0x1b>;
			phandle = <0x66>;
			reg = <0x7e806000 0x1000>;
		};

		power {
			compatible = "raspberrypi,bcm2835-power";
			firmware = <0x7>;
			phandle = <0x16>;
			#power-domain-cells = <0x1>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-pixelvalve0";
			status = "disabled";
			interrupts = <0x2 0xd>;
			phandle = <0x60>;
			reg = <0x7e206000 0x100>;
		};

		firmware {
			compatible = "raspberrypi,bcm2835-firmware";
			mboxes = <0x1b>;
			phandle = <0x7>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-dsi0";
			clocks = <0x8 0x20 0x8 0x2f 0x8 0x31>;
			clock-names = "phy", "escape", "pixel";
			#address-cells = <0x1>;
			interrupts = <0x2 0x4>;
			#size-cells = <0x0>;
			#clock-cells = <0x1>;
			phandle = <0x5>;
			reg = <0x7e209000 0x78>;
			clock-output-names = "dsi0_byte", "dsi0_ddr2", "dsi0_ddr";
		};

		fb {
			compatible = "brcm,bcm2708-fb";
			firmware = <0x7>;
			status = "okay";
			phandle = <0x70>;
		};

		[email protected] {
			compatible = "brcm,bcm2836-l1-intc";
			#interrupt-cells = <0x1>;
			interrupt-parent = <0x3>;
			phandle = <0x3>;
			reg = <0x40000000 0x100>;
			interrupt-controller;
		};

		virtgpio {
			compatible = "brcm,bcm2835-virtgpio";
			gpio-controller;
			firmware = <0x7>;
			status = "okay";
			phandle = <0x1d>;
			#gpio-cells = <0x2>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-dpi";
			clocks = <0x8 0x14 0x8 0x2c>;
			clock-names = "core", "pixel";
			status = "disabled";
			#address-cells = <0x1>;
			#size-cells = <0x0>;
			phandle = <0x6d>;
			reg = <0x7e208000 0x8c>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-sdhost";
			clocks = <0x8 0x14>;
			brcm,pio-limit = <0x1>;
			status = "okay";
			interrupts = <0x2 0x18>;
			brcm,overclock-50 = <0x0>;
			bus-width = <0x4>;
			dma-names = "rx-tx";
			phandle = <0x28>;
			reg = <0x7e202000 0x100>;
			pinctrl-0 = <0xc>;
			dmas = <0xb 0xd>;
			pinctrl-names = "default";
		};

		expgpio {
			compatible = "brcm,bcm2835-expgpio";
			gpio-controller;
			firmware = <0x7>;
			status = "okay";
			phandle = <0x17>;
			#gpio-cells = <0x2>;
		};

		[email protected] {
			power-domains = <0x16 0x5>;
			compatible = "brcm,bcm2835-hdmi";
			clocks = <0x8 0x10 0x8 0x19>;
			clock-names = "pixel", "hdmi";
			ddc = <0x15>;
			status = "disabled";
			interrupts = <0x2 0x8 0x2 0x9>;
			dma-names = "audio-rx";
			phandle = <0x68>;
			hpd-gpios = <0x17 0x4 0x1>;
			reg = <0x7e902000 0x600 0x7e808000 0x100>;
			dmas = <0xb 0x11>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-pwm";
			clocks = <0x8 0x1e>;
			status = "disabled";
			assigned-clock-rates = <0x989680>;
			assigned-clocks = <0x8 0x1e>;
			phandle = <0x64>;
			reg = <0x7e20c000 0x28>;
			#pwm-cells = <0x2>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-pm-wdt";
			phandle = <0x26>;
			reg = <0x7e100000 0x28>;
		};

		[email protected] {
			compatible = "brcm,bcm2836-armctrl-ic";
			#interrupt-cells = <0x2>;
			interrupt-parent = <0x3>;
			interrupts = <0x8>;
			phandle = <0x1>;
			reg = <0x7e00b200 0x200>;
			interrupt-controller;
		};

		[email protected] {
			compatible = "brcm,bcm2835-dsi1";
			clocks = <0x8 0x23 0x8 0x30 0x8 0x32>;
			clock-names = "phy", "escape", "pixel";
			status = "disabled";
			#address-cells = <0x1>;
			interrupts = <0x2 0xc>;
			#size-cells = <0x0>;
			#clock-cells = <0x1>;
			phandle = <0x6>;
			reg = <0x7e700000 0x8c>;
			clock-output-names = "dsi1_byte", "dsi1_ddr2", "dsi1_ddr";
		};

		axiperf {
			compatible = "brcm,bcm2835-axiperf";
			firmware = <0x7>;
			status = "disabled";
			phandle = <0x2a>;
			reg = <0x7e009800 0x100 0x7ee08000 0x100>;
		};

		sound {
			status = "disabled";
			phandle = <0x72>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-i2c";
			clocks = <0x8 0x14>;
			status = "disabled";
			#address-cells = <0x1>;
			interrupts = <0x2 0x15>;
			#size-cells = <0x0>;
			phandle = <0x23>;
			reg = <0x7e205000 0x1000>;
			clock-frequency = <0x186a0>;
			pinctrl-0 = <0x11>;
			pinctrl-names = "default";
		};

		[email protected] {
			compatible = "brcm,bcm2835-aux-uart";
			clocks = <0x12 0x0>;
			status = "disabled";
			interrupt-parent = <0x12>;
			interrupts = <0x0>;
			phandle = <0x20>;
			reg = <0x7e215040 0x40>;
			pinctrl-0 = <0x13>;
			pinctrl-names = "default";
		};

		[email protected] {
			#dma-cells = <0x1>;
			compatible = "brcm,bcm2835-dma";
			brcm,dma-channel-mask = <0x7f34>;
			interrupts = <0x1 0x10 0x1 0x11 0x1 0x12 0x1 0x13 0x1 0x14 0x1 0x15 0x1 0x16 0x1 0x17 0x1 0x18 0x1 0x19 0x1 0x1a 0x1 0x1b 0x1 0;
			phandle = <0xb>;
			reg = <0x7e007000 0xf00>;
			interrupt-names = "dma0", "dma1", "dma2", "dma3", "dma4", "dma5", "dma6", "dma7", "dma8", "dma9", "dma10", "dma11", "dma12", "d;
		};

		[email protected] {
			compatible = "brcm,bcm2835-i2c";
			clocks = <0x8 0x14>;
			status = "disabled";
			#address-cells = <0x1>;
			interrupts = <0x2 0x15>;
			#size-cells = <0x0>;
			phandle = <0x15>;
			reg = <0x7e805000 0x1000>;
			clock-frequency = <0x186a0>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-aux-spi";
			clocks = <0x12 0x1>;
			status = "disabled";
			interrupt-parent = <0x12>;
			#address-cells = <0x1>;
			interrupts = <0x1>;
			#size-cells = <0x0>;
			phandle = <0x62>;
			reg = <0x7e215080 0x40>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-aux";
			clocks = <0x8 0x14>;
			#interrupt-cells = <0x1>;
			interrupts = <0x1 0x1d>;
			#clock-cells = <0x1>;
			phandle = <0x12>;
			reg = <0x7e215000 0x8>;
			interrupt-controller;
		};

		[email protected] {
			compatible = "raspberrypi,rpi-firmware-kms";
			status = "disabled";
			interrupts = <0x2 0x10>;
			brcm,firmware = <0x7>;
			phandle = <0x6e>;
			reg = <0x7e600000 0x100>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-rng";
			phandle = <0x27>;
			reg = <0x7e104000 0x10>;
		};

		[email protected] {
			power-domains = <0x16 0x6>;
			compatible = "brcm,bcm2708-usb";
			clocks = <0x18>;
			clock-names = "otg";
			phy-names = "usb2-phy";
			#address-cells = <0x1>;
			interrupts = <0x2 0x0 0x1 0x9>;
			#size-cells = <0x0>;
			phandle = <0x69>;
			phys = <0x19>;
			reg = <0x7e980000 0x10000 0x7e006000 0x1000>;

			[email protected] {
				compatible = "usb424,9514";
				#address-cells = <0x1>;
				#size-cells = <0x0>;
				reg = <0x1>;

				[email protected] {
					compatible = "usb424,ec00";
					local-mac-address = [b8 27 eb 0f e5 20];
					phandle = <0x6a>;
					reg = <0x1>;
				};
			};
		};

		[email protected] {
			compatible = "brcm,bcm2835-smi";
			clocks = <0x8 0x2a>;
			status = "disabled";
			interrupts = <0x2 0x10>;
			assigned-clock-rates = <0x7735940>;
			dma-names = "rx-tx";
			assigned-clocks = <0x8 0x2a>;
			phandle = <0x6f>;
			reg = <0x7e600000 0x100>;
			dmas = <0xb 0x4>;
		};

		[email protected] {
			compatible = "brcm,bcm2835-aux-spi";
			clocks = <0x12 0x2>;
			status = "disabled";
			interrupt-parent = <0x12>;
			#address-cells = <0x1>;
			interrupts = <0x2>;
			#size-cells = <0x0>;
			phandle = <0x63>;
			reg = <0x7e2150c0 0x40>;
		};
	};

	leds {
		compatible = "gpio-leds";
		phandle = <0x76>;

		act {
			gpios = <0x1d 0x0 0x0>;
			label = "led0";
			phandle = <0x2f>;
			linux,default-trigger = "mmc0";
		};

		pwr {
			gpios = <0x17 0x7 0x0>;
			label = "led1";
			phandle = <0x30>;
			linux,default-trigger = "input";
		};
	};

	aliases {
		intc = "/soc/[email protected]";
		spi2 = "/soc/[email protected]";
		i2c1 = "/soc/[email protected]";
		i2c_vc = "/soc/[email protected]";
		spi0 = "/soc/[email protected]";
		thermal = "/soc/[email protected]";
		vchiq = "/soc/vchiq";
		sdhost = "/soc/[email protected]";
		aux = "/soc/[email protected]";
		gpio = "/soc/[email protected]";
		mmc1 = "/soc/[email protected]";
		audio = "/soc/audio";
		dma = "/soc/[email protected]";
		ethernet0 = "/soc/[email protected]/[email protected]/[email protected]";
		soc = "/soc";
		leds = "/leds";
		mmc = "/soc/[email protected]";
		serial1 = "/soc/[email protected]";
		i2c_arm = "/soc/[email protected]";
		uart0 = "/soc/[email protected]";
		fb = "/soc/fb";
		i2c2 = "/soc/[email protected]";
		i2s = "/soc/[email protected]";
		spi1 = "/soc/[email protected]";
		usb = "/soc/[email protected]";
		i2c0 = "/soc/[email protected]";
		watchdog = "/soc/[email protected]";
		axiperf = "/soc/axiperf";
		mmc0 = "/soc/[email protected]";
		sound = "/soc/sound";
		mailbox = "/soc/[email protected]";
		uart1 = "/soc/[email protected]";
		random = "/soc/[email protected]";
		i2c = "/soc/[email protected]";
		serial0 = "/soc/[email protected]";
	};

	chosen {
		bootargs = "8250.nr_uarts=0 bcm2708_fb.fbwidth=656 bcm2708_fb.fbheight=416 bcm2708_fb.fbswap=1 vc_mem.mem_base=0x3ec00000 vc_mem.mem_si;
		kaslr-seed = <0xc25fa8b7 0x82f751a6>;
	};

	thermal-zones {

		cpu-thermal {
			thermal-sensors = <0x2>;
			polling-delay = <0x3e8>;
			polling-delay-passive = <0x0>;
			coefficients = <0xfffffde6 0x64960>;
			phandle = <0x31>;

			cooling-maps {
			};
		};
	};

	timer {
		compatible = "arm,armv7-timer";
		always-on;
		interrupt-parent = <0x3>;
		interrupts = <0x0 0x1 0x3 0x2>;
	};

	memory {
		device_type = "memory";
		reg = <0x0 0x38000000>;
	};

	phy {
		compatible = "usb-nop-xceiv";
		phandle = <0x19>;
		#phy-cells = <0x0>;
	};

	fixedregulator_3v3 {
		compatible = "regulator-fixed";
		phandle = <0x75>;
		regulator-min-microvolt = <0x325aa0>;
		regulator-max-microvolt = <0x325aa0>;
		regulator-always-on;
		regulator-name = "3v3";
	};

	cpus {
		enable-method = "brcm,bcm2836-smp";
		#address-cells = <0x1>;
		#size-cells = <0x0>;
		phandle = <0x73>;

		[email protected] {
			compatible = "arm,cortex-a53";
			cpu-release-addr = <0x0 0xf0>;
			device_type = "cpu";
			enable-method = "spin-table";
			phandle = <0x2e>;
			reg = <0x3>;
			clock-frequency = <0x47868c00>;
		};

		[email protected] {
			compatible = "arm,cortex-a53";
			cpu-release-addr = <0x0 0xe0>;
			device_type = "cpu";
			enable-method = "spin-table";
			phandle = <0x2c>;
			reg = <0x1>;
			clock-frequency = <0x47868c00>;
		};

		[email protected] {
			compatible = "arm,cortex-a53";
			cpu-release-addr = <0x0 0xe8>;
			device_type = "cpu";
			enable-method = "spin-table";
			phandle = <0x2d>;
			reg = <0x2>;
			clock-frequency = <0x47868c00>;
		};

		[email protected] {
			compatible = "arm,cortex-a53";
			cpu-release-addr = <0x0 0xd8>;
			device_type = "cpu";
			enable-method = "spin-table";
			phandle = <0x2b>;
			reg = <0x0>;
			clock-frequency = <0x47868c00>;
		};
	};

	fixedregulator_5v0 {
		compatible = "regulator-fixed";
		phandle = <0x74>;
		regulator-min-microvolt = <0x4c4b40>;
		regulator-max-microvolt = <0x4c4b40>;
		regulator-always-on;
		regulator-name = "5v0";
	};

	axi {

		vc_mem {
			reg = <0x3ec00000 0x40000000 0xc0000000>;
		};
	};
};

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:15 am

and i found it:

Code: Select all

[email protected] {
			compatible = "brcm,bcm2835-i2c";
			clocks = <0x8 0x14>;
			status = "okay";
			#address-cells = <0x1>;
			interrupts = <0x2 0x15>;
			#size-cells = <0x0>;
			phandle = <0x24>;
			reg = <0x7e804000 0x1000>;
			clock-frequency = <0x186a0>;
			pinctrl-0 = <0x14>;
			pinctrl-names = "default";

			[email protected] {
				compatible = "nxp,sc16is752";
				clocks = <0x7a>;
				gpio-controller;
				status = "okay";
				i2c-max-frequency = <0x61a80>;
				interrupt-parent = <0x10>;
				interrupts = <0x19 0x2>;
				phandle = <0x7b>;
				reg = <0x4c>;
				#gpio-cells = <0x0>;

				sc16is752_clk {
					compatible = "fixed-clock";
					#clock-cells = <0x0>;
					phandle = <0x7a>;
					clock-frequency = <0xe10000>;
				};
			};

			[email protected] {
				compatible = "nxp,sc16is752";
				clocks = <0x77>;
				gpio-controller;
				status = "okay";
				i2c-max-frequency = <0x61a80>;
				interrupt-parent = <0x10>;
				interrupts = <0x12 0x2>;
				phandle = <0x78>;
				reg = <0x48>;
				#gpio-cells = <0x0>;

				sc16is752_clk {
					compatible = "fixed-clock";
					#clock-cells = <0x0>;
					phandle = <0x77>;
					clock-frequency = <0xe10000>;
				};
			};
		};

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:24 am

Yes, that's what I was looking for, and it all looks correct - both instances are present, and each has its own clock.

The order the kernel processes the Device Tree isn't defined, but if you swap the order of dtoverlays does it make any difference to which device gets used (the device showing as == in i2cdetect)?

Try making the I2C addresses of each of the overlays invalid, one at a time, e.g. 48 & 5c as one pair, then 58 & 4c as another pair. Does the valid address always end up getting used (==)?

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:42 am

if:

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=18,addr=0x4c
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x48

Code: Select all

^[[[email protected]:i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- UU -- -- -- 4c -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --        
else if:

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=25,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=18,addr=0x4c

Code: Select all

^[[[email protected]:i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- 4c -- -- --UU  -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --        

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:47 am

Thanks - I interpret those results to mean that both configurations are correct, and that the driver is failing to be instantiated twice. I can read the code to see if anything sticks out as a possible reason, but I may need to modify the driver to add extra debugging. This will be a low priority task - I hope you understand.

hnwangkg163
Posts: 19
Joined: Tue Sep 11, 2018 6:01 am

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:52 am

Ok, because the products we designed have been produced and sold, and now we have received several feedbacks that we cannot use two modules. If you plan this, can you tell me here that it has been fixed? Now I can only write code to drive this module myself to make it work.

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Wed Mar 13, 2019 9:55 am

Please remember that even though the driver is part of the standard kernel tree, and we build it and supply overlays so it can be used, the SC16IS752 is not a device specifically supported by Raspberry Pi.

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Mon Mar 18, 2019 9:03 am

Sorry it's taken a while to get back to this, but I have a test build of the module with some extra debugging - you can download it here: https://drive.google.com/open?id=0B_P-i ... nBmYkFaUHM

It should work with the kernel you have - install it with:

Code: Select all

sudo cp sc16is7xx.ko /lib/modules/4.14.50-v7+/kernel/drivers/tty/serial
After a reboot, look at the output from dmesg for errors - "dmesg -l err" only shows the errors. You should notice that an extra message saying "Built with added debugging"; if not, you must be running a different kernel version - report the output of "uname -a" and I'll build you another.

qkidamon
Posts: 5
Joined: Mon Mar 18, 2019 1:03 pm

Re: How to use 2 SC16IS752,I USE I2C

Mon Mar 18, 2019 1:14 pm

Hi. all.

I'm suffering from the same issue that hnwangkg163 explains from start.

I'have followed the tests that was provided throught the present thread and i'm getting identical results in all steps.

I think i understand from a previous reply that this issue may be a SC16IS752 driver problem. If, at the end, the driver is the reason, should we expect a driver uptade and fix in the next kernel releases ?

My kernel release is 4.14.98+. Should i get a modified debugging module in order to send debug information if needed ?

Thanks in advance.

Miguel.
Last edited by qkidamon on Tue Mar 19, 2019 8:14 pm, edited 1 time in total.

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Mon Mar 18, 2019 1:59 pm

Is that a "4.14.98-v7+" kernel or do you really have a BCM2835 Pi (original A or B, A+, B+, Zero or CM1)?

PhilE
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 2385
Joined: Mon Sep 29, 2014 1:07 pm
Location: Cambridge

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 19, 2019 9:34 am

Here are builds to cover both cases: 4.14.98+ and 4.14.98-v7+.

qkidamon
Posts: 5
Joined: Mon Mar 18, 2019 1:03 pm

Re: How to use 2 SC16IS752,I USE I2C

Tue Mar 19, 2019 8:07 pm

Ok.

I own what i think is a genuine PI ZERO W. And my kernel versión is what "uname -r" command shows for my unit.

Thanks for the rebuilt modules.

As you said, SC16IS752 modified module throws debug messages to "dmesg" output (as you can see in the next image):

https://drive.google.com/file/d/0B1h83u ... sp=sharing

My current dtoverlay config is:

Code: Select all

dtoverlay=sc16is752-i2c,int_pin=18,addr=0x48
dtoverlay=sc16is752-i2c,int_pin=25,addr=0x4c

"i2cdetect" and "i2cdump" commands output what next image shows:

https://drive.google.com/file/d/0B1h83u ... sp=sharing

Thanks.

Return to “Device Tree”