These are chat archives for SmingHub/Sming

14th
Jan 2016
Piotr Dobrowolski
@Informatic
Jan 14 2016 10:19
Hmmm... Seems like MQTT client does not send PINGs when it receives messages... I have a simple app which connects to network and subscribes to some topic, and on my local machine i just send some message to that topic every 1 or 5 seconds, after 20-something seconds Mosquitto drops the connection with "Client ... has exceeded timeout, disconnecting." message.
Or maybe I just don't understand MQTT protocol, but what i know - Mosquitto drops the connection in such case, and does not, when there is no traffic on the topic Sming is subscribed to ;) I'll try to debug it some day.
Piotr Dobrowolski
@Informatic
Jan 14 2016 10:33
Ok, now I see it. MQTT client is supposed to send any message in keepalive period - MqttClient::onReadyToSendDatahowever checks sleep > 10, which is reset to 0 in TcpConnection::staticOnReceive as well as TcpConnection::staticOnSent... There goes another issue. :)
Piotr Dobrowolski
@Informatic
Jan 14 2016 10:40
And there goes #549.
Piotr Dobrowolski
@Informatic
Jan 14 2016 11:00
I also submited waiting patch for my previous issue, feel free to reject it :P
robotiko
@robotiko
Jan 14 2016 11:43
Thanks
Informatic.. For submitting the issue
laurentppol
@laurentppol
Jan 14 2016 15:47
is there some difference between Sming for Linux (files dated 24.10) and current Sming for Windoze?
My app compiles on Linux, but not on Win on someone's else machine,
error is: "in file included from application.cpp, app/appSettings (coming from HttpServer_ConfigNetwork) : in member function "void ApplicationSettingsStorage::load()" error, class ArduinoJson::JsonObjectSubscript<const char*> has no member named toString"
and many more, related to ArduinoJson
hreintke
@hreintke
Jan 14 2016 15:51
@laurentppol : The difference is the Sming version. 24/10 -> 1.4.0, now 2.1.0
See releasenotes for difference.
laurentppol
@laurentppol
Jan 14 2016 15:53
is it still possible to download 1.4.0 for Win? And can I download releasenotes from Linux?
laurentppol
@laurentppol
Jan 14 2016 15:59
don't see releasenotes on SmingHub :(
Piotr Dobrowolski
@Informatic
Jan 14 2016 16:01
laurentppol
@laurentppol
Jan 14 2016 16:07
ok, I can see "ArduinoJson" version change, but what should I change in my program? (I use some code from HttpServer_ConfigNetwork)
hreintke
@hreintke
Jan 14 2016 16:20
@laurentppol : If your failing code comes from the HttpServer_ConfigNetwork example you can check the difference between the 1.4 and 2.1 version in there
laurentppol
@laurentppol
Jan 14 2016 16:30
for now I think I want just to build 1.4 on Win. Simply download/unzip/make? (removing/moving 2.1)
as I don't really understand the Json code...
or there is *.exe installer somewhere?
hreintke
@hreintke
Jan 14 2016 16:33
No, but that is not available for any sming version at this moment.
providing that is still work in progress
laurentppol
@laurentppol
Jan 14 2016 16:36
ok, so how to get working 1.4 on Win?
hreintke
@hreintke
Jan 14 2016 16:39
the same as any sming version but beware on the espressif sdk versions. Sming 1.4 only works with 1.3.0 and below
laurentppol
@laurentppol
Jan 14 2016 16:42
"Windows manual install"? On Linux I have SDK 1.4.0
hreintke
@hreintke
Jan 14 2016 16:44
Please use the install guide from the repo
and indeed, when you use the install guide from now, you will get sdk 1.5.0
so if you want sdk1.3.0 you need to go to espressif site and download there
laurentppol
@laurentppol
Jan 14 2016 16:54
You mean from Wiki? "Windows manual install"? as I don't see any "install*" in tarball.
hreintke
@hreintke
Jan 14 2016 16:56
yes wiki, but as I said, that will install espressif sdk 1.5. moving from there to 1.3.0 is a non documented action
laurentppol
@laurentppol
Jan 14 2016 16:59
thx, looks easier than modify code to adapt to new Sming.
hreintke
@hreintke
Jan 14 2016 17:00
but modifying code for new sming gives you new features and support
and staying on old you keep the bugs, and on json there are serious json memory leaks
laurentppol
@laurentppol
Jan 14 2016 17:17
as I said: "for now", as I don't understand code related to Json. And Json is used for only fraction of app's life: in WiFi config, which normally happens once. And once every startup.
hreintke
@hreintke
Jan 14 2016 17:17
ok, all up to you :smile:
0xPIT
@0xPIT
Jan 14 2016 17:54
Hello. So is there active work on a RTOS SDK variant?
alonewolfx2
@alonewolfx2
Jan 14 2016 18:04
@0xPIT now @hreintke @raburton and i working on rtos for stable port of sming
robotiko
@robotiko
Jan 14 2016 18:07
hey @alonewolfx2 .. mainly @hreintke @raburton and you
:D
alonewolfx2
@alonewolfx2
Jan 14 2016 18:09
shit. i am on mobile and i wrote @raburton but t9 changed it :D
0xPIT
@0xPIT
Jan 14 2016 18:09
cool.
alonewolfx2
@alonewolfx2
Jan 14 2016 18:42
@hreintke are you here
hreintke
@hreintke
Jan 14 2016 19:42
@alonewolfx2 : yes I am in now
hreintke
@hreintke
Jan 14 2016 19:48
@raburton : I pushed bugfix for hardwarePWM and basic_hwpwn example to Sming_RTOS
Testing with @robotiko showed a more stable pwm than on nonos.
Maybe you should give it at try whether is solves your pwm issues
alonewolfx2
@alonewolfx2
Jan 14 2016 19:51
LD out/build/app.out
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::get_status()':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::print_status(unsigned char)':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::print_byte_register(char const*, unsigned char, unsigned char)':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o):C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: more undefined references to `os_printf_plus(char const*, ...)' follow
collect2.exe: error: ld returned 1 exit status
make: *** [out/build/app.out] Error 1

