Discussion in "8051 Discussion Forum" started by    sks    Sep 19, 2008.
Fri Sep 19 2008, 09:26 AM
#1
thank u very much mr pundalik a.k.a. pdi33. u have given me a great pleasure to mail and guide me to use the site. i love electronics, i always experiment with new technology as right now i am working in media designing pipe line for post production studios in orissa. whenever i find time i do make myself busy with electronics. that give me energy. i may be old physically but i am very young mentally. god bless u all people. i am very happy to say u all r helping other people by guiding properly without anything, that's a great & noble idea.
any way i am working on a object counter project. i can make the counter Hardware using discrete ics but i want it on uc as it can be don with less components. i can write code for a single digit counter using a switch as input , 7seg display as display. i don't know how it can covert to multiple digits, i want the device should count up to 9999 , all the display should be multiplexed. a switch can be used as input in every press of the switch the counter has to increment by 1, when it reaches 9999 it has to stop. then restart again by another sw press. i am sorry fora lengthy mail .thanks all again
s.k.sahoo
Fri Sep 19 2008, 12:00 PM
#2
hi
you can download the project from link
i write this code with bascom8051 and change to asm for you
http://www.2shared.com/file/3955362/782373c3/project.html
can you download from 2shared?
bay
 sks like this.
Fri Sep 19 2008, 06:08 PM
#3
Hi sks, welcome to website We all try to do our best. And Hope you learn a lot from here

Please keep 1nafar's code as reference, i suggest you to try it on your own so that it helps you better way. If you have any doubt doesnt matter small or big simply post here.
 sksAmit singh like this.
Fri Sep 19 2008, 06:36 PM
#4
btw, i checked the simulation file of nafar and it seems to be a time counter(timer) instead of object counter. So u will have to do a little modifications i the ciruit provided by him especially about intrducing the opto coupler part as u had referred to it in the chat box description ( if remember correctly).
for the optocoupler, i suggest u use the simplest one which is the TL817 4pin opto.
u can refer in the download section for 7 segment interfacing circuit ( u will require multiplexed one for ur project .)
try finalising the circuit first before starting coding.
good luck,
regards,
:-)

P.S.: another important aspect for object counting (if u r going to use it in a practical application in future) is the storage of the last count on power failure so that u can continue from the last count onwards. Please confirm whether that condition is required for ur apliction and i can suggest u a solution for it.



[ Edited Fri Sep 19 2008, 06:39 PM ]
 sks like this.
Sat Sep 20 2008, 06:07 AM
#5
Thanks Ajay, i have inafar's project file there was Proteus project file along with codes written in basic ,hex file and a list file etc . i have simulated that in Proteus, it is a time counter. ok whatever it may be i had followed his source code in the list file but sorry to say i couldn't follow completely as it doesn't have comments. as i have said i am new to uc i will love to know in details like how u people write algorithms and the codes. please guide. thanks again
s.k.s
Sat Sep 20 2008, 06:36 AM
#6
Hi Mr pdi33, thank u for ur reply, comments, and queries. yes Inafar's project is a time counter i had simulated in Proteus i can modify the circuit and post. u have said correctly i have to store data in external memory if power fails or for other reasons. i think a 24c04 will solve the problem i don't know what u suggest. actually it is a practical project i will use a 4*4 matrix key pad to input the required base value. when i start the hardware all 4 display has to be in off mode , i may enter any value like 0000, 34 or 100 in hex keypad which has to be displayed after that i have to press an enter key which will be a part of hex keypad to start the counter it has to count above the entered value and stops at 9999. Mr Ajay has advised me to follow Inafar's code but i could not follow his code, i want to learn pl help me from ALGO to CODE writing. i know it may be a hard task for u but if u can pl guide me young man. i don't know what u do, do u have time or not. pl reply. thank again
sks
Sat Sep 20 2008, 09:09 AM
#7
Hi Mr ajay, sorry to disturb u people, but i want to learn programming. i have followed the code of Mr Inafar but it is hard to understand on part fully.
let us go slowly, i have some questions
1: if we write ORG 00H is it reset all and goes to starting of all locations or starting of only memory location ?
2: if we write ORG 0BH is it reset time counter0 ?
3: i don't follow this ORG 33H, 36H is it starting of (general purpose) scratch pad location of internal RAM?
4: in line x004b he has written mov 20h,#0 is it decimal 0 will be loaded at bit addressable location of RAM
I don't know uc language correctly i am trying to learn, i write very small codes. i have never used interrupt or counter of 8051, some people write delay routine using timer but i write delay routine using LOOP technique.
i will appreciate if u help me to complete this project. thanking you once again. i am sorry but i want to learn
sks
Sat Sep 20 2008, 09:21 AM
#8
Hi Mr 1nafar, thank u for ur help. i am glad to know u have taken pain to disassemble the code and mail me to help me out. god bless u people, but i could not follow completely as there are no comments and subroutine names i don't know what u call it (x0036). if u want to help me pl send me the ALGORITHM of ur code by which i will try to understand it. u have used direct bit addressable method and used interrupts i am not used to it as i am starting learning recently. thanks again
sks
Sat Sep 20 2008, 05:48 PM
#9

