Maker Pro
Maker Pro

how to set RBPU bit in OPTION register

milen

Dec 20, 2009
17
Joined
Dec 20, 2009
Messages
17
I want to set rbpu bit to be 0 so I will enable portb internal pull ups in PIC mcu.
I am using mikropascal compiler and when I write "OPTION_REG:=value;" the command is excepted, but if I want to set particular bit as "OPTION_REG.RBPU:=0" the command isn't accepted.

For comparison the compiler excepts this line OSCCON.IRCF2:=1; where you set oscilator freq bits.
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
option_reg.7 := 0 seems to be the way to go.
 
Top