mirror of
https://github.com/sethm/symon.git
synced 2025-08-08 20:25:01 +00:00
NPE fix and reset position on every command
This commit is contained in:
@@ -54,7 +54,7 @@ public class SdController extends Device {
|
|||||||
private int lba0,lba1,lba2;
|
private int lba0,lba1,lba2;
|
||||||
private int command;
|
private int command;
|
||||||
private int position;
|
private int position;
|
||||||
private Status status;
|
private Status status = Status.IDLE;
|
||||||
|
|
||||||
|
|
||||||
public SdController(int address) throws MemoryRangeException {
|
public SdController(int address) throws MemoryRangeException {
|
||||||
@@ -161,6 +161,7 @@ public class SdController extends Device {
|
|||||||
default:
|
default:
|
||||||
this.status = Status.IDLE;
|
this.status = Status.IDLE;
|
||||||
}
|
}
|
||||||
|
computePosition();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Reference in New Issue
Block a user