Correct usage of "event.subscribe('sms.received',..)"?


I am currently working on a python script that receives SMS messages via the hologram cloud.

What is the correct way to use “event.subscribe(‘sms.received’,…)”?

Looking at the SDK source code, I see that the event get’s triggered as part of hologram.enableSMS() function.
I also see that hologram.disableSMS() actually points back to hologram.enableSMS()??

With that I am thinking about creating a loop that calls hologram.enableSMS() and this should trigger the sms.received event once an SMS is received.

Is that the correct way? What pause should I use between hologram.enableSMS() calls?


To be honest, I’m not totally sure if that’s fully implemented right now. If you look at the code for the hologram receive --sms command, it just polls AT+CMGL every second or so.