Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

light follower and obstacle aviodance robot.

Status
Not open for further replies.

mukhtar

New Member
hi guys

i want to design a light following robot that uses two LDRs at front and it must also avoid obstacles by using limit switch.i want to write the code using assembly and iam new to it so i want some one to tell me how to code the ADC of this two sensors, and display voltage on lcd and drive motors using the data from ldr. so please help me with the assembly lang
 
why do you want to use assembly? You can certainly do that in assembly, but it may not be the easiest way. Assembly is best where very low level control is needed, usually for very good optimization. Reading some ADCs and responding to them doesn't seem like it requires that.
 
why do you want to use assembly?

Here's the reason:
Everything works fine until the program does not work.
Here's the dilemma: Is the fault in the code?
Is the fault in a bracket?
How do you fault-find?

If you use the instructions provided for the chip, you can methodically work through and locate the problem.

I have done more in assembly (Tic Tac Toe game) than I have seen in any higher level language.
Writing a program up to 1k is much easier, quicker and less frustrating for a beginner.
At least you can get it started and finished via my method of “cut and paste.”
I have yet to see anyone help a beginner in any other language.
 
I have yet to see anyone help a beginner in any other language.
Have you checked out the microcontroller forum on this site, Colin55?
 
i really need to use assembly because i am doin a project asked by my lecturer and i understand the basics but the problem is how to relate the analog parts and make the motor respond to it. that is chalenging for me
 
Ok then. Do you have any specific questions? For a start you can get MPLAB for free and the microchip assembler, or some other assembler for 8 bit PICs. Then just look at some example assembly code about controlling the ports, and about reading ADCs. Get the datasheet for the chip by searching its number and "datasheet", read the intro, features, and the sections on the ADC and ports. Once you've done this stuff you'll have a good start and should you have any problems, you can ask more specific questions.
 
if i want to use portA(RA0 AND RA1) as input of analog and want to use portd as output to motor and portb as output to lcd. how should i do the assembly coding for this part. please if u know atleast one part. just it may help.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top