Hi TIMAI2 I am working with Bernon on this project and these are the blocks for all the clocks used in these project which start immediately after connecting to the AI Companion
Clock 1 is set to 60000ms
Clock 2 is set to 1000ms
Clock 3 is set to 60000ms
For most situations, you should only start a clock timer when you need to run it, that is, it is started by some user action (clicking a button, etc.)
There are occasions where you may want the clock timer to start with the app, for example, to start a counter to assess elapsed time. But I do not believe this is one of those occasions
Untick TimerEnabled in the Designer for all your clocks:
You can then start and stop them, as required, using the timer enabled block:
Ah but it needs to be running when the app is opened as the function is to display the current time, and when the user sets a reminder, it compares the user set time to the current time. Firing the BLE command if the two times are equal. The problem lies as when the BLE command fires, it somehow affects the shorts received block. I will try to add an if statement to make sure the shorts received block does not fire randomly.
But when i send an uint32_t of 1 to mit app,
I receive a weird () as the int and it does not fulfill the if statement. Do y'all know why this happens ?
I think it may have something to do with the fact that the characteristic that it writes into is the same characteristic that MIT APP uses for another function (writing PillData), i will try to create a new characteristic for this SMS function so that there will be no interference, however i remember trying something like this in the past, will try again after dinner haha
Thanks for the help abg!!, i have turned the JSON list setting on and after abit more testing and creating a new characteristic for it . I have sucessfully sent the SMS at the correct time i want it to. I think the error was due to me having tried to make 1 characteristic have two functions that interfered with one another.