bikash123
Member level 2
- Joined
- Feb 19, 2012
- Messages
- 48
- Helped
- 0
- Reputation
- 0
- Reaction score
- 0
- Trophy points
- 1,286
- Location
- Tezpur University
- Activity points
- 1,672
Plz help me.
i have written one programme of internal EEPROM with PIC microcontrollers. Is the programme is right to run. plz tell me the connection diagram. the compliler is microc.
// LCD module connections
sbit LCD_RS at RB4_bit;
sbit LCD_EN at RB5_bit;
sbit LCD_D4 at RB0_bit;
sbit LCD_D5 at RB1_bit;
sbit LCD_D6 at RB2_bit;
sbit LCD_D7 at RB3_bit;
sbit LCD_RS_Direction at TRISB4_bit;
sbit LCD_EN_Direction at TRISB5_bit;
sbit LCD_D4_Direction at TRISB0_bit;
sbit LCD_D5_Direction at TRISB1_bit;
sbit LCD_D6_Direction at TRISB2_bit;
sbit LCD_D7_Direction at TRISB3_bit;
// End LCD module connections
char *txt1="current";
int I,V;
Lcd_Init();
Lcd_Cmd(_LCD_CLEAR); // Clear display
Lcd_Cmd(_LCD_CURSOR_OFF); // Cursor off
void main()
{
while(1)
{
current_read();
}
txt1= " current";
Lcd_out(1,1,txt1);
Delay_ms(2000);
ADCON1=0x22; // A/D Conversions of input voltage
TRISA= 0xFF; // All input Pins of A are connected as inputs
}
void current_read()
{
V= ADC_Read(2)* 5000/1024;
I = V - 2.5;
FloatToString(I,str)
Lcd_Out(1,8,str)
Delay_ms(10);
}
i have written one programme of internal EEPROM with PIC microcontrollers. Is the programme is right to run. plz tell me the connection diagram. the compliler is microc.
// LCD module connections
sbit LCD_RS at RB4_bit;
sbit LCD_EN at RB5_bit;
sbit LCD_D4 at RB0_bit;
sbit LCD_D5 at RB1_bit;
sbit LCD_D6 at RB2_bit;
sbit LCD_D7 at RB3_bit;
sbit LCD_RS_Direction at TRISB4_bit;
sbit LCD_EN_Direction at TRISB5_bit;
sbit LCD_D4_Direction at TRISB0_bit;
sbit LCD_D5_Direction at TRISB1_bit;
sbit LCD_D6_Direction at TRISB2_bit;
sbit LCD_D7_Direction at TRISB3_bit;
// End LCD module connections
char *txt1="current";
int I,V;
Lcd_Init();
Lcd_Cmd(_LCD_CLEAR); // Clear display
Lcd_Cmd(_LCD_CURSOR_OFF); // Cursor off
void main()
{
while(1)
{
current_read();
}
txt1= " current";
Lcd_out(1,1,txt1);
Delay_ms(2000);
ADCON1=0x22; // A/D Conversions of input voltage
TRISA= 0xFF; // All input Pins of A are connected as inputs
}
void current_read()
{
V= ADC_Read(2)* 5000/1024;
I = V - 2.5;
FloatToString(I,str)
Lcd_Out(1,8,str)
Delay_ms(10);
}