EliasKotlyar / Xiaomi-Dafang-Hacks

4.18k stars 1k forks source link

FIX INCLUDED: SW Nightmode not working #1301

Closed 0n3-70uch closed 4 years ago

0n3-70uch commented 4 years ago

Description

Do not auto switch to night or day mode.

Everything similar to this: https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/issues/1300

What did you do to debug the issue

See link above.

Evidence

Summary of all log files
==> /var/log/isp_tuning_func <==
0x0000000f
�?wl�C0�whdw
==> /var/log/lighttpd-access.log <==
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:10:22 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334512 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:10:32 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334503 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:10:42 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334356 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.20 192.168.2.13 root [02/Mar/2020:17:10:44 +0100] "POST /cgi-bin/action.cgi?cmd=showlog HTTP/1.1" 200 1251 "https://192.168.2.13/" "Mozilla/5.0 (X11; Fedora; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.122 Safari/537.36"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:10:52 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334183 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:11:02 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334370 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:11:12 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 333954 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:11:22 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334340 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:11:32 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334087 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"
192.168.2.11 192.168.2.13 root [02/Mar/2020:17:11:42 +0100] "GET /cgi-bin/currentpic.cgi HTTP/1.1" 200 334429 "-" "HomeAssistant/0.106.2 aiohttp/3.6.1 Python/3.7"

==> /var/log/lighttpd-cgi-stderr.log <==
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/system/sdcard/.lastCommitDate': No such file or directory
cat: can't open '/tmp/v4l2rtspserver-master.log': No such file or directory
cat: can't open '/system/sdcard/log/update.log': No such file or directory