20:43:38 Build Finished (took 2s.341ms)
i have this one
hreintke
@hreintke
Jan 14 2016 19:57
wait, I check
hreintke
@hreintke
Jan 14 2016 20:13
I think it is coming from FAKE_PGMSPACE
robotiko
@robotiko
Jan 14 2016 20:13
@raburton I tested the HW_PWM that @hreintke just released. The basic example has perfect timing and no issues .. apart from the known issue that cannot reach 100% duty cycle 9x.x % but not 100%
hreintke
@hreintke
Jan 14 2016 20:16
line 90 : #define printf_P(f, ...) os_printf_plus((f), ##__VA_ARGS__)
alonewolfx2
@alonewolfx2
Jan 14 2016 20:18
@hreintke how can i fix it_
hreintke
@hreintke
Jan 14 2016 20:20
can you try with #define printf_P(f, ...) printf((f), ##__VA_ARGS__)
alonewolfx2
@alonewolfx2
Jan 14 2016 20:21
in where?
hreintke
@hreintke
Jan 14 2016 20:22
FAKE_PGMSPACE.h line 90
alonewolfx2
@alonewolfx2
Jan 14 2016 20:23
C+ libraries/RF24/RF24.cpp
libraries/RF24/RF24.cpp:12:0: error: "printf_P" redefined [-Werror]
 #define printf_P(f, ...) printf((f), ##__VA_ARGS__)
hreintke
@hreintke
Jan 14 2016 20:25
did you cange the line or added the line ?
alonewolfx2
@alonewolfx2
Jan 14 2016 20:44
@hreintke i changed that line but seems i have first issue again
22:43:24 **** Build of configuration Sming for project Radio_nRF24L01 ****
make all 
C+ app/application.cpp
AR out/build/app_app.a
LD out/build/app.out
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::get_status()':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::print_status(unsigned char)':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o): In function `RF24::print_byte_register(char const*, unsigned char, unsigned char)':
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: undefined reference to `os_printf_plus(char const*, ...)'
c:/tools/Sming_RTOS_POC-master/sming/compiler/lib/\libsming.a(RF24.o):C:\tools\Sming_RTOS_POC-master\sming/libraries/RF24/RF24.cpp:988: more undefined references to `os_printf_plus(char const*, ...)' follow
collect2.exe: error: ld returned 1 exit status
make: *** [out/build/app.out] Error 1
i cleaned libsming and rebuild
cleaned example and rebuild
hreintke
@hreintke
Jan 14 2016 20:47
do you have a fork of sming_rtos_poc with a branch of your work on this
alonewolfx2
@alonewolfx2
Jan 14 2016 20:48
no. just local branch
how can i put into github or i can send you a zip file
hreintke
@hreintke
Jan 14 2016 20:50
prefer github then I just can pull it from there (I think)
hreintke
@hreintke
Jan 14 2016 21:00
can you one more try before this ?
same file line 67 change os_printf_plus in printf
int __result = os_printf_plus(__localF, ##__VA_ARGS__); \
alonewolfx2
@alonewolfx2
Jan 14 2016 21:05
i push it
hreintke
@hreintke
Jan 14 2016 21:06
can you give try on what I showed above ?
alonewolfx2
@alonewolfx2
Jan 14 2016 21:06
ok
same fakememspaceh
?
hreintke
@hreintke
Jan 14 2016 21:06
yes
alonewolfx2
@alonewolfx2
Jan 14 2016 21:12
seems compiling
hreintke
@hreintke
Jan 14 2016 21:18
ok
In sming_rtos I tried to get rid of all those different printf's scattered thru the code