Searching \ for 'EEPROM & LCD Matrix' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/lcds.htm?key=lcd
Search entire site for: 'EEPROM & LCD Matrix'.

Truncated match.
PICList Thread
'EEPROM & LCD Matrix'
1995\11\09@110800 by SONY-OD

flavicon
face
From "Philippe"<spam_OUTsonyedeTakeThisOuTspamiway.fr>

On Tue, 7 Nov 1995 .....John.P.HollingsheadKILLspamspam@spam@HAPPY.FIRSTNETHOU.COM wrote:

> Also, I'm looking for some good sources for the displays.  What I
> have in mind, is for using a pic 16c57 for taking the 2of 8 binarie
> from a cd22202e dtmfdecode chip, and outputing to a serial e-prom and
> to output to the display.  It then must be able to access the eeprom
> to get readback buffers.

I already do that, specially to read/write serial EEPROM, I use a 93C46, but
another type can also be driven with this code.

Here is a piece of code to drive EEPROM


;>>>>>> START OF SAMPLE CODE
; This what I do to drive a PLL MC145170 and a 96C46 EEPROM

;******************************************************************************
;   HCK      = PortC.1
;   DATA out = PortC.3
;   DATA in  = PortC.5
;   CS PLL   = PortC.2
;   CS ROM   = PortC.6
;
;----- PLL & EEPROM  Constants

bHCK           equ 1
PEnb           equ 2
REnb           equ 6
bDout          equ 3
bDin           equ 5
bLock          equ 0

;******************************************************************************
; READ Routine for SERIAL EEPROM (96C46 : 64 X 16Bit)
; REGISTER used:
;    Data1         -> $0E
;    Data2         -> $0D
;    Address/Temp  -> $0F
;    EETemp        -> $0A

        org $0600
                  ;76543210
SetDataOut     equ %10110001

EERead:  movlw SetDataOut   ; Set HCK/DOUT/ENB as OUTPUT
        tris  C
        bcf  SPort,bHCK    ; bHCK = 0
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        bsf  SPort,PEnb    ; PEnb = 1    PLL ACCESS disable

        bcf  SPort,bDOUT
        bsf  SPort,REnb
        nop
        nop
        bsf  SPort,bHCK
        nop
        nop

        call EEStart
        movf Temp,W        ; GET Address from Temp register
        andlw %00111111    ; it's a 6 bit ADDRESS
        iorlw  %10000000   ; ADD Read INSTRUCTION to the word
        call EERdOut
        call EERdIn
        movf  Data1,W
        movwf Data2
        call EERdIn
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        retlw 0

;---------------
EEStart: bcf SPort,bHCK
        bsf SPort,Renb
        bsf SPort,bDOut
        nop
        nop
        nop
        bsf SPort,bHCK
        nop
        nop
        bcf SPort,bHCK
        nop
        retlw 0

;---------------
EERdOut: bsf SPort,Renb
        movwf EETemp
        movlw 8
        movwf Temp
        bcf SPort,bHCK

EERdO_1: bcf SPort,bDOut
        rlf EETemp
        btfsc STATUS,Cy
        bsf SPort,bDOut
        nop
        nop
        bsf SPort,bHCK
        nop
        nop
        nop
        bcf SPort,bHCK
        decfsz Temp
        goto EERdO_1
        retlw 0

;---------------
$BREAK
EERdIn:  bsf SPort,Renb
        movlw 8
        movwf Temp
        bcf SPort,bHCK

EERdI_1: nop
        nop
        bsf SPort,bHCK
        nop
        bcf STATUS,Cy
        btfsc SPort,bDIn
        bsf STATUS,Cy
        rlf Data1
        nop
        bcf SPort,bHCK
        decfsz Temp
        goto EERdI_1
        retlw 0

;******************************************************************************
;******************************************************************************
; ENABLE, DISABLE and WRITE Routine for SERIAL EEPROM (64 X 16Bit)
; REGISTER used:
;    Data1         -> $0E
;    Data2         -> $0D
;    Address/Temp  -> $0F
;    EETemp        -> $0A
;    CounterA      -> $1D
;    CounterB      -> $1E


EEEnable:movlw SetDataOut   ; Set HCK/DOUT/ENB as OUTPUT
        tris  C
        bcf  SPort,bHCK    ; bHCK = 0
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        bsf  SPort,PEnb    ; PEnb = 1    PLL ACCESS disable

        bcf  SPort,bDOUT
        bsf  SPort,REnb
        nop
        nop
        bsf  SPort,bHCK
        nop
        nop
        bcf  SPort,bHCK

        call EEStart
        movlw %00110000    ; ENABLE WRITE INSTRUCTION
        call EERdOut
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        retlw 0

EEDisable:movlw SetDataOut   ; Set HCK/DOUT/ENB as OUTPUT
        tris  C
        bcf  SPort,bHCK    ; bHCK = 0
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        bsf  SPort,PEnb    ; PEnb = 1    PLL ACCESS disable

        call EEStart
        movlw %00000000    ; DISABLE WRITE INSTRUCTION
        call EERdOut
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        retlw 0

EEWrite: movlw SetDataOut   ; Set HCK/DOUT/ENB as OUTPUT
        tris  C
        bcf  SPort,bHCK    ; bHCK = 0
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        bsf  SPort,PEnb    ; PEnb = 1    PLL ACCESS disable

        call EEStart
        movf Temp,W        ; GET Address from Temp register
        andlw %00111111    ; it's a 5 bit ADDRESS
        iorlw %01000000    ; ADD WRITE INSTRUCTION to the word
        call EERdOut
        movf Data2,W       ; Get the "HIGH WORD"
        call EERdOut
        movf Data1,W       ; Get the "LOW WORD"
        call EERdOut

        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        nop                ; NOW, waiting for acknowledge
        bsf  SPort,bHCK
        nop
        clrf Temp
        bcf  SPort,bHCK
        nop
        bsf  SPort,REnb
        movlw MaxWriteTime
        movwf CounterA

EEWait_1:bsf SPort,bHCK
        nop
        nop
        btfsc SPort,bDIn
        goto EEWait_2
        nop
        bcf SPort,bHCK
        nop
        decfsz Temp
        goto EEWait_1
        decfsz CounterA
        goto EEWait_1
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        retlw 1            ; return "1" there is a problem to write th WORD !!!

EEWait_2:bcf  SPort,bHCK
        bcf  SPort,REnb    ; REnb = 0    ROM ACCESS disable
        retlw 0            ; return "0", OK.

;>>>>>> END OF SAMPLE CODE

1995\11\09@223809 by Tesaro Sandu

flavicon
face
Hello all ..
sorry about the topic .. its a different one  ..

we are doing a project with the PIC16C54-lp/p, the supply voltage is 3V
and the Xtal is 32.786 kHz .(watch crystal)..

it basically just gets the result from 4 swithes, and flashes a LED
acordingly..

Our problem is that some do not want to start. The crystal does not want
to start on some units. We are using 33p caps with them .. We have tried
different values, and we still get the same problem ...

We tried the delayed reset .. still is the same problem...

HELP ;)


Any ideas pplz ...  --
------------------------------------------------------------------------------

    Quote : Ambition is the key to success.
            Do you listen to your heart or someone elses ?
            Life is short, Make the most of it!

    Tesaro Sandu                   or                   Love-God (IRC)

                        call on  : (0416) 141 818
                   email on : tsanduspamKILLspamst.nepean.uws.edu.au
          http: //http://www.st.nepean.uws.edu.au/users/tsandu/index.html

------------------------------------------------------------------------------

1995\11\09@225719 by Brad Phillips

flavicon
face
About those watch crystals....

I had the same problem a few days ago. Try some 47pF caps and see how you
go - this was my solution.
cheers, Brad

More... (looser matching)
- Last day of these posts
- In 1995 , 1996 only
- Today
- New search...