PIC Microcontroller with GSM module - microcontroller

How do I get a caller identity from sim900 using pic16f877A microcontroller meanwhile, I can make call, send SMS and answer calls but I want to be able to compare an incoming call identity with a predefined on in my program. My compiler if Mikroc. Thanks

You need to give AT+CLIP=1\r command to enable additional caller information.
Once you issue this command, any incoming call will be notified in the following format,
RING
+CLIP:+911234567890
Now just extract the number after +CLIP: to compare against pre-stored numbers.

Related

How to link USR-7S4 with TI CC2640R2F through UART programming?

USR-7S4 is an LTE module and I just want to check whether it can communicate with CC2640R2F BLE module.
We can use UART communication and transmit the AT initialization commands described for the module. Once done with one AT command we need to accept the response using BLE and immediately clear that AT command so that the next command can be given. This helps to receive the new responses from the 0th position of the buffer. This clearing can be done using: "memset(rxBuf,0,sizeof(rxBuf));" commands.

It is possible to program Linino to send HTTP requests and then use the returned values in sketch?

I am new to using Arduino Yun and I would like to know if it is possible to run a command from the Arduino sketch in order to make (probably, through the Bridge Library) Linino to execute a HTTP Request to a remote server. Then I would like to know if it is possible to use the returned values in that Arduino sketch.
In other words, I would like to delegate the task of retrieving values from the web to the Linux side and the usage of the retrieved data to the sketch.
If it is possible, how to do that?
In your Arduino IDE there is an example scetch: File>Example>Bridge>HTTP client. Have you looked at that? It retrieves the content of a text document hosted on the Arduino site and prints it to the Serial Monitor.

GSM DATA INTERCHANGE

I was wondering if it is possible to send via GSM protocol and appropriate AT commands, few data through a simple GSM call (witout using data traffic).
For example my system is a PIC + GSM Module and it monitors and processes a string of data.
When the user wishes, he makes a voice call in order to interacts with the GSM module via DTMF commands for example via an APP.
My dubt is if the GSM module is able to send the data to thesmartphone in order to monitor the status of the system. The module is a Quectel M95.
During some investigation, I saw that the module can send USSD codes but I don't know if it's possible to customize the USSD and read it from the smartphone as I wish.
Or maybe is it possible to use the FAX for data exchange?
Thanks everybody in advance
Marco
There are a couple of alternatives if you want to avoid using data traffic. But they all require either a connection to a service that is capable of receiving SMS's for example Twilio. Or you can of course have a GSM Module connected to your server which could do the receiving.
You could then send your data and requests for data within an standard SMS body. Or alternatively you could send binary SMS's where you are not limited to the 7 bit character set.
USSD would only work if you have a USSD service provider (I think Twilio has this now). Because the USSD service must initiate a USSD session for your target GSM Module to respond to. USSD code sending for GSM Modules is operator specific and therefore you are limited to what they have implemented (usually for prepaid users and the topping up of accounts).

plc modbus ascii multiple instructions

I'm doing an application that uses the Modbus ASCII protocol (RS485).
A client will communicate with a PLC service that will talk to the PLC through the serial port.
I'm not sure whether there is any limitation about sending one command each time or if I need to wait for the response to come back from the PLC before sending the next command.
That will affect the architecture of the PLC service because if only one instruction can be processed at a time the design of my class will support one async method call and will expose IsBusy property. Otherwise I'll have to support concurrent method calls and pass in the stateId for each call (I'll be using EAP: Event-based Asynchronous pattern)
Thanks in advance.
The protocol is synchr. like comli so yes you can only send one command and must wait for a reply - I also doubled checked some old code just to be sure, been ages...
You can also read more about the protocol here
The Modbus protocol handles one command at a time, so wait until you have a response and then send the next command.

Read the ID of a xbee with Arduino Fio and send it over Serial Communication

I am trying to network multiple Arduino Fio with Xbee as slaves and my computer as Master with an Explore and Xbee.
Suppose i send and command 'Read' over serial to all Arduinos. Everyone responds suppose 'OK'.
My problem is to make them respond something like 'Arduino ID1 says OK' or 'Arduino ID2 says OK' etc.
Now this may be easy of each arduinos have separate programs burnt into them. But in my case all arduinos are suppose to have identical programs.
I know we assign MyID and Pan ID to each Xbee while configuring them for the first time.
So i am looking for some function in the program burnt into the Arduinos example
'readMyXbeeID()' or something.
Any ideas how i can do this? Or any other way to achieveArd the same thing?
I was able to get MYID by using AT commands.
You will need to read the XBEE documentation confirm these.
Use "+++" to get in to command mode (not forgetting the > one second delay to 'guard' this sequence).
{ I used: delay(1200); Serial.print ( "+++" ) ; }
The XBEE will respond OK\r.
Then ATMY\r will give you MYID returned as an ascii string terminated with "\r".
[In my case I had set a MYID of 2 so I saw the string "2\r"]
Finish with the command ATCN\r to exit command mode.
If you want to manage communications with several devices, I recommend you to use the API mode instead of the AT mode. If you are working with Arduino, there are some really good libraries: Xbee-Api and XBee-Arduino. Here you will find useful information and examples that may help in your project.
I mentored a few projects with these libraries (complete beginners in ZigBee technology), and they got all concepts really fast. 100% recomendable.
Regarding your question, you are right about writing just one program for all Arduinos. Otherwise you will have to create different hex-files for each node, which makes no sense. The easiest way for identifiying the ZigBee nodes is just using i.e. the 64-bit physical address. You can get this address easily through AT Commands. But keep in mind that in API Mode, whenever you send a message, the source address is automatically included in the frame, so you do not have to include explicity this information.

Resources