Convert and transmit

Status
Not open for further replies.

ttbuddy

New Member
Wow....it took me whole day to settle my configurations for the pins. Now what i need to do is having UART over pre-built hardware UART on RB5 of 16F88. I am now having a variable called AmpHour which is stored as this:

Code:
calc_Ah:
	add1632	Amps,AmpSum	; AmpSum = accumulated Amps
	mov32	AmpSum,dd
	movi16	3600*3,aa	; 3 reads per second, 3600 seconds per hour
	call	Div32		; AmpHours = AmpSum  / (reads per hour)
store_Ah:
	mov16	dd+2,AmpHours
It is a 16 bits binary. I need to convert it to human readable ASCII and send it using UART. Huh....learning by the way..
 
Last edited:
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…