projects
/
fw
/
altos
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'buttonbox' of git://git.gag.com/fw/altos into buttonbox
[fw/altos]
/
ao-tools
/
altosui
/
AltosDebug.java
diff --git
a/ao-tools/altosui/AltosDebug.java
b/ao-tools/altosui/AltosDebug.java
index ca2e5a9046625465130c0f4dd1ec55f9c10cba48..8d435b667d5ecb584b118bed27a5d9945b4abb92 100644
(file)
--- a/
ao-tools/altosui/AltosDebug.java
+++ b/
ao-tools/altosui/AltosDebug.java
@@
-19,11
+19,10
@@
package altosui;
import java.lang.*;
import java.io.*;
import java.lang.*;
import java.io.*;
-import java.util.concurrent.LinkedBlockingQueue;
-import java.util.LinkedList;
-import java.util.Iterator;
-import altosui.AltosSerial;
-import altosui.AltosRomconfig;
+import java.util.concurrent.*;
+import java.util.*;
+
+import libaltosJNI.*;
public class AltosDebug extends AltosSerial {
public class AltosDebug extends AltosSerial {
@@
-62,8
+61,8
@@
public class AltosDebug extends AltosSerial {
void ensure_debug_mode() {
if (!debug_mode) {
void ensure_debug_mode() {
if (!debug_mode) {
- printf("
m 0\n
D\n");
- flush_
reply
();
+ printf("D\n");
+ flush_
input
();
debug_mode = true;
}
}
debug_mode = true;
}
}
@@
-103,7
+102,7
@@
public class AltosDebug extends AltosSerial {
throws IOException, InterruptedException {
byte[] data = new byte[length];
throws IOException, InterruptedException {
byte[] data = new byte[length];
- flush_
reply
();
+ flush_
input
();
ensure_debug_mode();
printf("I %x %x\n", length, address);
int i = 0;
ensure_debug_mode();
printf("I %x %x\n", length, address);
int i = 0;
@@
-155,7
+154,7
@@
public class AltosDebug extends AltosSerial {
public byte[] read_bytes(int length)
throws IOException, InterruptedException {
public byte[] read_bytes(int length)
throws IOException, InterruptedException {
- flush_
reply
();
+ flush_
input
();
ensure_debug_mode();
printf("G %x\n", length);
int i = 0;
ensure_debug_mode();
printf("G %x\n", length);
int i = 0;
@@
-261,4
+260,8
@@
public class AltosDebug extends AltosSerial {
public void reset() {
printf ("R\n");
}
public void reset() {
printf ("R\n");
}
+
+ public AltosDebug (AltosDevice in_device) throws FileNotFoundException, AltosSerialInUseException {
+ super(in_device);
+ }
}
\ No newline at end of file
}
\ No newline at end of file