I have to build code for a 3-8 decoder anyone have basic structure?
output = 1 << (state & 7); // where state is 3-bits (0-7), and output is 8-bits wide
THE 3 BIT INPUT CODE SHOULD APPEAR on p0.2 p0.1 p0.0 out put should appear on one of the eight pins of port one... using h'30 thru h'37
iam completely in the dark about this
Need to look at a Datasheet of the chip you have on the board. And check the mapping of Port 0 and Port 1 pins with the internal signalling of the ports. I was looking at a book on the web maybe inconsistent with the pin locations you are describing.
Also should look at the Schematic of the board to gain information.
Did you just not show up in class, or is the institution/professor inept?
You are using what processor? You have to write this in C or Assembler? You have course work/notes? You have written what so far?