==> /var/log/lighttpd-error.log <==
2020-03-02 16:17:50: (server.c.1423) server started (lighttpd/1.4.50-devel-lighttpd-1.4.49-7-g26fb8d3e)
Content of dmesg
[    0.000000] Initializing cgroup subsys cpu
[    0.000000] Initializing cgroup subsys cpuacct
[    0.000000] Linux version 3.10.14 (root@ubuntu) (gcc version 4.7.2 (Ingenic r2.3.3 2016.12) ) #21 PREEMPT Thu Oct 19 11:38:16 CST 2017
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 RESET ERROR PC:DF02A4F3
[    0.000000] CPU0 revision is: 00d00101 (Ingenic Xburst)
[    0.000000] FPU revision is: 00b70000
[    0.000000] cgu_get_rate, parent = 860160000, rate = 0, m = 0, n = 0, reg val = 0x000020ff
[    0.000000] CCLK:860MHz L2CLK:430Mhz H0CLK:200MHz H2CLK:200Mhz PCLK:100Mhz
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 0051b000 @ 00010000 (usable)
[    0.000000]  memory: 00035000 @ 0052b000 (usable after init)
[    0.000000] User-defined physical RAM map:
[    0.000000]  memory: 06000000 @ 00000000 (usable)
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x00000000-0x05ffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x00000000-0x05ffffff]
[    0.000000] On node 0 totalpages: 24576
[    0.000000] free_area_init_node: node 0, pgdat 805285f0, node_mem_map 81000000
[    0.000000]   Normal zone: 192 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 24576 pages, LIFO batch:3
[    0.000000] Primary instruction cache 32kB, 8-way, VIPT, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 8-way, VIPT, no aliases, linesize 32 bytes
[    0.000000] pls check processor_id[0x00d00101],sc_jz not support!
[    0.000000] MIPS secondary cache 128kB, 8-way, linesize 32 bytes.
[    0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
[    0.000000] pcpu-alloc: [0] 0 
[    0.000000] Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 24384
[    0.000000] Kernel command line: console=ttyS1,115200n8 mem=96M@0x0 ispmem=8M@0x6000000 rmem=24M@0x6800000 init=/linuxrc rootfstype=squashfs root=/dev/mtdblock2 rw mtdparts=jz_sfc:256k(boot),2048k(kernel),3392k(root),640k(driver),4736k(appfs),2048k(backupk),640k(backupd),2048k(backupa),256k(config),256k(para),-(flag)
[    0.000000] PID hash table entries: 512 (order: -1, 2048 bytes)
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
[    0.000000] Memory: 91236k/98304k available (3951k kernel code, 7068k reserved, 1276k data, 212k init, 0k highmem)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000] NR_IRQS:418
[    0.000000] clockevents_config_and_register success.
[    0.000024] Calibrating delay loop... 858.52 BogoMIPS (lpj=4292608)
[    0.087752] pid_max: default: 32768 minimum: 301
[    0.092736] Mount-cache hash table entries: 512
[    0.097834] Initializing cgroup subsys debug
[    0.102095] Initializing cgroup subsys freezer
[    0.109157] regulator-dummy: no parameters
[    0.113402] NET: Registered protocol family 16
[    0.134959] bio: create slab  at 0
[    0.141336] jz-dma jz-dma: JZ SoC DMA initialized
[    0.146588] SCSI subsystem initialized
[    0.150522] usbcore: registered new interface driver usbfs
[    0.156101] usbcore: registered new interface driver hub
[    0.161538] usbcore: registered new device driver usb
[    0.166841] i2c-gpio i2c-gpio.1: using pins 57 (SDA) and 58 (SCL)
[    0.173038]  (null): set:249  hold:250 dev=100000000 h=500 l=500
[    0.179181] media: Linux media interface: v0.10
[    0.183743] Linux video capture interface: v2.00
[    0.190527] Switching to clocksource jz_clocksource
[    0.195483] cfg80211: Calling CRDA to update world regulatory domain
[    0.202552] jz-dwc2 jz-dwc2: cgu clk gate get error
[    0.207489] jz-dwc2 jz-dwc2: regulator vbus get error
[    0.212574] DWC IN OTG MODE
[    0.365827] sft id =========================off
[    0.370429] dwc2 dwc2: Keep PHY ON
[    0.373818] dwc2 dwc2: Using Buffer DMA mode
[    0.577967] dwc2 dwc2: Core Release: 3.00a
[    0.582089] dwc2 dwc2: DesignWare USB2.0 High-Speed Host Controller
[    0.588418] dwc2 dwc2: new USB bus registered, assigned bus number 1
[    0.595827] hub 1-0:1.0: USB hub found
[    0.599572] hub 1-0:1.0: 1 port detected
[    0.603718] dwc2 dwc2: DWC2 Host Initialized
[    0.608216] NET: Registered protocol family 2
[    0.613204] TCP established hash table entries: 1024 (order: 1, 8192 bytes)
[    0.620229] TCP bind hash table entries: 1024 (order: 0, 4096 bytes)
[    0.626711] TCP: Hash tables configured (established 1024 bind 1024)
[    0.633164] TCP: reno registered
[    0.636363] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.642316] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.648920] NET: Registered protocol family 1
[    0.653634] RPC: Registered named UNIX socket transport module.
[    0.659567] RPC: Registered udp transport module.
[    0.664401] RPC: Registered tcp transport module.
[    0.669103] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.676146] freq_udelay_jiffys[0].max_num = 10
[    0.680573] cpufreq  udelay  loops_per_jiffy 
[    0.685039] dwc2 dwc2: ID PIN CHANGED!
[    0.688819] init DWC as A_HOST
[    0.691921] 12000     59885   59885  
[    0.695143] 24000     119771  119771 
[    0.698586] 60000     299428  299428 
[    0.702219] 120000    598857  598857 
[    0.705676] 200000    998095  998095 
[    0.709207] 300000    1497142     1497142    
[    0.712950] 600000    2994285     2994285    
[    0.716624] 792000    3952457     3952457    
[    0.720332] 1008000   5030400     5030400    
[    0.724141] 1200000   5988571     5988571    
[    0.733517] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.740364] jffs2: version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
[    0.746971] msgmni has been set to 178
[    0.752206] io scheduler noop registered
[    0.756143] io scheduler cfq registered (default)
[    0.762814] jz-uart.1: ttyS1 at MMIO 0x10031000 (irq = 58) is a uart1
[    0.771004] console [ttyS1] enabled, bootconsole disabled
[    0.786223] brd: module loaded
[    0.791481] loop: module loaded
[    0.795635] zram: Created 2 device(s) ...
[    0.799874] logger: created 256K log 'log_main'
[    0.805272] jz SADC driver registeres over!
[    0.810580] jz TCU driver register completed
[    0.815822] the id code = c84018, the flash name is GD25Q127C
[    0.821785] JZ SFC Controller for SFC channel 0 driver register
[    0.827991] 11 cmdlinepart partitions found on MTD device jz_sfc
[    0.834255] Creating 11 MTD partitions on "jz_sfc":
[    0.839315] 0x000000000000-0x000000040000 : "boot"
[    0.844871] 0x000000040000-0x000000240000 : "kernel"
[    0.850535] 0x000000240000-0x000000590000 : "root"
[    0.856091] 0x000000590000-0x000000630000 : "driver"
[    0.861770] 0x000000630000-0x000000ad0000 : "appfs"
[    0.867435] 0x000000ad0000-0x000000cd0000 : "backupk"
[    0.873269] 0x000000cd0000-0x000000d70000 : "backupd"
[    0.879046] 0x000000d70000-0x000000f70000 : "backupa"
[    0.884897] 0x000000f70000-0x000000fb0000 : "config"
[    0.890627] 0x000000fb0000-0x000000ff0000 : "para"
[    0.896229] 0x000000ff0000-0x000001000000 : "flag"
[    0.901718] SPI NOR MTD LOAD OK
[    0.905093] tun: Universal TUN/TAP device driver, 1.6
[    0.910330] tun: (C) 1999-2004 Max Krasnyansky 
[    0.916875] usbcore: registered new interface driver zd1201
[    0.922731] usbcore: registered new interface driver r8152
[    0.928499] usbcore: registered new interface driver usb-storage
[    0.934881] usbcore: registered new interface driver usbserial
[    0.940965] usbcore: registered new interface driver usbserial_generic
[    0.947796] usbserial: USB Serial support registered for generic
[    0.954077] usbcore: registered new interface driver ch341
[    0.959790] usbserial: USB Serial support registered for ch341-uart
[    0.966335] usbcore: registered new interface driver cp210x
[    0.972163] usbserial: USB Serial support registered for cp210x
[    0.978343] usbcore: registered new interface driver pl2303
[    0.984168] usbserial: USB Serial support registered for pl2303
[    1.491266] i8042: i8042 controller selftest timeout
[    1.496932] jzmmc_v1.2 jzmmc_v1.2.0: vmmc regulator missing
[    1.511943] jzmmc_v1.2 jzmmc_v1.2.0: card inserted, state=0
[    1.541944] jzmmc_v1.2 jzmmc_v1.2.0: register success!
[    1.547336] jzmmc_v1.2 jzmmc_v1.2.1: vmmc regulator missing
[    1.592040] jzmmc_v1.2 jzmmc_v1.2.1: register success!
[    1.597515] hidraw: raw HID events driver (C) Jiri Kosina
[    1.604481] usbcore: registered new interface driver usbhid
[    1.610258] usbhid: USB HID core driver
[    1.614535] TCP: cubic registered
[    1.617976] NET: Registered protocol family 17
[    1.623638] input: gpio-keys as /devices/platform/gpio-keys/input/input0
[    1.630784] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[    1.642925] VFS: Mounted root (squashfs filesystem) readonly on device 31:2.
[    1.650588] Freeing unused kernel memory: 212K (8052b000 - 80560000)
[    1.815192] dwc2 dwc2:  ++OTG Interrupt: A-Device Timeout Change++
[    2.595353] wait stable.[246][cgu_msc0]
[    2.599451] mmc0: new high speed SDHC card at address aaaa
[    2.608447] mmcblk0: mmc0:aaaa SB32G 29.7 GiB 
[    2.617583]  mmcblk0: p1
[    3.046953] FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
[    4.631721] RTL871X: module init start
[    4.635718] RTL871X: rtl8189es v4.3.18.3_20185.20161116_pmpinclu_mac_monitor_minMem_EDCA542B_pbyr
[    4.645001] RTL871X: build time: Oct 19 2017 11:54:52
[    4.650251] wlan power on
[    4.672392] RTL871X: module init ret=0
[    4.730180] mmc1: new SDIO card at address 0001
[    4.753227] bFWReady == _FALSE call reset 8051...
[    4.802695] RTL871X: rtw_ndev_init(wlan0) if1 mac_addr=78:11:dc:79:6e:94
[    6.562106] ==> rtl8188e_iol_efuse_patch 
[    8.225778] RTL871X: rtw_set_802_11_connect(wlan0)  fw_state=0x00000008
[    8.271036] RTL871X: start auth
[    8.285459] RTL871X: auth success, start assoc
[    8.310026] RTL871X: assoc success
[    8.320135] RTL871X: recv eapol packet
[    8.338527] RTL871X: send eapol packet
[    8.362614] RTL871X: recv eapol packet
[    8.368998] RTL871X: send eapol packet
[    8.376917] RTL871X: set pairwise key camid:4, addr:44:4e:6d:78:d8:e2, kid:0, type:AES
[    8.389761] RTL871X: set group key camid:5, addr:44:4e:6d:78:d8:e2, kid:2, type:AES
[   10.623816] request spk en gpio 63 ok!
[   10.623832] jz_codec_register: probe() successful!
[   10.631061] cgu_set_rate, parent = 860160000, rate = 2048000, n = 420, reg val = 0x000021a4
[   10.631079] cgu_enable,cgu_i2s reg val = 0x200021a4
[   10.972340] dma dma0chan24: Channel 24 have been requested.(phy id 7,type 0x06 desc a57ef000)
[   10.981600] dma dma0chan25: Channel 25 have been requested.(phy id 6,type 0x06 desc a57c6000)
[   12.035237] motor_probe743
[   12.055109] name : i2c-gpio1 nr : 1
[   12.058730] name : i2c0 nr : 0
[   12.124753] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.131893] i2c i2c-0: --I2C txabrt:
[   12.135617] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.142229] error: sensor_read,172 ret = -5
[   12.146564]  sensor_read: addr=0xa value = 0x0
[   12.151167] err sensor read addr = 0xa, value = 0x0
[   12.216580] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.223761] i2c i2c-0: --I2C txabrt:
[   12.227471] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.234087] error: sensor_read,172 ret = -5
[   12.238420]  sensor_read: addr=0x300a value = 0x0
[   12.243307] err sensor read addr = 0x300a, value = 0x0
[   12.308936] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.316082] i2c i2c-0: --I2C txabrt:
[   12.319791] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.326404] error: sensor_read,172 ret = -5
[   12.330738]  sensor_read: addr=0x300b value = 0x0
[   12.335624] err sensor read addr = 0x300b, value = 0x0
[   12.401234] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.408380] i2c i2c-0: --I2C txabrt:
[   12.412103] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.418700] error: sensor_read,172 ret = -5
[   12.423046]  sensor_read: addr=0xa value = 0x0
[   12.427650] err sensor read addr = 0xa, value = 0x0
[   12.493004] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.500136] i2c i2c-0: --I2C txabrt:
[   12.503859] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.510455] error: sensor_read,172 ret = -5
[   12.514802]  sensor_read: addr=0x580b value = 0x0
[   12.519674] err sensor read addr = 0x580b, value = 0x0
[   12.585350] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.592500] i2c i2c-0: --I2C txabrt:
[   12.596209] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.602818] error: sensor_read,172 ret = -5
[   12.607152]  sensor_read: addr=0x580b value = 0x0
[   12.612035] err sensor read addr = 0x580b, value = 0x0
[   12.677707] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.684872] i2c i2c-0: --I2C txabrt:
[   12.688580] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.695194] error: sensor_read,172 ret = -5
[   12.699529]  sensor_read: addr=0x3107 value = 0x0
[   12.704415] err sensor read addr = 0x3107, value = 0x0
[   12.770840] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.778072] i2c i2c-0: --I2C txabrt:
[   12.781878] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.788508] error: sensor_read,172 ret = -5
[   12.792856]  sensor_read: addr=0x3107 value = 0x0
[   12.797732] err sensor read addr = 0x3107, value = 0x0
[   12.863210] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.870342] i2c i2c-0: --I2C txabrt:
[   12.874064] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.880729] error: sensor_read,172 ret = -5
[   12.885162]  sensor_read: addr=0x3000 value = 0x0
[   12.890038] err sensor read addr = 0x3000, value = 0x0
[   12.955522] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   12.962668] i2c i2c-0: --I2C txabrt:
[   12.966376] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   12.972985] error: sensor_read,172 ret = -5
[   12.977320]  sensor_read: addr=0xa value = 0x0
[   12.981997] err sensor read addr = 0xa, value = 0x0
[   13.047281] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.054428] i2c i2c-0: --I2C txabrt:
[   13.058138] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.064749] error: sensor_read,172 ret = -5
[   13.069084]  sensor_read: addr=0xf0 value = 0x0
[   13.073792] err sensor read addr = 0xf0, value = 0x0
[   13.139227] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.146375] i2c i2c-0: --I2C txabrt:
[   13.150083] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.156693] error: sensor_read,172 ret = -5
[   13.161027]  sensor_read: addr=0xf0 value = 0x0
[   13.165735] err sensor read addr = 0xf0, value = 0x0
[   13.231160] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.238310] i2c i2c-0: --I2C txabrt:
[   13.242033] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.248632] error: sensor_read,172 ret = -5
[   13.252977]  sensor_read: addr=0xf0 value = 0x0
[   13.257674] err sensor read addr = 0xf0, value = 0x0
[   13.323109] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.330241] i2c i2c-0: --I2C txabrt:
[   13.333966] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.340563] error: sensor_read,172 ret = -5
[   13.344909]  sensor_read: addr=0xfc value = 0x0
[   13.349602] err sensor read addr = 0xfc, value = 0x0
[   13.415271] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.422420] i2c i2c-0: --I2C txabrt:
[   13.426130] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.432744] error: sensor_read,172 ret = -5
[   13.437080]  sensor_read: addr=0x3004 value = 0x0
[   13.441966] err sensor read addr = 0x3004, value = 0x0
[   13.508497] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.515652] i2c i2c-0: --I2C txabrt:
[   13.519360] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.525973] error: sensor_read,172 ret = -5
[   13.530307]  sensor_read: addr=0x300a value = 0x0
[   13.535192] err sensor read addr = 0x300a, value = 0x0
[   13.601703] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.608933] i2c i2c-0: --I2C txabrt:
[   13.612912] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.619516] error: sensor_read,172 ret = -5
[   13.623881]  sensor_read: addr=0x31f3 value = 0x0
[   13.628756] err sensor read addr = 0x31f3, value = 0x0
[   13.694314] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.701516] i2c i2c-0: --I2C txabrt:
[   13.705340] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.711967] error: sensor_read,172 ret = -5
[   13.716303]  sensor_read: addr=0x3107 value = 0x0
[   13.721178] err sensor read addr = 0x3107, value = 0x0
[   13.786656] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.793802] i2c i2c-0: --I2C txabrt:
[   13.797512] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.804184] error: sensor_read,172 ret = -5
[   13.808596]  sensor_read: addr=0x4 value = 0x0
[   13.813227] err sensor read addr = 0x4, value = 0x0
[   13.878420] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.885563] i2c i2c-0: --I2C txabrt:
[   13.889273] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.895884] error: sensor_read,172 ret = -5
[   13.900218]  sensor_read: addr=0xa value = 0x0
[   13.904890] err sensor read addr = 0xa, value = 0x0
[   13.970172] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   13.977318] i2c i2c-0: --I2C txabrt:
[   13.981028] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   13.987638] error: sensor_read,172 ret = -5
[   13.991986]  sensor_read: addr=0x0 value = 0x0
[   13.996589] err sensor read addr = 0x0, value = 0x0
[   14.061946] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   14.069080] i2c i2c-0: --I2C txabrt:
[   14.072807] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   14.079406] error: sensor_read,172 ret = -5
[   14.083752]  sensor_read: addr=0x300a value = 0x0
[   14.088627] err sensor read addr = 0x300a, value = 0x0
[   14.154496]  sensor_read: addr=0xa value = 0xf
[   14.159504]  sensor_read: addr=0xb value = 0x22
[   14.164224] info: success sensor find : jxf22
[   14.300781] register all isp device successfully!
[   14.308272] @@@@ tx-isp-probe ok @@@@@
[   16.453676] name : i2c-gpio1 nr : 1
[   16.457300] name : i2c0 nr : 0
[   16.718465] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   16.733950] i2c i2c-0: --I2C txabrt:
[   16.742004] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   16.762949] error: sensor_read,172 ret = -5
[   16.767289]  sensor_read: addr=0xa value = 0x0
[   16.774478] err sensor read addr = 0xa, value = 0x0
[   16.951438] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   17.041833] i2c i2c-0: --I2C txabrt:
[   17.072147] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   17.092037] error: sensor_read,172 ret = -5
[   17.096377]  sensor_read: addr=0x300a value = 0x0
[   17.122081] err sensor read addr = 0x300a, value = 0x0
[   17.309958] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   17.350890] i2c i2c-0: --I2C txabrt:
[   17.362008] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   17.368615] error: sensor_read,172 ret = -5
[   17.402001]  sensor_read: addr=0x300b value = 0x0
[   17.406885] err sensor read addr = 0x300b, value = 0x0
[   17.593055] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   17.600257] i2c i2c-0: --I2C txabrt:
[   17.604196] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   17.619150] error: sensor_read,172 ret = -5
[   17.641219]  sensor_read: addr=0xa value = 0x0
[   17.661387] err sensor read addr = 0xa, value = 0x0
[   17.839303] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   17.872032] i2c i2c-0: --I2C txabrt:
[   17.875749] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   17.898987] error: sensor_read,172 ret = -5
[   17.914037]  sensor_read: addr=0x580b value = 0x0
[   17.918922] err sensor read addr = 0x580b, value = 0x0
[   18.646834] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   18.695643] i2c i2c-0: --I2C txabrt:
[   18.713681] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   18.731827] error: sensor_read,172 ret = -5
[   18.748699]  sensor_read: addr=0x580b value = 0x0
[   18.757177] err sensor read addr = 0x580b, value = 0x0
[   18.825392] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   18.832555] i2c i2c-0: --I2C txabrt:
[   18.836267] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   18.842880] error: sensor_read,172 ret = -5
[   18.847215]  sensor_read: addr=0x3107 value = 0x0
[   18.852103] err sensor read addr = 0x3107, value = 0x0
[   18.917579] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   18.924793] i2c i2c-0: --I2C txabrt:
[   18.928585] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   18.935212] error: sensor_read,172 ret = -5
[   18.939547]  sensor_read: addr=0x3107 value = 0x0
[   18.944433] err sensor read addr = 0x3107, value = 0x0
[   19.009947] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.017100] i2c i2c-0: --I2C txabrt:
[   19.020809] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.027493] error: sensor_read,172 ret = -5
[   19.031936]  sensor_read: addr=0x3000 value = 0x0
[   19.036811] err sensor read addr = 0x3000, value = 0x0
[   19.102298] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.109429] i2c i2c-0: --I2C txabrt:
[   19.113151] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.119750] error: sensor_read,172 ret = -5
[   19.124097]  sensor_read: addr=0xa value = 0x0
[   19.128765] err sensor read addr = 0xa, value = 0x0
[   19.194064] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.201197] i2c i2c-0: --I2C txabrt:
[   19.204919] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.211517] error: sensor_read,172 ret = -5
[   19.215863]  sensor_read: addr=0xf0 value = 0x0
[   19.220558] err sensor read addr = 0xf0, value = 0x0
[   19.285987] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.293135] i2c i2c-0: --I2C txabrt:
[   19.296842] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.303454] error: sensor_read,172 ret = -5
[   19.307786]  sensor_read: addr=0xf0 value = 0x0
[   19.312490] err sensor read addr = 0xf0, value = 0x0
[   19.377912] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.385059] i2c i2c-0: --I2C txabrt:
[   19.388769] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.395378] error: sensor_read,172 ret = -5
[   19.399712]  sensor_read: addr=0xf0 value = 0x0
[   19.404416] err sensor read addr = 0xf0, value = 0x0
[   19.470071] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.477222] i2c i2c-0: --I2C txabrt:
[   19.480933] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.487544] error: sensor_read,172 ret = -5
[   19.491877]  sensor_read: addr=0xfc value = 0x0
[   19.496583] err sensor read addr = 0xfc, value = 0x0
[   19.562024] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.569158] i2c i2c-0: --I2C txabrt:
[   19.572880] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.579478] error: sensor_read,172 ret = -5
[   19.583826]  sensor_read: addr=0x3004 value = 0x0
[   19.588698] err sensor read addr = 0x3004, value = 0x0
[   19.654318] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.661527] i2c i2c-0: --I2C txabrt:
[   19.665266] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.672082] error: sensor_read,172 ret = -5
[   19.676420]  sensor_read: addr=0x300a value = 0x0
[   19.681296] err sensor read addr = 0x300a, value = 0x0
[   19.747457] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.754616] i2c i2c-0: --I2C txabrt:
[   19.758324] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.765031] error: sensor_read,172 ret = -5
[   19.769367]  sensor_read: addr=0x31f3 value = 0x0
[   19.774269] err sensor read addr = 0x31f3, value = 0x0
[   19.840125] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.847275] i2c i2c-0: --I2C txabrt:
[   19.850983] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.857594] error: sensor_read,172 ret = -5
[   19.861939]  sensor_read: addr=0x3107 value = 0x0
[   19.866866] err sensor read addr = 0x3107, value = 0x0
[   19.932609] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   19.939790] i2c i2c-0: --I2C txabrt:
[   19.943573] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   19.950174] error: sensor_read,172 ret = -5
[   19.954525]  sensor_read: addr=0x4 value = 0x0
[   19.959128] err sensor read addr = 0x4, value = 0x0
[   20.024333] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   20.031465] i2c i2c-0: --I2C txabrt:
[   20.035189] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   20.041787] error: sensor_read,172 ret = -5
[   20.046133]  sensor_read: addr=0xa value = 0x0
[   20.050796] err sensor read addr = 0xa, value = 0x0
[   20.116346] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   20.123496] i2c i2c-0: --I2C txabrt:
[   20.127207] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   20.133816] error: sensor_read,172 ret = -5
[   20.138150]  sensor_read: addr=0x0 value = 0x0
[   20.142765] err sensor read addr = 0x0, value = 0x0
[   20.208103] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[   20.215249] i2c i2c-0: --I2C txabrt:
[   20.218958] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[   20.225605] error: sensor_read,172 ret = -5
[   20.229942]  sensor_read: addr=0x300a value = 0x0
[   20.234835] err sensor read addr = 0x300a, value = 0x0
[   20.300697]  sensor_read: addr=0xa value = 0xf
[   20.305726]  sensor_read: addr=0xb value = 0x22
[   20.310429] info: success sensor find : jxf22
[   20.315050] misc sinfo_release
[   20.334319] set sensor gpio as PA-low-10bit
[   20.338667] probe ok ------->jxf22
[   20.366507] -----jxf22_detect: 432 ret = 0, v = 0x0f
[   20.366923] -----jxf22_detect: 440 ret = 0, v = 0x22
[   20.366935] jxf22 0-0040: jxf22 chip found @ 0x40 (i2c0)
[   20.372472] tx_isp: Registered sensor subdevice jxf22 0-0040
[   20.378404] do not support ctrl->cmd ====1
[   20.378421] do not support ctrl->cmd ====0
[   20.387615] do not support ctrl->cmd ====1
[   20.914390] do not support ctrl->cmd ====1
[   20.915824] jxf22 stream on
[   20.970212] ###### image_tuning_v4l2_open 4219 #######
[   20.999142] &&& chan1  scaler.max_width = 1920 max_height = 1080  min_width = 128 min_height = 128 &&&
[   21.521689] cgu_set_rate, parent = 860160000, rate = 4096000, n = 210, reg val = 0x200020d2
[   21.521713] codec_codec_ctl: set sample rate...
[   21.522821] codec_codec_ctl: set device...
[   21.922018] codec_set_device: set device: MIC...
[  123.079280] jxf22 stream off
[  123.082883] do not support ctrl->cmd ====0
[  123.089110] codec_codec_ctl: set CODEC_TURN_OFF...
[  123.671955] name : i2c-gpio1 nr : 1
[  123.682247] name : i2c0 nr : 0
[  123.801463] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  123.822139] i2c i2c-0: --I2C txabrt:
[  123.825859] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  123.840716] error: sensor_read,172 ret = -5
[  123.845864]  sensor_read: addr=0xa value = 0x0
[  123.850556] err sensor read addr = 0xa, value = 0x0
[  123.993727] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.000866] i2c i2c-0: --I2C txabrt:
[  124.022105] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.028717] error: sensor_read,172 ret = -5
[  124.035796]  sensor_read: addr=0x300a value = 0x0
[  124.040755] err sensor read addr = 0x300a, value = 0x0
[  124.184577] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.202285] i2c i2c-0: --I2C txabrt:
[  124.206005] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.221955] error: sensor_read,172 ret = -5
[  124.226465]  sensor_read: addr=0x300b value = 0x0
[  124.232119] err sensor read addr = 0x300b, value = 0x0
[  124.374220] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.381359] i2c i2c-0: --I2C txabrt:
[  124.392154] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.412129] error: sensor_read,172 ret = -5
[  124.416470]  sensor_read: addr=0xa value = 0x0
[  124.421073] err sensor read addr = 0xa, value = 0x0
[  124.537120] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.544388] i2c i2c-0: --I2C txabrt:
[  124.552225] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.570213] error: sensor_read,172 ret = -5
[  124.582132]  sensor_read: addr=0x580b value = 0x0
[  124.587014] err sensor read addr = 0x580b, value = 0x0
[  124.715912] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.732096] i2c i2c-0: --I2C txabrt:
[  124.735810] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.745990] error: sensor_read,172 ret = -5
[  124.750398]  sensor_read: addr=0x580b value = 0x0
[  124.755907] err sensor read addr = 0x580b, value = 0x0
[  124.879977] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  124.902145] i2c i2c-0: --I2C txabrt:
[  124.905866] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  124.922252] error: sensor_read,172 ret = -5
[  124.926593]  sensor_read: addr=0x3107 value = 0x0
[  124.931468] err sensor read addr = 0x3107, value = 0x0
[  125.003375] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.010603] i2c i2c-0: --I2C txabrt:
[  125.014523] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.021125] error: sensor_read,172 ret = -5
[  125.025489]  sensor_read: addr=0x3107 value = 0x0
[  125.030363] err sensor read addr = 0x3107, value = 0x0
[  125.095847] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.102995] i2c i2c-0: --I2C txabrt:
[  125.106705] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.113379] error: sensor_read,172 ret = -5
[  125.117794]  sensor_read: addr=0x3000 value = 0x0
[  125.122695] err sensor read addr = 0x3000, value = 0x0
[  125.188162] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.195307] i2c i2c-0: --I2C txabrt:
[  125.199015] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.205626] error: sensor_read,172 ret = -5
[  125.209959]  sensor_read: addr=0xa value = 0x0
[  125.214577] err sensor read addr = 0xa, value = 0x0
[  125.279911] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.287059] i2c i2c-0: --I2C txabrt:
[  125.290767] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.297378] error: sensor_read,172 ret = -5
[  125.301713]  sensor_read: addr=0xf0 value = 0x0
[  125.306421] err sensor read addr = 0xf0, value = 0x0
[  125.371958] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.379104] i2c i2c-0: --I2C txabrt:
[  125.382827] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.389427] error: sensor_read,172 ret = -5
[  125.393773]  sensor_read: addr=0xf0 value = 0x0
[  125.398466] err sensor read addr = 0xf0, value = 0x0
[  125.464020] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.471153] i2c i2c-0: --I2C txabrt:
[  125.474877] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.481475] error: sensor_read,172 ret = -5
[  125.485821]  sensor_read: addr=0xf0 value = 0x0
[  125.490515] err sensor read addr = 0xf0, value = 0x0
[  125.556183] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.563417] i2c i2c-0: --I2C txabrt:
[  125.567127] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.573900] error: sensor_read,172 ret = -5
[  125.578237]  sensor_read: addr=0xfc value = 0x0
[  125.582960] err sensor read addr = 0xfc, value = 0x0
[  125.648401] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.655549] i2c i2c-0: --I2C txabrt:
[  125.659258] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.665866] error: sensor_read,172 ret = -5
[  125.670202]  sensor_read: addr=0x3004 value = 0x0
[  125.675149] err sensor read addr = 0x3004, value = 0x0
[  125.740928] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.748081] i2c i2c-0: --I2C txabrt:
[  125.751790] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.758403] error: sensor_read,172 ret = -5
[  125.762752]  sensor_read: addr=0x300a value = 0x0
[  125.767628] err sensor read addr = 0x300a, value = 0x0
[  125.833276] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.840410] i2c i2c-0: --I2C txabrt:
[  125.844134] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.850732] error: sensor_read,172 ret = -5
[  125.855079]  sensor_read: addr=0x31f3 value = 0x0
[  125.859952] err sensor read addr = 0x31f3, value = 0x0
[  125.925513] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  125.932733] i2c i2c-0: --I2C txabrt:
[  125.936634] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  125.943270] error: sensor_read,172 ret = -5
[  125.947605]  sensor_read: addr=0x3107 value = 0x0
[  125.952496] err sensor read addr = 0x3107, value = 0x0
[  126.018008] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  126.025158] i2c i2c-0: --I2C txabrt:
[  126.028866] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  126.035548] error: sensor_read,172 ret = -5
[  126.039969]  sensor_read: addr=0x4 value = 0x0
[  126.044604] err sensor read addr = 0x4, value = 0x0
[  126.109805] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  126.116953] i2c i2c-0: --I2C txabrt:
[  126.120664] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  126.127276] error: sensor_read,172 ret = -5
[  126.131610]  sensor_read: addr=0xa value = 0x0
[  126.136286] err sensor read addr = 0xa, value = 0x0
[  126.201566] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  126.208712] i2c i2c-0: --I2C txabrt:
[  126.212515] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  126.219117] error: sensor_read,172 ret = -5
[  126.223510]  sensor_read: addr=0x0 value = 0x0
[  126.228116] err sensor read addr = 0x0, value = 0x0
[  126.293521] i2c i2c-0: i2c_jz_irq 441, I2C transfer error, ABORT interrupt
[  126.300655] i2c i2c-0: --I2C txabrt:
[  126.304383] i2c i2c-0: --I2C TXABRT[0]=I2C_TXABRT_ABRT_7B_ADDR_NOACK
[  126.310983] error: sensor_read,172 ret = -5
[  126.315331]  sensor_read: addr=0x300a value = 0x0
[  126.320207] err sensor read addr = 0x300a, value = 0x0
[  126.386090]  sensor_read: addr=0xa value = 0xf
[  126.391095]  sensor_read: addr=0xb value = 0x22
[  126.395815] info: success sensor find : jxf22
[  126.403203] misc sinfo_release
[  126.421572] set sensor gpio as PA-low-10bit
[  126.428037] probe ok ------->jxf22
[  126.453928] -----jxf22_detect: 432 ret = 0, v = 0x0f
[  126.454433] -----jxf22_detect: 440 ret = 0, v = 0x22
[  126.454447] jxf22 0-0040: jxf22 chip found @ 0x40 (i2c0)
[  126.459955] tx_isp: Registered sensor subdevice jxf22 0-0040
[  126.471395] do not support ctrl->cmd ====1
[  126.471419] do not support ctrl->cmd ====0
[  126.474951] do not support ctrl->cmd ====1
[  127.029104] do not support ctrl->cmd ====1
[  127.029939] jxf22 stream on
[  127.071570] ###### image_tuning_v4l2_open 4219 #######
[  127.099390] &&& chan1  scaler.max_width = 1920 max_height = 1080  min_width = 128 min_height = 128 &&&
[  127.641490] codec_codec_ctl: set sample rate...
[  127.642497] codec_codec_ctl: set device...
[  128.042129] codec_set_device: set device: MIC...
[  356.120288] RTL871X: recv eapol packet
[  356.171176] RTL871X: send eapol packet
[  356.176469] RTL871X: set group key camid:6, addr:44:4e:6d:78:d8:e2, kid:1, type:AES
[  956.213426] RTL871X: recv eapol packet
[  956.230796] RTL871X: send eapol packet
[  956.235004] RTL871X: set group key camid:5, addr:44:4e:6d:78:d8:e2, kid:2, type:AES
[ 1556.324451] RTL871X: recv eapol packet
[ 1556.340580] RTL871X: send eapol packet
[ 1556.345144] RTL871X: set group key camid:6, addr:44:4e:6d:78:d8:e2, kid:1, type:AES
[ 2156.418182] RTL871X: recv eapol packet
[ 2156.443111] RTL871X: send eapol packet
[ 2156.447342] RTL871X: set group key camid:5, addr:44:4e:6d:78:d8:e2, kid:2, type:AES
[ 2756.522503] RTL871X: recv eapol packet
[ 2756.564862] RTL871X: send eapol packet
[ 2756.569222] RTL871X: set group key camid:6, addr:44:4e:6d:78:d8:e2, kid:1, type:AES
Content of logcat
D/IMP-ISP (  266): ~~~~~~ IMP_ISP_Open[267] ~~~~~~~
I/NCU     (  266): NCU Debug mode:0
E/NCU     (  266): open /etc/sensor/jxf22_nd.bin failed: No such file or directory
D/System  (  266): IMP_System_Init SDK Version:3.12.0-6f2a7d4 built: Mar 20 2018 18:53:49
D/System  (  266): system_init()
D/System  (  266): Calling DSystem
D/System  (  266): Calling FrameSource
D/System  (  266): [ignored]read /proc/cpuinfo ret is NULL
D/System  (  266): Calling IVS
D/System  (  266): Calling OSD
I/Alloc Manager(  266): MEM Alloc Method is kmalloc
D/KMEM Method(  266): CMD Line Rmem Size:25165824, Addr:0x06800000
D/KMEM Method(  266): alloc->mem_alloc.method = kmalloc
D/KMEM Method(  266):           alloc->mem_alloc.vaddr = 0x757fe000
D/KMEM Method(  266):           alloc->mem_alloc.paddr = 0x06800000
D/KMEM Method(  266):           alloc->mem_alloc.length = 25165824
I/Alloc Manager(  266): MEM Manager Method is continuous
D/System  (  266): Calling Encoder
I/Encoder (  266): IMP Alloc BS Buf size:2073600
D/Encoder (  266): ispmem Size:8388608, Addr:0x06000000
I/Encoder (  266): bank-0 paddr=06000000 vaddr=74ffe000 size=7172608
I/Encoder (  266): bank-1 paddr=066d7200 vaddr=756d5200 size=1216000
D/System  (  266): Calling Decoder
D/System  (  266): Calling FB
D/Encoder (  266): channel-1 buffer malloc size=3114624 addr=0x724ea008
D/Encoder (  266): channel-0 buffer malloc size=9343872 addr=0x71902008
I/Encoder (  266): chn-0 NCU Info vaddr=74ffe000 paddr=06000000 size=1044480 backv=750fd000 backp=060ff000 outv=752fb000 outp=062fd000 total_size=5222400
D/System  (  266): system_bind(): bind DST-OSD-0(4.0.0) to SRC-Framesource-0(0.0.0)
D/System  (  266): system_bind(): bind DST-Encoder-0(1.0.0) to SRC-OSD-0(4.0.0)
D/System  (  266): system_bind(): bind DST-IVS-0(3.0.0) to SRC-Framesource-0(0.0.0)
I/Framesource(  266): [chn0]: width = 1920 height = 1080
E/VBM     (  266): VBMCreatePool()-0: w=1920 h=1080 f=842094158
E/VBM     (  266): VBMCreatePool()-0: pool->config.fmt.fmt.pix.sizeimage=3110400 sizeimage=3133440
E/VBM     (  266): VBMCreatePool()-0: sizeimage=3133440
I/VBM     (  266): PoolId:0, frame=0x71d390, frame->priv=0x71d3b8, frame[0].virAddr=7615e000, frame[0].phyAddr=7160000
I/VBM     (  266): PoolId:0, frame=0x71d3c0, frame->priv=0x71d3e8, frame[1].virAddr=7645b000, frame[1].phyAddr=745d000
I/VBM     (  266): PoolId:0, frame=0x71d3f0, frame->priv=0x71d418, frame[2].virAddr=76758000, frame[2].phyAddr=775a000
D/IVS_MOVE(  266): move->param.sense[0]=4
D/System  (  266): [ignored]read /proc/cpuinfo ret is NULL
I/ai      (  266): AI Enable: 1
I/Encoder (  266): framePriv->i_fps_num=25, framePriv->i_fps_den=1
I/ai      (  266): AI Enable Chn: 1-0
I/ai      (  266): EXIT AI Enable Chn: 1-0
I/ai      (  266): AI Set Vol: 70
I/ai      (  266): AI Get Vol: 70
I/ai      (  266): AI HPF Enable
I/ai      (  266): HPF version is: Ingenic High Pass Filter 1.1.0
I/ai      (  266): AI_EnableAec:AiDevId = 1,aiChn = 0,AoDevId = 0,aoChn = 0
I/ai      (  266): AI AEC ENABLE
I/ai      (  266): AI NS ENABLE: mode = 1
I/ai      (  266): AI HPF Enable
I/ai      (  266): HPF version is: Ingenic High Pass Filter 1.1.0
I/ai      (  266): AI_EnableAec:AiDevId = 1,aiChn = 0,AoDevId = 0,aoChn = 0
I/ai      (  266): AI AEC ENABLE
I/ai      (  266): AI NS ENABLE: mode = 1
E/ai      (  266): AI NS already enable
D/IMP-ISP ( 1460): ~~~~~~ IMP_ISP_Open[267] ~~~~~~~
I/NCU     ( 1460): NCU Debug mode:0
E/NCU     ( 1460): open /etc/sensor/jxf22_nd.bin failed: No such file or directory
D/System  ( 1460): IMP_System_Init SDK Version:3.12.0-6f2a7d4 built: Mar 20 2018 18:53:49
D/System  ( 1460): system_init()
D/System  ( 1460): Calling DSystem
D/System  ( 1460): Calling FrameSource
D/System  ( 1460): [ignored]read /proc/cpuinfo ret is NULL
D/System  ( 1460): Calling IVS
D/System  ( 1460): Calling OSD
I/Alloc Manager( 1460): MEM Alloc Method is kmalloc
D/KMEM Method( 1460): CMD Line Rmem Size:25165824, Addr:0x06800000
D/KMEM Method( 1460): alloc->mem_alloc.method = kmalloc
D/KMEM Method( 1460):           alloc->mem_alloc.vaddr = 0x75195000
D/KMEM Method( 1460):           alloc->mem_alloc.paddr = 0x06800000
D/KMEM Method( 1460):           alloc->mem_alloc.length = 25165824
I/Alloc Manager( 1460): MEM Manager Method is continuous
D/System  ( 1460): Calling Encoder
I/Encoder ( 1460): IMP Alloc BS Buf size:2073600
D/Encoder ( 1460): ispmem Size:8388608, Addr:0x06000000
I/Encoder ( 1460): bank-0 paddr=06000000 vaddr=74995000 size=7172608
I/Encoder ( 1460): bank-1 paddr=066d7200 vaddr=7506c200 size=1216000
D/System  ( 1460): Calling Decoder
D/System  ( 1460): Calling FB
D/Encoder ( 1460): channel-1 buffer malloc size=3114624 addr=0x71e81008
D/Encoder ( 1460): channel-0 buffer malloc size=9343872 addr=0x71299008
I/Encoder ( 1460): chn-0 NCU Info vaddr=74995000 paddr=06000000 size=1044480 backv=74a94000 backp=060ff000 outv=74c92000 outp=062fd000 total_size=5222400
D/System  ( 1460): system_bind(): bind DST-OSD-0(4.0.0) to SRC-Framesource-0(0.0.0)
D/System  ( 1460): system_bind(): bind DST-Encoder-0(1.0.0) to SRC-OSD-0(4.0.0)
D/System  ( 1460): system_bind(): bind DST-IVS-0(3.0.0) to SRC-Framesource-0(0.0.0)
I/Framesource( 1460): [chn0]: width = 1920 height = 1080
E/VBM     ( 1460): VBMCreatePool()-0: w=1920 h=1080 f=842094158
E/VBM     ( 1460): VBMCreatePool()-0: pool->config.fmt.fmt.pix.sizeimage=3110400 sizeimage=3133440
E/VBM     ( 1460): VBMCreatePool()-0: sizeimage=3133440
I/VBM     ( 1460): PoolId:0, frame=0x866b68, frame->priv=0x866b90, frame[0].virAddr=75af5000, frame[0].phyAddr=7160000
I/VBM     ( 1460): PoolId:0, frame=0x866b98, frame->priv=0x866bc0, frame[1].virAddr=75df2000, frame[1].phyAddr=745d000
I/VBM     ( 1460): PoolId:0, frame=0x866bc8, frame->priv=0x866bf0, frame[2].virAddr=760ef000, frame[2].phyAddr=775a000
D/IVS_MOVE( 1460): move->param.sense[0]=4
D/System  ( 1460): [ignored]read /proc/cpuinfo ret is NULL
I/ai      ( 1460): AI Enable: 1
I/Encoder ( 1460): framePriv->i_fps_num=25, framePriv->i_fps_den=1
I/ai      ( 1460): AI Enable Chn: 1-0
I/ai      ( 1460): EXIT AI Enable Chn: 1-0
I/ai      ( 1460): AI Set Vol: 70
I/ai      ( 1460): AI Get Vol: 70
I/ai      ( 1460): AI HPF Enable
I/ai      ( 1460): HPF version is: Ingenic High Pass Filter 1.1.0
I/ai      ( 1460): AI_EnableAec:AiDevId = 1,aiChn = 0,AoDevId = 0,aoChn = 0
I/ai      ( 1460): AI AEC ENABLE
I/ai      ( 1460): AI NS ENABLE: mode = 1
I/ai      ( 1460): AI HPF Enable
I/ai      ( 1460): HPF version is: Ingenic High Pass Filter 1.1.0
I/ai      ( 1460): AI_EnableAec:AiDevId = 1,aiChn = 0,AoDevId = 0,aoChn = 0
I/ai      ( 1460): AI AEC ENABLE
I/ai      ( 1460): AI NS ENABLE: mode = 1
E/ai      ( 1460): AI NS already enable
Process List
PID   USER     TIME  COMMAND
    1 root      0:01 {linuxrc} init
    2 root      0:00 [kthreadd]
    3 root      0:05 [ksoftirqd/0]
    5 root      0:00 [kworker/0:0H]
    6 root      0:00 [kworker/u2:0]
    7 root      0:12 [rcu_preempt]
    8 root      0:00 [rcu_bh]
    9 root      0:00 [rcu_sched]
   10 root      0:00 [watchdog/0]
   11 root      0:00 [khelper]
   12 root      0:00 [writeback]
   13 root      0:00 [bioset]
   14 root      0:00 [kblockd]
   15 root      0:00 [khubd]
   16 root      0:35 [kworker/0:1]
   17 root      0:00 [cfg80211]
   18 root      0:00 [rpciod]
   19 root      0:00 [kworker/0:2]
   20 root      0:00 [kswapd0]
   21 root      0:00 [fsnotify_mark]
   22 root      0:00 [nfsiod]
   23 root      0:00 [crypto]
   37 root      0:00 [kworker/u2:1]
   38 root      0:00 [deferwq]
   39 root      0:00 [kworker/0:1H]
   56 root      0:00 [mmcqd/0]
   60 root      0:00 [jffs2_gcd_mtd4]
   62 root      0:00 [jffs2_gcd_mtd7]
   64 root      0:00 [jffs2_gcd_mtd8]
   66 root      0:00 [jffs2_gcd_mtd9]
   73 root      0:00 /sbin/getty -L console 115200 vt100
   81 root      0:00 /system/sdcard/bin/busybox crond -L /system/sdcard/log/crond.log -c /system/sdcard/config/cron/crontabs
   99 root      0:47 [ksdioirqd/mmc1]
  102 root      0:28 [RTW_XMIT_THREAD]
  103 root      0:01 [RTW_CMD_THREAD]
  104 root      0:29 [RTWHALXT]
  113 root      0:00 wpa_supplicant -d -B -i wlan0 -c /system/sdcard/config/wpa_supplicant.conf -P /var/run/wpa_supplicant.pid
  150 root      0:00 udhcpc -i wlan0 -p /var/run/udhcpc.pid -b -x hostname:DAFANG
  160 root      0:00 /system/sdcard/bin/busybox ntpd -p time.google.com
  182 root      0:07 [irq/37-isp]
  194 root      0:00 /system/sdcard/bin/dropbearmulti dropbear -R
  198 root      2:55 /system/sdcard/bin/lighttpd.bin -f /system/sdcard/config/lighttpd.conf
  218 root      0:02 {mqtt-status-int} /bin/sh /system/sdcard/scripts/mqtt-status-interval.sh
  221 root      0:01 /system/sdcard/bin/autonight
  352 root      0:00 {mqtt-control.sh} /bin/sh /system/sdcard/scripts/mqtt-control.sh
  521 root      0:00 /system/sdcard/bin/mosquitto_sub.bin -v -h 192.168.2.11 -p 1883 -u mqtt -P ieVee3eib0ooquee -t dafang_vorplatz/# -t myhome/set
  522 root      0:14 {mqtt-control.sh} /bin/sh /system/sdcard/scripts/mqtt-control.sh
 1460 root     40:16 /system/sdcard/bin/v4l2rtspserver-master -W1920 -H1080 -E MP3:16000:44100 -r 2 -F 25 -P 8554
 1541 root      1:56 [apical_isp_fw_p]
