Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

assembly code with pic16f877

Status
Not open for further replies.

Adamant

Newbie level 5
Joined
Mar 26, 2005
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,353
Hello all.

Im Adamant, and I need help writing a code in Assembly Language.....I am stuck using the MPLAB Ide for my code writing....and im not very good at it.


I need some help on a code that will send info from a 360 degree potentiometer to the pic, and from the pic to an LCD. My LCD is a 4x20, and it has its "own" commands. I dont know how to incorporate these commands to use them in assembler.

I'm trying to display directions, on the LCD, such as North, South, East, West. And im using a 360 degree pot. As my pot changes resistance values when it turns, I want the display on the LCD to show the direction, N, S, E, or West.

I have a serial LCD.


Any ideas?

thank you for reading!
 

Cortex

Full Member level 3
Joined
Mar 26, 2005
Messages
182
Helped
12
Reputation
24
Reaction score
4
Trophy points
1,298
Location
Morocco
Activity points
2,733
u can use a ADC to Read the exact Position of the Pot
for the LCD there some routine that you can use
 

Adamant

Newbie level 5
Joined
Mar 26, 2005
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,353
Cortex said:
u can use a ADC to Read the exact Position of the Pot
for the LCD there some routine that you can use

i think there is an analog to digital converter on this PIC (i'm just beginning this project)
any routines, any methods of assembly code would be HIGHLY APPRECIATED!
 

donkey41

Full Member level 1
Joined
Feb 19, 2002
Messages
99
Helped
2
Reputation
4
Reaction score
1
Trophy points
1,288
Location
Pakistan
Activity points
949
hello,

i can provide a code example for 16F76
this will need some modifications for your 877, but it souldnt be too much effort.
you can get at least some idea.

this test project was for a 16x2 chracter LCD.
 

    Adamant

    Points: 2
    Helpful Answer Positive Rating

Adamant

Newbie level 5
Joined
Mar 26, 2005
Messages
8
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,353
Thank you for that Donkey41. You helped me. I clicked the "points" button for you, forgive my ignorance, im still learning how this board operates, with the points and all.
 

Cortex

Full Member level 3
Joined
Mar 26, 2005
Messages
182
Helped
12
Reputation
24
Reaction score
4
Trophy points
1,298
Location
Morocco
Activity points
2,733
this is for the 16f84
u can see how to communicate with LCD 16*2
 

    Adamant

    Points: 2
    Helpful Answer Positive Rating

bonn.2101

Newbie level 3
Joined
Jan 18, 2011
Messages
4
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,432
can i also have the examples.. i'm having problems communicating with lcd.. thanx...
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top