Activating cloud functions before setup() finishes

Hi,

I read this on the docs:

When using the default AUTOMATIC system mode, the cloud functions must be
registered in the setup() function. The information about registered functions 
will be sent to the cloud when the setup() function has finished its execution. 

Is there an alternate way to send the info about registered functions to the cloud mid-way on the setup() execution?

Thanks!

No. Cloud function registration only happens after loop runs.

The best way to solve this is to put the setup code that requires working cloud functions and subscriptions in loop protected by a flag that only runs once. A finite state machine may be even better.

2 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.