18341 root      0:00 sleep 30
18376 root      0:00 /bin/sh /system/sdcard/www/cgi-bin/action.cgi
18390 root      0:00 ps
Mounts
 rootfs on / type rootfs (rw)
/dev/root on / type squashfs (ro,relatime)
tmpfs on /dev type tmpfs (rw,relatime)
proc on /proc type proc (rw,relatime)
devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /tmp type tmpfs (rw,relatime)
tmpfs on /run type tmpfs (rw,nosuid,nodev,relatime,mode=755)
sysfs on /sys type sysfs (rw,relatime)
media on /media type tmpfs (rw,relatime)
/dev/mtdblock3 on /driver type squashfs (ro,relatime)
/dev/mtdblock4 on /system type jffs2 (rw,relatime)
/dev/mtdblock7 on /backupa type jffs2 (rw,relatime)
/dev/mtdblock8 on /configs type jffs2 (rw,relatime)
/dev/mtdblock9 on /params type jffs2 (rw,relatime)
/dev/mmcblk0p1 on /system/sdcard type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/mmcblk0p1 on /bin/busybox type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/mmcblk0p1 on /root type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)
/dev/mmcblk0p1 on /etc type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=iso8859-1,shortname=mixed,errors=remount-ro)

Hotfix

Add two single quotes at line 3 in file /system/sdcard/config/autonight.conf.

