Counter not working

Discussion in 'Embedded Systems and Microcontrollers' started by xshax, Nov 3, 2012.

  1. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
  2. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    What is not working;) Hard for us to help with so little to work on
     
  3. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015

    Come t06afre I know you are smarter than that. Give the OP an answer. :) Plenty of info there. :rolleyes:
     
  4. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    problem is 1,2,3,4 connections are positive,so how to connect common cathode displays......?
     
  5. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015
    You are going to have to do much, much better than that.


    1. Post a full schematic

    2. Post your code.

    3. Describe in full detail the issue you are having. Not just a part of a sentence.

    4. Describe what you have already done to troubleshoot the issue.


    Please help others to help you. Don't expect others to put more time into helping you then you are willing to put into describing your issue.
     
  6. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015
    Wait you are not even the op. Why are you responding to someone else's thread? Or maybe Bertus messed up when he moved it??
     
  7. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    here it is ...........
    i need to prepare this project plz help me......
     
  8. bertus

    Administrator

    Apr 5, 2008
    15,648
    2,347
  9. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015
    What help do you need? Post your address and t06fre will fly out to your home and build your project for you. :eek:


    Seriously, what help do you need? What have you done so far, what is not working? What have you done to troubleshoot it?
     
  10. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    hi guys please help me in this manner.....i shall be thankful if anyone can give a working counter (hex & diagram).....
     
  11. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015
    It is your project, you need to provide that. We are more than happy to help you with any questions but we are not going to do the work for you.
     
  12. Wendy

    Moderator

    Mar 24, 2008
    20,766
    2,536
    Again, you need to post real pictures of what you have done, simply declaring it does not work is insufficient. The odds are you have done something incorrectly, but if you do not work with us we can not help you.

    The odds are if you do not have the patience to troubleshoot your personal work you will not do well in this hobby or profession. Troubleshooting is a large part of the learning curve.

    There are no royal shortcuts in learning math. Nor electronics.
     
  13. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    It has been some back and forth in this thread and other threads there the OP has posted this problem. But I think some place the OP said that he needed to swap display type from common anode to common cathode or vice versa. That is something we can work on.
     
  14. MMcLaren

    Well-Known Member

    Feb 14, 2010
    759
    116
    The author could certainly have done a better job commenting the program, however, if you take time to analyze the code and add some meaningful comments it becomes clear that the program has been written for common cathode displays. Notice that the segment lines (RB6..RB0) are active high and the column or digit lines (RA3..RA0) are active low;

    Code ( (Unknown Language)):
    1. ;********************************************************
    2. ;  refresh the common cathode displays                  *
    3. ;********************************************************
    4.  
    5. EKRAN
    6.         MOVLW   .5              ; refresh all four
    7.         MOVWF   RAKAM           ; digits five times
    8.         CLRF    PORTB           ; active hi segments off
    9.         MOVLW   .255            ; active lo digit select
    10.         MOVWF   PORTA           ; lines off
    11. GOSTER
    12.     BCF PORTA,0         ; select 4th digit (RA0)
    13.     BSF PORTA,1         ;   "
    14.     BSF PORTA,2         ;   "
    15.     BSF PORTA,3         ;   "
    16.     MOVF    BIR,W           ; ones, 0..9
    17.         CALL    TABLO           ; get segment data
    18.     MOVWF   PORTB           ; display new digit
    19.     CALL    GECIKME         ; delay 850-uS
    20.     CALL    GECIKME         ; delay 850-uS
    21.  
    22.     CLRF    PORTB           ; blank the display
    23.     BSF PORTA,0         ; select 3rd digit (RA1)
    24.     BCF PORTA,1         ;   "
    25.     BSF PORTA,2         ;   "
    26.     BSF PORTA,3         ;   "
    27.     MOVF    ON,W            ; tens, 0..9
    28.         CALL    TABLO           ; get segment data
    29.     MOVWF   PORTB           ; display new digit
    30.     CALL    GECIKME         ; delay 850-uS
    31.  
    32.     CLRF    PORTB           ; blank the display
    33.     BSF PORTA,0         ; select 2nd digit (RA2)
    34.     BSF PORTA,1         ;   "
    35.     BCF PORTA,2         ;   "
    36.     BSF PORTA,3         ;   "
    37.     MOVF    YUZ,W           ; hundreds, 0..9
    38.         CALL    TABLO           ; get segment data
    39.     MOVWF   PORTB           ; display new digit
    40.     CALL    GECIKME         ; delay 850-uS
    41.  
    42.     CLRF    PORTB           ; blank the display
    43.     BSF PORTA,0         ; select 1st digit (RA3)
    44.     BSF PORTA,1         ;   "
    45.     BSF PORTA,2         ;   "
    46.     BCF PORTA,3         ;   "
    47.     MOVF    BIN,W           ; thousands, 0..9
    48.         CALL    TABLO           ; get segment data
    49.     MOVWF   PORTB           ; display new digit
    50.     CALL    GECIKME         ; delay 850-uS
    51.     DECFSZ  RAKAM,F         ; last cycle? yes, skip, else
    52.     GOTO    GOSTER          ; branch (refresh again)
    53.     RETURN                  ;
    54.  
    Are you using common cathode displays? If so, are you sure you wired the displays correctly?
     
    Last edited: Nov 6, 2012
  15. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015
    I would not spend too much time trying to help the OP until the OP makes some effort to help himself..


    Looks like a "one post wonder" to me.
     
    Eric007 likes this.
  16. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    hi guys this project not belongs to me.......]
    i think it belongs to profahmet. brothers i don't want to hijack anyone project.i just wanted to make 4digit counter.so i search everywhere on the internet and i found profahmet project in here.i made it.but it's not working.i need your help to run this.not to find the owner of this project.......



    i'm new to here.i don't no how to create a thread and how to reply a thread (that is the reason you people misunderstand me)
     
  17. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    what is the meaning of OP.......?
     
  18. spinnaker

    AAC Fanatic!

    Oct 29, 2009
    4,887
    1,015



    Once again. You need to help yourself. We will help you with various problems you might have but we are not going to build your project for you.

    That is no fun for you anyway. You might as well buy a product off of the shelf.

    You will need to get started and define where you are having issues. And it can't be as general as "write the hex code for me". You need to do that and when you have SPECIFIC questions, post back here and we will try to help.
     
    Eric007 likes this.
  19. t06afre

    AAC Fanatic!

    May 11, 2009
    5,939
    1,222
    What kind of display are you using. Do you have the exact part number. And how do you connect it to the 16f84.
     
  20. xshax

    Thread Starter New Member

    Oct 24, 2012
    11
    0
    pat no.5161AS

    it is common anode
     
Loading...