ARM 7

 ARM7 is a type of microcontroller core created by ARM Holdings. It's known for being powerful, energy-efficient, and versatile, making it suitable for many different uses. You can find ARM7 processors in things like smartphones, cars, and even household appliances.

These processors are great because they have lots of features that developers can use to create all kinds of cool stuff. They're really good at handling different tasks and connecting to other devices. So whether it's controlling machines in a factory or making your smartwatch work, ARM7 processors are up to the job.

Object counter

Introducing our ARM7-based Object Counter – a smart solution for counting objects in real-time using IR sensors. This project detects and tracks objects passing through a designated area, providing a simple and efficient way to monitor traffic or track inventory

Source code:

#include<lpc214x.h>
#include<stdio.h>
#include<string.h>
#include "4Bitlcd.h"
#define IR (IO1PIN & (1<<24))
 
unsigned int i;
int count=0;
char str_count[10];
int main()
{
	  PINSEL1=0x00000000;
  	PINSEL2=0x00000000;
	  IODIR1=0x00F00000;
	  IODIR0=0x00070000;  
	
    lcd_init();
    lcd_cmd(0x80);
    string("OBJECT COUNTER");
	
    while(1) {
            if(IR == 0) {
							count++;
							sprintf(str_count,"%d",count);
							lcd_cmd(0xC0);
              string(str_count);	
							delay(25);
							IOSET1=(1<<24);
            }
						
           else
					 {
						  lcd_cmd(0xC0);
              string(str_count);	 
            
           }





OTP based door locking system with dual verifaction:

Introducing our ARM7 Door Locking System – a secure solution with dual verification. Users enter a PIN and receive a one-time password (OTP) on their mobile device to unlock the door. In case of device failure, a physical key can be used. After three incorrect attempts, an alert is sent, and the door remains locked until verified by the user.

#include "keypad.h"

#include "OTP_GENERATE.h"

int main(){

    PINSEL0=(1<<0) | (1<<3);

  PINSEL1=0x00000000;

  PINSEL2=0x00000000;

    IODIR0=0x000FFFF0;

  

  IODIR1=0x000FF000; 

  

  uart_init();

  lcd_init();

     

  while (1){

  lcd_cmd(0x0f);

  display("ENTER PIN:");

    keypad();

  pwd_chk(pwd);

lcd_cmd(0x01);//clear display

  display("PRESS SW1 FORKEY");

  lcd_cmd(0xC0);

  display("PRESS SW2 FOROTP");

while(1){

/// switch two

    if(( IOPIN0 & 0x04000000) == 0 )

{

//delay(10);

display("PRESS SW2 AGAIN");

lcd_cmd(0xC0);

lcd_cmd(0x01);

        display("TO RECEIVE OTP");

lcd_cmd(0xC0);

display("PRESS SW2 AGAIN");

if( strcmp(keypad(),otp_generate()) == 0 )

{

lcd_cmd(0x01);

display("WELCOME HOME");

delay(100);

}

        else{

            lcd_cmd(0x01);

            display("WRONG OTP");

 

             }

        }

//// switch one

else if(( IOPIN0 & (1<<25)) == 0 )

{

lcd_cmd(0x01);

display("UNLOCK DOOR WITH");

lcd_cmd(0xC0);

display("THE KEY AND ENTER");

delay(30);

lcd_cmd(0x01);

display("WELCOME HOME");

delay(100);

}

  }// 2nd while

    }//main while

 

 

}//main


Note: The header files which are getting used are self made customized to make it work.








RTC based alarm setting on 7 segments


This project features a real-time clock (RTC) display using an LPC214x microcontroller. it allows users to set an alarm using push buttons. When the alarm time matches the current time, an LED blinks. The system provides reliable timekeeping and alarm functionality in a compact design.


source code :


#include <lpc214x.h>
#include "RTC.h"

//unsigned int num[10]= {0x0000003F,0x00000006,0x0000005B,0x0000004F,0x00000066,0x0000006D,0x0000007D,0x00000007,0x0000007F,0x00000067};

int main(){
  PINSEL0=0x00;
PINSEL1=0x00;
PINSEL2=0x00;
IODIR0=0x000000FF;
IO1DIR = (1<<16) | (1<<17) | (1<<18) | (1<<19) | (1<<20) | (1<<21) | (1<<23) ;
IOCLR1=(1<<23);  // led off
  RTC_set_alarm();
RTC_init();
while(1){
    volatile int hours = HOUR;
        volatile int minutes = MIN;
        volatile int seconds = SEC;
////SECONDS////
IO0CLR = 0xff;  // seg clr 
IOCLR1 = (1<<20)  ;                   // tens on 
IO1SET = (1<<16) | (1<<17) | (1<< 18) | (1<<19) | (1<<21);      // unit off hundred off thousand off
IO0SET =  num[seconds/10];      
delay(10);
 
IO0CLR = 0xff;
  IO1CLR = (1<<21);                     // unit on
IO1SET = (1<<16) | (1<<17) | (1<< 18) | (1<<19) | (1<<20);       //  tens off hundred off thousand off
IO0SET =  num[seconds%10];   
delay(10);
//////SECONDS////////////////
////MINUTE//////
  IO0CLR = 0xff;  // seg clr 
IOCLR1 = (1<<18)  ;                   // tens on 
IO1SET = (1<<16) | (1<<17) | (1<< 20) | (1<<19) | (1<<21);      // unit off hundred off thousand off
IO0SET =  num[minutes/10];      
delay(10);
 
IO0CLR = 0xff;
  IO1CLR = (1<<19);                     // unit on
IO1SET = (1<<16) | (1<<17) | (1<< 21) | (1<<18) | (1<<20);       //  tens off hundred off thousand off
IO0SET =  num[minutes%10];   
delay(10);
///////MINUTE////////
//////////////////HOUR//////////////
IO0CLR = 0xff;  // seg clr 
IOCLR1 = (1<<16)  ;                   // tens on 
IO1SET = (1<<18) | (1<<17) | (1<< 20) | (1<<19) | (1<<21);      // unit off hundred off thousand off
IO0SET =  num[hours/10];      
delay(10);
 
IO0CLR = 0xff;
  IO1CLR = (1<<17);                     // unit on
IO1SET = (1<<16) | (1<<19) | (1<< 21) | (1<<18) | (1<<20);       //  tens off hundred off thousand off
IO0SET =  num[hours%10];   
delay(10);
//////////////////HOUR//////////////
if( hours == ALHOUR && minutes == ALMIN && seconds == ALSEC)
{
IOSET1=(1<<23);
delay(5000);  
     IOCLR1=(1<<23);
delay(5000);
IOSET1=(1<<23);
delay(5000);  
     IOCLR1=(1<<23);
delay(5000);
IOSET1=(1<<23);
delay(5000);  
     IOCLR1=(1<<23);
delay(5000);
    }
}


}
























Comments

Popular Posts