We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi everybody ! I have 2 boards, one with 80C517 and other with PIC16F628. With the C517 I measure speed and the PIC is controlling the displays. I need to send the velocity information (it is an integer value - 100 means 100km/h, for example) from C517 to PIC through serial. The PIC board have the following protocol: abc0E, were a=LSB, c=MSB and E is 'E' ASCII value just to say it is the 'end'. After this string I have to send an 'Enter'. I have to "broke" my speed value (integer) into 3 parts (abc). How can I do this with keil C ???? Thanks in advance, Luis
Why not let printf do the work for you? unsigned char speed; printf("%3d0E",speed); The magnitude ordering is reversed but changing the access to the receive buffer can fix that.