Hello , i m trying to see my spark variables and functions . I have used the login example. Login is no problem and also connecting to the core is no problem .But in the log i see
No problem to connect with the core but the variables and functions?
I don’t know why they are undefined.
Wenn I check these cloud variables and functions with SPARK DEV, I have no problem checking them, I can read the variable and send arguments into the function with a result.
There are some problems with the SparkJS library, as far as browser usage goes, some of which are noted in this thread. I’ve tried to rewrite your code in a way that it produces similar results to what is required. It’s probably not perfect, but it’ll get the job done;
Depending on what you want to make, you could take a look at this: http://jordymoors.nl/interface It’ll show you your exposed functions/variables and will allow you to query them. Let me know if you need any further help, and I’ll give it a try.
@Moors7 I tried your code to get the functions defined on my particle. It is not undefined anymore but in the console the name is blank. Do you have any idea why it is just blank?
Sorry for the late reply, it’s been a busy couple of days. If you could explain a bit further on what exactly isn’t working, and maybe provide some screenshots, I might be able to help.
I don't really understand that, since you shouldn't need particle.publish() to use a particle.function(). Also, the code I posted above does nothing with publishes, so that appears to be unrelated. Would you mind clarifying this some more so other can benefit from this in the future? Thanks in advance!