Discussion in "Project Doubts" started by    Chinmay Das    Mar 11, 2009.
Thu Oct 22 2009, 06:09 pm
@mohsin: ya i have simulated it on proteus ..it is working properly in the simulation..and since i am not using read lcd i have grounded it ...here is my code..this is only one part of it..actually i want to make a rolling display from right to left..this part of the code is just to display the text..i still have to write the scrolling part..
LCD_data equ P2    ;LCD Data port
LCD_D7   equ P2.7  ;LCD D7/Busy Flag
LCD_rs   equ P1.6  ;LCD Register Select

LCD_en   equ P1.7  ;LCD Enable


         mov   LCD_data,#38H  ;Function set: 2 Line, 8-bit, 5x7 dots
         clr   LCD_rs         ;Selected command register
        
         setb  LCD_en         ;Enable H->
L
         clr   LCD_en
         acall LCD_busy       ;Wait for LCD to process the command
         mov   LCD_data,#0FH  ;Display on, Curson blinking command
         clr   LCD_rs         ;Selected instruction register
         
         setb  LCD_en         ;Enable H->
L
         clr   LCD_en
         acall LCD_busy       ;Wait for LCD to process the command
         mov   LCD_data,#01H  ;Clear LCD
         clr   LCD_rs         ;Selected command register
         
         setb  LCD_en         ;Enable H->
L
         clr   LCD_en
         acall LCD_busy       ;Wait for LCD to process the command
         mov   LCD_data,#06H  ;Entry mode, auto increment with no shift
         clr   LCD_rs         ;Selected command register
        
         setb  LCD_en         ;Enable H->
L
         clr   LCD_en
         acall LCD_busy       ;Wait for LCD to process the command
                          ;Return from routine



LCD_busy:
         mov  r7,#50H
back:
         mov r6,#0FFH
         djnz r6,$
         djnz r7,back
         ret                  ;Return from busy routine


LCD_senddata:
         mov   LCD_data,A     ;Move the command to LCD port
         setb  LCD_rs         ;Selected data register
        
         setb  LCD_en         ;Enable H->
L
         clr   LCD_en
         acall LCD_busy       ;Wait for LCD to process the data
         ret                  ;Return from busy routine



LCD_sendstring:
         clr   a                 ;clear Accumulator for any previous data
         movc  a,@a+dptr         ;load the first character in accumulator
         jz    exit              ;go to exit if zero
         acall lcd_senddata      ;send first char
         inc   dptr              ;increment data pointer
         sjmp  LCD_sendstring    ;jump back to send the next character
exit:
         ret                     ;End of routine


mov   dptr,#my_string   ;my_string is the label where the string is stored
acall LCD_sendstring    ;Send string

my_string:
DB   "Mohak Jhaveri  Yuvek Mehta", 00H
end
Thu Oct 22 2009, 06:11 pm
@chinmay: i have verified my diagram with yours..i dont think there is a problem with my connections..
@mohsin: as u said that this is a very common problem...what are the most probable reasons why this could be happening..??
Thu Oct 22 2009, 09:53 pm
@ mohak

try pullup resistors in ur circuit

i think ur problem should be solved
Thu Oct 22 2009, 11:39 pm
the main reason behind this problem mohak is that the LCD does not get properly initialized due to proper or somewht loose connections....make sure that u r using pullup resistor if ur driving ur lcd through port 0. secondly try to use plug system for connecting ur lcd to port 0 rather than directly solding the wires....can u do one thing...post the snapshot of ur hardware cct of LCD and microcontroller...?
Fri Oct 23 2009, 05:01 pm
in your program you forgot to set the LCD address to 80H before displaying data. try to send 80H command to LCD and try again. If still it doesn't work then.

check reset circuit
check crystal
make sure your controller is working try to put a blink program.

secondly, see if your power supply is enough to run your circuit. check the drop using multimeter (check VCC).

NOTE: If your doubt is not related to this project, please try to post it in a new thread coz this thread is for GreenBee project.
Mon Oct 26 2009, 07:00 pm
according to this project i used soil moisture sensor and gave the input supply 5v

it is producing ground leakage current plllzz help


one thing more if the water level is different in greenhouse then how we can decide the soil moisture
Tue Oct 27 2009, 03:15 pm
did u follow the same circuit given in the report for soil moisture??? if yes then it should not cause such problem

and sorry i culd not understand ur second question... ....
Sun Nov 01 2009, 10:21 am
@ m mohsin

I tried the same circuit but it doesn't work

can u explain me the working of 2N222n transistor

my second question is

if the land area where we have installed the soil moisture sensor is around 10 acres and there is different water content in different areas of soil then how we can decide what is the exact soil moisture sensor???/
Thu Nov 05 2009, 04:15 pm
well none of us who tried this project faced the problem in soil moisture sensor....and its working is well written in the project report that u downloaded.

secondly this project is designed as a sample device for the automation of small green house...u can expand it according to ur requirements...if u hace such a big land for green house then u can use more than one soil moisture sensors and divide the land into small portions and then program ur controller according to that division where u get the display some wht like "soil moisture of particular portion : ***"

Sun Nov 08 2009, 03:30 pm
hey..thanks a lot everyone..my project started working..:D

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

Astorne
Tue Apr 16 2024, 08:52 pm
Williamjaf
Tue Apr 16 2024, 12:25 pm
best_yyPa
Tue Apr 16 2024, 09:42 am
ErnestoExpop
Tue Apr 16 2024, 02:57 am
Jamesclepe
Mon Apr 15 2024, 11:10 am
Aliciaelora
Mon Apr 15 2024, 07:59 am
btaletvpcu
Mon Apr 15 2024, 04:36 am
UbvpwcTib
Mon Apr 15 2024, 03:13 am