If I delay 1 millisecond in the loop I am able to change the status of the pin (when it detects a certain beacon) however it resets if I try delaying in between the status change.
If I dont delay in the loop it doesnt reset but it doesnt change the status.
Now, I tried turning off promiscuous mode before I change the status but it doesnt help.
Bottom line, I need the delay in the loop for the status to change but I cant have two delays, in the loop and in the promiscuous callback.
Any suggestions will be greatly appreciated.
Thanks