• 10 dec 2017: forum version update. In case of issues use this topic.
  • 30 nov 2017: pilight moved servers. In case of issues use this topic.
Hello There, Guest! Login Register

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[v6.0 > v7.0] Errors with the latest nightly
Don't know how to get it from here into "Errors with the latest nightlies"

In the meantime i did fix the compilation issue and i think the ev1527 related commits are also okay. But the problem is getting more difficult to grasp.

Using the most recent development commit, the values were updated but than pilight crashed with the following entries in pilight.err:
[                      ] pilight-daemon: ERROR: config gui element #23 "THS7Bad", device not configured
[                      ] pilight-daemon: ERROR: config is not in a valid json format
[                      ] pilight-daemon: -- STACKTRACE (3 FRAMES) --
[              Dy▒p▒▒▒v] pilight-daemon: __default_sa_restorer_v2       ip = 0x76bbab20, sp = 0x70967968
[      Dy▒p▒▒▒v8
▒v4w▒p] pilight-daemon: realloc                        ip = 0x76c00c38, sp = 0x70967c58
The config.json file is valid (i always copy a backup copy to config.json before starting pilight).

With that release the pilight process termiantes itself silently ...

I am pretty sure that the problem is not caused by faulty hardware, as the problem started to appear on my pi_b_23_8 (pi model b with ip address 23 and 8GB SD card) even before i decided to upgrade that machine to Kernel 3.18.

I am currently testing on my pi2_65_16 (pi model 2 with ip address 65 and 16GB SD card). I setup that machine from scratch using a blank new SD card and a fresh raspbian image. No files were directly copied between both machines, except the config.json file which was transferred using COPY / PASTE.
Can you run in gdb until it crashes.
The longer i am chasing the issue the more i come to the conclusion that it is a memory overwrite
The problem is caused by tfaCheckValues.
There is no error check for the offset values of temperature and humidity.
- json_find_number(jvalues, "temperature-offset", &snode->temp);
- json_find_number(jvalues, "humidity-offset", &snode->humi);
Depending on the random values this leads to various problems during program execution.

As a workaround:
- it is currently mandatory and not optional to define temperature-offset and humidity-offset for tfa devices in config.json:
"temperature-offset": 0,
"humidity-offset": 0,
I updated the protocol. Can you try again?
libpilight.so: undefined reference to `CloseHandle'
libpilight.so: undefined reference to `WriteFile'
Those are Windows handlers. Have to embed them in defines. Done.
Did some testing and the theory matches reality - okay.
I have briefly revisited the following modules:
settings structures in libs/config
- devices.c
- gui.c
- settings.c
Not sure if changes are required.

Protocol structures in libs/protocols:
Will do the changes and issue a pull request until tomorrow for:
- auriol.c
required: snode->temp =0;
- ninjablocks_weather.c
required: snode->temp =0;
required: snode->humi =0;
- alecto_ws1700.c
required: snode->temp =0;
required: snode->humi =0;
- alecto_wx500.c
required: snode->temp =0;
required: snode->humi =0;
- alecto_wsd17.c
required: snode->temp =0;
- teknihall.c
required: snode->temp =0;
required: snode->humi =0;
Does this confirm the issue is the protocol settings default value (snode->temp) or was it a memory overflow in on of my last commits.

@wo_rasp, can you also please test the pilight usb nano solution to see if protocols such as ninjablocks or quiqq will work?

Updated first post!
Yes it does, uninitialized settings, leading to undefined values after malloc, caused the problem (indirectly in particular in combination with printf it can cause a memory conflict).

Will combine the aforementioned files from the protocols branch in a single pull request using branch v6_protocols_01 (would appreciate if you could do the three files from the configs branch).

Testing pilight usb nano: Need to get an Arduino USB - just ordered one, will arrive on Friday.

Possibly Related Threads...
Thread Author Replies Views Last Post
  Nightly versions less than 8.1.5-59 missing? felfert 4 253 07-28-2020, 07:50 PM
Last Post: felfert
  stable/nightly Release is no longer signed DSLeX 1 562 05-14-2020, 01:09 PM
Last Post: peteratoce
  MQTT cannot be disabled on nightly image ayeyebrazov 5 498 05-01-2020, 03:11 PM
Last Post: ayeyebrazov
  hardware module issues in nightly apartmedia 17 3,248 04-05-2019, 06:59 PM
Last Post: curlymo
  Update to v8.0.10-nightly-a1279212 Ulrich.Arnold 3 1,866 06-04-2018, 08:31 PM
Last Post: curlymo
  Updates for nightly Ulrich.Arnold 1 935 01-26-2018, 07:31 PM
Last Post: curlymo
  how to complete remove nightly terrar 8 6,385 04-03-2016, 07:04 PM
Last Post: mvasi90
  new install fails - dev/nightly gneandr 11 11,115 01-29-2016, 11:30 AM
Last Post: WEBcast
  pilight7 from Stable --> Nightly gneandr 10 4,427 01-19-2016, 04:15 PM
Last Post: gneandr
  [v7.0 > v...] Errors with the latest nightly curlymo 20 8,535 07-27-2015, 02:37 PM
Last Post: diman87

Forum Jump:

Browsing: 1 Guest(s)