Esp8266EasyIoTMsg max structures numbers

9 years 6 months ago - 9 years 6 months ago #1339 by cdj
I try to start a new topic related to my easyrelaymod :

Hi again, I'm experiencing problems defining 4 different Esp8266EasyIoTMsg structures.

With just two of them it works flawlessly; I can send messages and update state as expected. As soon as I add even a third Esp8266EasyIoTMsg console output starts to get garbled.

Is there any limit on the number of Esp8266EasyIoTMsg I can use? The sketch size does not seem to be the problem.

Thanks in advance for your help

EDIT: I've seen that in thermostat sketch you call Esp8266EasyIoTMsg lots of time... but it runs on an Arduino Mega... could it be a cpu related problem ? I'm using an Arduino Nano.

Please Log in or Create an account to join the conversation.

9 years 6 months ago #1384 by EasyIoT

cdj wrote: I try to start a new topic related to my easyrelaymod :

Hi again, I'm experiencing problems defining 4 different Esp8266EasyIoTMsg structures.

With just two of them it works flawlessly; I can send messages and update state as expected. As soon as I add even a third Esp8266EasyIoTMsg console output starts to get garbled.

Is there any limit on the number of Esp8266EasyIoTMsg I can use? The sketch size does not seem to be the problem.

Thanks in advance for your help

EDIT: I've seen that in thermostat sketch you call Esp8266EasyIoTMsg lots of time... but it runs on an Arduino Mega... could it be a cpu related problem ? I'm using an Arduino Nano.


Yes, in my case I'm using Arduino mega and 5 switches. Maybe there is problem with RAM size. Also try to increase serial buffer size in SoftwareSerial library. Sometimes there's not enough RAM. Try also to disable DEBUG. It consumes additional RAM.
The following user(s) said Thank You: cdj

Please Log in or Create an account to join the conversation.

9 years 6 months ago #1419 by cdj
Bad News,
Increased softwareserial buffer to 128.
Esp8266 EasyIoT driver debug disabled.
Same result.
When i uncomment third line of :
Esp8266EasyIoTMsg msgRelay1(1, V_DIGITAL_VALUE);
Esp8266EasyIoTMsg msgRelay2(2, V_DIGITAL_VALUE);
//Esp8266EasyIoTMsg msgRelay3(3, V_DIGITAL_VALUE);
//Esp8266EasyIoTMsg msgRelay4(4, V_DIGITAL_VALUE);
It start to work badly...

Is there some another way to change state of switches? for example calling "ControlOn" url via api inside arduino code?

Please Log in or Create an account to join the conversation.

9 years 6 months ago #1469 by EasyIoT

cdj wrote: Bad News,
Increased softwareserial buffer to 128.
Esp8266 EasyIoT driver debug disabled.
Same result.
When i uncomment third line of :

Esp8266EasyIoTMsg msgRelay1(1, V_DIGITAL_VALUE);
Esp8266EasyIoTMsg msgRelay2(2, V_DIGITAL_VALUE);
//Esp8266EasyIoTMsg msgRelay3(3, V_DIGITAL_VALUE);
//Esp8266EasyIoTMsg msgRelay4(4, V_DIGITAL_VALUE);
It start to work badly...

Is there some another way to change state of switches? for example calling "ControlOn" url via api inside arduino code?


You can extend this example:
iot-playground.com/2-uncategorised/40-es...y-switch-arduino-ide

Please Log in or Create an account to join the conversation.

9 years 6 months ago #1472 by cdj
No man, i need Arduino because there are 4 input sensors that tell me if you turn on the light by physical switches. Please tell me if there's other way to change an easyiot switch state from Arduino....
Thanks
Dario

Please Log in or Create an account to join the conversation.

9 years 6 months ago #1519 by cdj
AND FINALLY I DID !!!!!! INCREDIBLE !!!

I call Esp8266EasyIoTMsg only when i need and not in declaration. Mr. EasyIOT it works... it's not necessary to put it in declaration... also in the middle of code it works !)

Great ! really happy ! Believe me after months of frustrating time spent, this is fantastic !!!

Please Log in or Create an account to join the conversation.

Time to create page: 0.277 seconds

Forum latest

  • No posts to display.