Hey everybody,
#working code / answer:
#original thoughts:
I want to get the CallerID when somebody calls my electron. I definitly need a different Sim card for this, thats for sure.
The AT Command I need for that is:
AT+UCALLSTAT
which needs to be enabled (I do not know the default setting)
when a call occurs that it is giving me back the caller ID in this format:
+UCALLSTAT: <call_id>,<stat>
So far so good.
Now I want to determine what would be the best option for recognizing a call.
In another Thread they spoke about the PB12 pin which is connected to the āalertā pin (or so) of the ublox which I guess should trigger when a SMS or Call is coming in.
PD12 is not brought out to the standard D/A Pins. So I canāt set an Interrupt on them using the normal firmware (or can I?)
#what I need:
how to enable the Interrupt on PB12 on an Electron.
Or is anyone else thinking polling the Serial line is a better solution?
I might need that anyways because the +UCALLSTAT might occur earlier that the ISPā¦
Thanks for your help!
Project Idea: check if phone number is inside a local(/online) ādatabaseā and only if yes then toggle a relay. If not maybe send him a SMS for further instructions.
#EDIT:
The Datasheet says that the STM32 is supporting up to 140 interrupt able pins⦠So the chances are goodā¦
Edit 2: the alternate Function name of this pin is TIM1_BKIN
Timer 1⦠BK(?)Input sounds goodā¦
EDIT3:
from reference manual:
6.3.8 External interrupt/wakeup lines
All ports have external interrupt capability. To use external interrupt lines, the port must be configured in input mode, refer to Section 8.2: External interrupt/event controller (EXTI) and Section 8.2.3: Wakeup event management.
EDIT4:
So I need to ORRS [0, =0x14] , =0x1
ā thatās Assembler⦠and how to do this with Cā¦?