Home
Prox / RFID
Verichips
Ladder Logic
[interfacing] †
Tube Joints
Key Code From Photo
SolveSpace (3d CAD)
SketchFlat (2d CAD)
Photographs
Miscellany
Resume / Consulting
Contact Me

LDmicro Forum - Moving the bytes in an 8-bit port on the condition

(you are viewing a thread; or go back to list of threads)

Moving the bytes in an 8-bit port on the condition (by maxxir)
Hi Jonathan!
How to implement in the LdMicro following code:
if (PINA&0x01)
{
PORTB = 0x32; // Or any other value
}
else
{
PORTB = 0x89; // Or any other value
}
Can I move the byte at the condition?
Fri Jun 10 2011, 14:02:40
(no subject) (by Joao Pereira)
Hello maxxir,

You must make an converter from decimal to binary. You knwo that
----| |---| |---- this is an "AND" logic

____|---| |---|____ This is an "OR" logic
|---| |---|
Mon Jun 13 2011, 10:58:01
(no subject) (by maxxir)
I considered this way.
But it is not optimal, and not flexible.
It's not moving, and hard logic.
Tue Jun 14 2011, 14:03:28
Post a reply to this comment:
Your Name:
Your Email:
Subject:
(no HTML tags; use plain text, and hit Enter for a line break)
Attached file (if you want, 5 MB max):