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.

simple code problem

Status
Not open for further replies.

neelam29

New Member
Hi,
last night i was trying to interface ADE7754 with 89c51. I just gave 220 v AC voltage at Phase A input (via 1Mohm/1K resistor network) and read the value of AVrms register which is showing a huge value which changes with change in voltage. But the value is too large than maximum possible.

I doubt in one part of my code. Should the code be written as :-

CLR C
SETB SCLK
CLR SCLK ;SERIAL CLOCK TO ADE7754

MOV C, DOUT ;DOUT IS DATA OUT OF ADE7754
RLC A


or should this be as below????

CLR C
SETB SCLK

MOV C, DOUT
RLC A

CLR SCLK ;CLR SCLK SHOULD BE DONE AFTER RLC?????

Thanks
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top