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. I'm working on a project involving a java program and the micro controller NXP P89v664.
The java program which utilises the RXTX package, outputs to the serial port a string of characters to be deciphered by the micro controller.
My java program is completed and outputs correctly as checked by virtual com ports and a c program.
I have written a keil c program to receive the input but I somehow receive random inputs instead.
I used the _getkey() fuction to receive the input and putchar() function to check the output.
I'm new to keil c can anyone shed some light on this pls?
Thanks.
TH1 = (unsigned char) (256 - (18432000 / (16L * 12L * baudrate))); //18432000=Crystal freq set in the project options.
Interesting line. So you want 16 and 12 to be long constants. But does 18432000 seem like it fits in a 16-bit int?