hello SKS,

we respect your interest and appreciate your Zeal to learn Micros. please don't be in a hurry, my advice would be to first get hold of a good micro book like Kenneth Ayala or mazidi and soak you self into the basics of code building, try some small projects to familiarize with concepts and then move on to more complex projects.

Arun
 sks like this.
Sat Sep 20 2008, 09:17 PM
#10
Hello sks

As Arun says the best place to start is with a good book,
(or several good books) and simple experiments.

Trying to understand someone else's code, without good commenting
is very hard.
I wouldn't bother, you'll just get a headache

Good luck anyway.



[ Edited Sat Sep 20 2008, 09:20 PM ]
 sks like this.

Get Social

Information

Powered by e107 Forum System

Conversation

Thu Nov 21 2019, 12:30 PM
raj2555
how to interface 8051 microcontroller with NRF24L01+ module
ExperimenterUK
Sat Oct 12 2019, 10:23 PM
Log in.. then post your code in the 8051 forum
Sat Oct 12 2019, 10:18 AM
Bhadra Sajikumar
i am doing a countdown timer with 8051 for my project, unfortunately our professor had to take a leave of absence before he could teach us most of it.. can someone explain the .asm code of it for me?
Mon Sep 23 2019, 07:37 AM
Nathaniel
I am doing a project for my schools wireless security system with cameras,sensors and spot lights using 8051 micro controller, could you help me out with the design and its source code.
Wed Sep 18 2019, 08:48 PM
Caryn Kover
Thank you for your time,
ExperimenterUK
Mon Aug 05 2019, 07:09 PM
@Ismail ..post in forum, give details
Mon Aug 05 2019, 04:33 PM
Ismail balghmi
Hello. Please I won't download
ExperimenterUK
Wed Jul 24 2019, 12:47 AM
@BUSTER123 Please post in the forum
Tue Jul 23 2019, 06:13 PM
BUSTER123
hello! newbie here. i am kind of a guy who hates using ready - made existing libraries, so this helped a lot as i was trying to control and write to a character lcd display. however, i can't figure out how to set the cursor position. for example, i want to set it to the 5th column in the first row, so position 5. so according to the table, i am sending 10000101 on the 8 data lines of the lcd (register select pulled low). the cursor does not move there however. and i cant move the cursor left or right too. is it something wrong that i am doing? thank you.
ExperimenterUK
Thu Jul 11 2019, 07:55 PM
@ramos https://www.theengineeringprojects.com/2017/09/l298-motor-driver-library-proteus.html

Downloads

Comments

nabiha_anaya
Sun Dec 08 2019, 09:16 AM
ananyagupta
Tue Dec 03 2019, 07:53 AM
wells
Mon Nov 25 2019, 08:25 PM
auwal
Tue Nov 19 2019, 03:13 PM
ANKITPATEL
Mon Nov 18 2019, 11:00 AM
Casmir
Wed Nov 13 2019, 06:25 AM
DeepakBGattani
Mon Nov 11 2019, 01:31 PM
Jeanbusatta
Sun Nov 10 2019, 04:42 AM

Online

Guests: 30, Members: 0 ...

most ever online: 182184
(Members: , Guests: 182184) on 06 Aug 2010: 05:37 AM

Members: 38108
Newest member: nabiha_anaya
Forum Activity
ilylily07 Avatar
Posted By ilylily07
Sun Dec 08 2019, 01:24 PM
Hi .im humbly ask for your advice as i wrongly pur...
nabiha_anaya Avatar
Posted By nabiha_anaya
Sun Dec 08 2019, 09:19 AM
My teacher assign me a project on "voice control h...
ExperimenterUK Avatar
Posted By ExperimenterUK
Fri Nov 29 2019, 04:24 AM
" Is it possible to interface a fingerprint scanne...
ilylily07 Avatar
Posted By ilylily07
Thu Nov 28 2019, 03:50 PM
You will not find any code for an 8051 as no one w...
ExperimenterUK Avatar
Posted By ExperimenterUK
Tue Nov 26 2019, 05:44 PM
You will not find any code for an 8051 as no one w...
ilylily07 Avatar
Posted By ilylily07
Tue Nov 26 2019, 04:13 AM
I tracked down a OV7670 data sheet.The OV7670 puts...
ExperimenterUK Avatar
Posted By ExperimenterUK
Tue Nov 26 2019, 12:08 AM
I tracked down a OV7670 data sheet.The OV7670 puts...
ilylily07 Avatar
Posted By ilylily07
Mon Nov 25 2019, 04:38 PM
The 8051 has too little memory to do anything us...
ExperimenterUK Avatar
Posted By ExperimenterUK
Tue Nov 19 2019, 10:44 PM
The 8051 has too little memory to do anything us...
ilylily07 Avatar
Posted By ilylily07
Mon Nov 18 2019, 09:54 AM
0v7670 camera interfacing with stc 8051.using asse...