banksy-git / lidl-gateway-freedom

Freeing the Silvercrest (Lidl/Tuya) Smart Home Gateway from the cloud.
https://paulbanks.org/projects/lidl-zigbee/
GNU General Public License v3.0
206 stars 66 forks source link

segmentation fault on SGWZ 1 A2 #29

Closed sj29fr closed 1 year ago

sj29fr commented 1 year ago

Hello, I rooted my LIDL gateway thanks to your great job, but I get a newer version with Homekit feature. The PCB looks the same (TYGWZ1 with TYZS4 module). The root python script has worked, and I successfully modified ssh server to port 22 and sent serialgateway.bin executable. Unfortunately I get an error when running your serial gateway. Do you know if I need to get a newer toolchain to rebuild your software with RSDK-4.6.4 and where to find it? Best Regards, Sebastien

# ./serialgateway
Segmentation fault

I grabbed some info from my device:

# cat /proc/version
Linux version 3.10.90 (zhangpc@embed) (gcc version 4.6.4 (Realtek RSDK-4.6.4 Build 2080) ) #1 Thu Jul 29 21:36:28 CST 2021

# cat /proc/cpuinfo
system type             : RTL8196E
machine                 : Unknown
processor               : 0
cpu model               : 52481
BogoMIPS                : 378.47
tlb_entries             : 32
mips16 implemented      : yes

# ls /dev/
console     mtd3        mtdblock11  null        sda1        ttyS1
fuse        mtd3dro     mtdblock2   ppp         sda2        ttyp0
misc        mtd4        mtdblock3   ptmx        sdb         ttyp1
mtd0        mtd4dro     mtdblock4   pts         sdb1        ttyp2
mtd0dro     mtd5        mtdblock5   ptyp0       sdb2        ttyp3
mtd1        mtd5dro     mtdblock6   ptyp1       sdc         urandom
mtd1dro     mtdblock0   mtdblock7   ptyp2       sdc1        zero
mtd2        mtdblock1   mtdblock8   random      sdc2
mtd2dro     mtdblock10  mtdblock9   sda         ttyS0

# cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00020000 00010000 "boot+cfg"
mtd1: 001e0000 00010000 "linux"
mtd2: 00200000 00010000 "rootfs"
mtd3: 00020000 00010000 "tuya-label"
mtd4: 00be0000 00010000 "jffs2-fs"

# ls /lib/
ld-uClibc-0.9.33.so      libm.so                  libstdc++.so.6.0.16
ld-uClibc.so             libm.so.0                libthread_db-0.9.33.so
ld-uClibc.so.0           libnsl-0.9.33.so         libthread_db.so
ld.so.1                  libnsl.so                libthread_db.so.1
libc.so                  libnsl.so.0              libuClibc-0.9.33.so
libc.so.0                libpthread-0.9.33.so     libuargp-0.9.33.so
libcrypt-0.9.33.so       libpthread.so            libuargp.so
libcrypt.so              libpthread.so.0          libuargp.so.0
libcrypt.so.0            libresolv-0.9.33.so      libubacktrace-0.9.33.so
libdl-0.9.33.so          libresolv.so             libubacktrace.so
libdl.so                 libresolv.so.0           libubacktrace.so.0
libdl.so.0               librt-0.9.33.so          libz.so
libgcc.so                librt.so                 libz.so.1
libgcc_s.so              librt.so.0               libz.so.1.2.8
libgcc_s.so.1            libstdc++.so
libm-0.9.33.so           libstdc++.so.6
sj29fr commented 1 year ago

I reply to myself. Finally I tried to download (with wget) and install bin via WSL and it's working. I don't need to rebuild it.