Example: Before:

autonight_mode=sw
hw_parameters=
sw_parameters=-S -j 3 -w 3 -1 1200000 -2 930000,14,10 -3 3000,17,8
# set ir_led_off to true in front of IR reflecting windows
ir_led_off=false

After:

autonight_mode=sw
hw_parameters=
sw_parameters='-S -j 3 -w 3 -1 1200000 -2 930000,14,10 -3 3000,17,8'
# set ir_led_off to true in front of IR reflecting windows
ir_led_off=false
jmtatsch commented 4 years ago

Sdcard is corrupted. FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Is your sd card written through? Is you power supply strong enough?

0n3-70uch commented 4 years ago

Sdcard is corrupted. FAT-fs (mmcblk0p1): Volume was not properly unmounted. Some data may be corrupt. Is your sd card written through? Is you power supply strong enough?

Hi, thanks for your reply. Is it possible, that this is an old message? Because it's there after every reboot at the same time ([ 3.046953]). I checked the power supply now... seems to be fine. Brand power supply with 2A. I measured the current and the consumption is under 2A all the time.

0n3-70uch commented 4 years ago

Update: I low level formated the card. Now the "corrupted" message is gone away. I will update the issue tomorrow after one night.

0n3-70uch commented 4 years ago

Update 2: This problem still exists. Switching between day and night does not work.

