i got it, i didnt realize i was so close to completing =). Next step is include my GUI program that i have seperate. Thank you so much guys i got it from here, you guys helped clear things up for me.
Type: Posts; User: williamsant
i got it, i didnt realize i was so close to completing =). Next step is include my GUI program that i have seperate. Thank you so much guys i got it from here, you guys helped clear things up for me.
Yeah, i guess you are right, i am done. By number i meant the "char" my c program is sending sorry for not being specific. My c program is just sending char by char, and i want my java to read char...
i tried sending 9 numbers and it displays the same as before but a 57 there. so im guessing it keeps reading the numbers but it does not store it anywhere. im guessing it erases the previous number...
When i add this, it prints the following:
49
50
51
52
53
54
55
56
The following code is my java code.
import java.io.*;
import java.util.*; //import gnu.io.*;
import javax.comm.*;
public class SimpleRead implements Runnable, SerialPortEventListener {
...
what i did, is read byte by byte, and the following came as a result:
1 and 7 squares
2 and 7 squares
3 and 7 squares
4 and 7 squares
5 and 7 squares
I am gonna be working on this for the rest of the day ill post the program when i get to that step, thanks.
The program i have now is a bit too confusion for me, is it possible you can help me create a program which just reads variables from a port because im trying to shed some code from this code and i...
so i did test it in terminal, my board works fine, i make it send "12345" every 5 seconds on 1 line, so there is 1 line sending every 5 seconds saying "12345". When i run it with this code, im...
Yea the code works. Actually, i have managed to forge a code which does read serial bit's though a serial port in java. What i am using is a chip called HCS12, which is a small microcontroller. The...
Ok the idea is that i want to use serial communication in java, using javax.comm. What i want to do exactly is read a line though serial communication and save it in an array. For example every time...