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.

8085 weird problem

Status
Not open for further replies.

prescott2006

New Member
we were requested to interface 8085 with memory and led,then a routine need to be written to make the led light up one at a time with delay 1 second.we have simulate the program and it run perfectly but when we test on the circuit we built it doesn't work.after a lot of trial and error,finally we found that answer,the 8085 does not recognize DCX,it only recognize DCR,so we only change the DCX in our original program to DCR to perform delay.do you guy know why the 8085 behave like this?simply does not recognize the DCX instruction.our lecturer also say never seen this before.
 
Most likely it is your assembler/compiler that doesn't understand the DCX instruction. Have you looked at the HEX code (decompiled it)?
 
Last edited:
Your simulator will establish initial conditions that are not guaranteed on an actual microprocessor. If I recall correctly, the 8085 "hardware reset" is simply a non-maskable interrupt vectored to 0000H. No registers are initialized!

Did you initialize the register pair before using it?
 
Last edited:
If your using a 8 bit data slice then you should use DCR, I think DCX is for two bytes. I never used 8085 instruction set before as it is so old but that is my guess.
 
Good catch! Most importantly, DCX does not affect flags, so it would appear that the instruction is ignored.

I'll bet the trainer/simulator mistakenly sets the flags!
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top