jmtatsch commented 4 years ago

Well then run autonight in debug mode with and without the page open and post the logs.

0n3-70uch commented 4 years ago

Well then run autonight in debug mode with and without the page open and post the logs.

Ok I will do it.

0n3-70uch commented 4 years ago

I can't find an option to enable debugging for auto-night-detection. Can you give me a short tip? Thank you.

PS: I get this error... /system/sdcard/controlscripts/auto-night-detection: /system/sdcard/config/autonight.conf: line 3: -j: not found

jmtatsch commented 4 years ago

Seen that error before. Was because the argument string wasn’t properly passed on to the executable. This was fixed some commits ago. To see all modes supported by autnonight run the executable with flag -h.

0n3-70uch commented 4 years ago

Seen that error before. Was because the argument string wasn’t properly passed on to the executable. This was fixed some commits ago. To see all modes supported by autnonight run the executable with flag -h.

But it still exist in the current commit 74256f7.

There is now response to -h. Seems that I do something wrong...

alagarath commented 4 years ago

I'm not sure if it is related to this but I'm seeing where changes saved to the SW night mode configuration in the webui are being saved to the configuration file but those changes aren't reflected in the webui after a page refresh or camera reboot. The camera appears to ignore the configuration file modifications after a reboot but the webui still contains the default values and won't switch to night mode until visiting the SW night page once. But it still only appears to use the defaults.

