romel_emperado
Advanced Member level 2
- Joined
- Jul 23, 2009
- Messages
- 606
- Helped
- 45
- Reputation
- 132
- Reaction score
- 65
- Trophy points
- 1,318
- Location
- philippines
- Activity points
- 6,061
guys, do you have any hint on how to program this?
this is the problem.
example if i have input in POR1 = 1111 1010
i need to know which bit is low. as seen in the example there are two low/0 values in the input... how to detect that??
actually from the example P1.0 and P1.2 are low.
i can do that using switch case but i think there is another method to do that. imagine that is 8bits i cant manage to put all that case combination by using switch case from 0 - 255. :sad:
this is the problem.
example if i have input in POR1 = 1111 1010
i need to know which bit is low. as seen in the example there are two low/0 values in the input... how to detect that??
actually from the example P1.0 and P1.2 are low.
i can do that using switch case but i think there is another method to do that. imagine that is 8bits i cant manage to put all that case combination by using switch case from 0 - 255. :sad: