RX72M enabling CLKOCR ( Clock out pin) using Pin Function Control Register. PLEASE HELP.

Hi Guys, can you please help me setup the peripheral pin select for the CLOCKOUT pin. On the RX72M 176pin the clockout pin is PORT2 BIT 5.

Here's what I've done and still no clock output on PORT2 bit 5.

; TURN ON CLOCKOUT PIN38 P25

		MOV.L #PWPR,R1	; WRITE- PROTECT REGISTER
		MOV.B #0,[R1]	; WRITE 0 FIRST
		MOV.B #64,[R1]	; THEN WRITE 1 TO BIT 6
		NOP
; -------------
		MOV.L #CKOCR,R1
		MOV.W #0,[R1]
; -------------
		MOV.L #PORT2_PIN5_FUNC_CTRL,R1
		MOV.B #101010b,[R1]

Info on the P2n OIN Function Control Register is on page 23.2.4. I'm new to the Pin Function Control Registers so if you can please help me understand that would be VERY much appreciated.

Thanks guys, hope to hear from you soon.

Peter Slight smile

Parents Reply Children
No Data