0n3-70uch commented 4 years ago

Yeah I notice the same problem.

jmtatsch commented 4 years ago
./autonight -h
Usage: autonight [options]

Options:
-v              Increase verbosity
-S              uses software to determine day/night
                    following options don't mean anything for software method
                    use sw_night_configure.html for more software mode options
-D <str>        Sets jz_adc_aux device (default: /dev/jz_adc_aux_0)
-c <str>        Sets the command to call to set night mode (default: /system/sdcard/scripts/nightmode.sh)
-a <int>        Sets the number of ADC reads to average into a single sample (default: 25)
-d <int>        Delay (in seconds) between averaged reads (default: 10)
-n <int>        Number of averaged samples to window average for thresholding (default: 5)
-O <float>      Turn on night mode when window average value drops below this threshold (default: 40.00)
-F <floag>      Turn off night mode when window average value goes above this threshold (default: 45.00)
-h              Print this usage statement and exit
0n3-70uch commented 4 years ago

Thanks for your help. But I'm to stupid to find the ./autonight tool. I connect via ssh to my camera. But there is only one auto night file: /controlscripts/auto-night-detection

And I can't find the debug mode in your description. Or is there a running output to the terminal after executing the command?

jmtatsch commented 4 years ago

the binary is in /system/sdcard/bin you have to start it like this ./autonight -v to output debug more debug information

0n3-70uch commented 4 years ago

the binary is in /system/sdcard/bin you have to start it like this ./autonight -v to output debug more debug information

Oh man... sometimes I'm inside a forest and cannot see the trees ;-). Thank you.

0n3-70uch commented 4 years ago

This is my output for ./autonight -v -S -j 3 -w 3 -1 1200000 -2 930000,14,10 -3 300 0,17,8:

Starting software method using 
jitter_percent = 3
eq1_user_exposure = 1200000
eq2_user_exposure = 930000
eq2_user_iridix = 14
eq2_count = 10
eq3_user_wb = 3000
eq3_user_iridix = 17
eq3_count = 8
sec_wait = 3
Night Mode Disabled
jitter active
mode switch wait active
mode switch wait active
mode switch wait active
Switching to night new exp=1266819
Night Mode Enabled
/system/sdcard/scripts/nightmode.sh: /system/sdcard/config/autonight.conf: line 3: -j: not found
jitter active
mode switch wait active
mode switch wait active
mode switch wait active

Same problem... will not switch automatically.

jmtatsch commented 4 years ago

show your /system/sdcard/config/autonight.conf

0n3-70uch commented 4 years ago

/system/sdcard/config/autonight.conf

Stock settings.

autonight_mode=sw
hw_parameters=
sw_parameters=-S -j 3 -w 3 -1 1200000 -2 930000,14,10 -3 3000,17,8
# set ir_led_off to true in front of IR reflecting windows
ir_led_off=false
Dopeyr commented 4 years ago

Not quite stock settings: https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/blob/master/firmware_mod/config/autonight.conf.dist has single quotes around sw_parameters value.

I think this is an issue with rewrite_config function, which is maybe stripping these?

jmtatsch commented 4 years ago

Okay i was able to trace that error: /system/sdcard/scripts/nightmode.sh: /system/sdcard/config/autonight.conf: line 3: -j: not found It happens because right value of the variable sw_parameters is broken up after the -S and the rest is lost (again) when sourcing the config in night_mode on in common_functions. As @Dopeyr pointed out, the culprit may be the rewrite_config function. Any regex experts here that could help with a better rewrite_config function?

jmtatsch commented 4 years ago

I verified that the stock config file is working as intended. Rewriting with sw night configuration removes the quotation marks and breaks the functionality.

0n3-70uch commented 4 years ago

I verified that the stock config file is working as intended. Rewriting with sw night configuration removes the quotation marks and breaks the functionality.

Ah great... thanks for your investigation.

Dopeyr commented 4 years ago

One thing to bear in mind, there are points in action.cgi where it looks like it's doing its own escaping e.g. https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/blob/master/firmware_mod/www/cgi-bin/action.cgi#L392 so just need to take that into account. Perhaps with a fixed up rewrite_config that could be removed? Just needs checking anyway.

0n3-70uch commented 4 years ago

I added the two single quotes and now the auto night detection works again.

PS: I added a detailed description above: https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/issues/1301#issue-574135324

alagarath commented 4 years ago

I added the two single quotes and now the auto night detection works again.

Not quite stock settings: https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/blob/master/firmware_mod/config/autonight.conf.dist has single quotes around sw_parameters value.

I think this is an issue with rewrite_config function, which is maybe stripping these?

Good eye! I just made the modification to my configuration and I'm back in business. Thanks everyone!

foet14 commented 4 years ago

it solved my problem too , thanks

0n3-70uch commented 4 years ago

I added a detailed description above: https://github.com/EliasKotlyar/Xiaomi-Dafang-Hacks/issues/1301#issue-574135324

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.