connect@howdiyworld.com
|

GSM SMS Sending (Automation)

What is Needed?

GSM Module
Sim Card
Jumpers
HowDIY

BLOCK DIAGRAM

Procedure

  1. GSM Module
  2. Connection
  3. Program
  4. Output

Procedure

GSM Module

A GSM module or a GPRS module is a chip or circuit that will be used to establish communication between a mobile device or a computing machine and a GSM or GPRS system.

Connection

  • Connect GSM’s Rx to 8th pin
  • Connect GSM’s Ground (GND) to 6th pin
  • Connect GSM’s VCC to 2nd

Program

import serial

from time import sleep

ser = serial.Serial (“/dev/ttyS0", 9600)

def get_input(a):

ser.write(str.encode('AT'+'rn'))

sleep(1)

ser.write(str.encode('AT+CMGF=1'+'rn'))

sleep(1)

ser.write(str.encode('AT+CMGS="Your Mobile Number"'+'rn'))

sleep(1)

ser.write(str.encode(''+a+'from HOWDIY'+'rn'))

sleep(1)

ser.write(str.encode(“x1A"))

sleep(1)

Output

Now you can send SMS to a number through Python Programming Language

Social media & sharing icons powered by UltimatelySocial
Facebook
Twitter
YouTube
LinkedIn
Instagram