0
\$\begingroup\$

I am using an AduC841 microcontroller programed using assembly language(8051). when using MOVX commands to read/write from internal XRAM to DAC,my oscilloscope shows the value of the DTPR rather than the object pointed to. How do I out put from memory? the command I'm using is MOVX A,@DPTR; and then MOV DAC0L,A; (I had tried to implement a scope in normal mode using XY of a scope as display, for a school project, but whenever a one time trigger event occurred it showed a sawtooth wave, so I devised a test program which showed that I was receiving the DPTR value)

asked Jan 31, 2016 at 16:09
\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

The special function register (SFR) at"0AFh",called "CFG841" configures the controller. bit 0 ,if set to '1' tells it to use INTERNAL XRAM. If set to '0' it uses external XRAM. the default value of the register is "00h" so it must be set. This solves the practical problem, but the question remains: Why does the controller output the value of the pointer when there is no memory access?

answered Jan 31, 2016 at 17:40
\$\endgroup\$

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.