It is currently 20 Apr 2018 02:16

All times are UTC + 1 hour




Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: 27 Dec 2017 23:37 
Offline

Joined: 27 Dec 2017 23:31
Posts: 1
Hello,

I would like request somebody to write me for partial routine in MIKROC
for first initialization a send data Word A and B from uP PIC to SAA1057.

thank you
regards
milandks



Today I continue to trying this Init subroutine. Is it correct? I do not have interconnect SAA1057 to PIC 16F628A yet.

sbit CLB at RB4_bit;
sbit DLEN at RB5_bit;
sbit DATA at RB6_bit;

//-----------------------------------------
// Initialize the SAA1057 PLL
//-----------------------------------------
// Do the 10 clock pulses with 10us pulse width to init SAA (see datasheet)

void init_saa(void)
{
unsigned char a;
RB5_bit = 0;
RB5_bit |= DLEN; // DLEN High for Init ??? (test)

for(a=0;a<19;a++) // 10 Clock pulses for Init
{
RB4_bit |= CLB; // CLB HIGH
Delay_us(10);
RB4_bit = ~CLB; // CLB LOW
Delay_us(10);
}

RB5_bit = ~DLEN; // DLEN Low after Init ??? (test)
}


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: