rp2040js 1.1.0 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -169,6 +169,7 @@ class StateMachine {
|
|
|
169
169
|
return;
|
|
170
170
|
}
|
|
171
171
|
this.txFIFO.push(value);
|
|
172
|
+
this.pio.txStall &= ~(FDEBUG_TXSTALL << this.index);
|
|
172
173
|
this.updateDMATx();
|
|
173
174
|
this.checkWait();
|
|
174
175
|
if (this.txFIFO.full) {
|
|
@@ -181,6 +182,7 @@ class StateMachine {
|
|
|
181
182
|
return 0;
|
|
182
183
|
}
|
|
183
184
|
const result = this.rxFIFO.pull();
|
|
185
|
+
this.pio.rxStall &= ~(FDEBUG_RXSTALL << this.index);
|
|
184
186
|
this.updateDMARx();
|
|
185
187
|
this.checkWait();
|
|
186
188
|
if (this.rxFIFO.empty) {
|
|
@@ -440,7 +442,8 @@ class StateMachine {
|
|
|
440
442
|
this.pio.checkInterrupts();
|
|
441
443
|
}
|
|
442
444
|
else {
|
|
443
|
-
this.pio.
|
|
445
|
+
this.pio.rxStall |= FDEBUG_RXSTALL << this.index;
|
|
446
|
+
this.pio.fdebug |= this.pio.rxStall;
|
|
444
447
|
this.wait(WaitType.rxFIFO, false, this.inputShiftReg);
|
|
445
448
|
}
|
|
446
449
|
this.inputShiftCount = 0;
|
|
@@ -458,7 +461,8 @@ class StateMachine {
|
|
|
458
461
|
this.pio.checkInterrupts();
|
|
459
462
|
}
|
|
460
463
|
else {
|
|
461
|
-
this.pio.
|
|
464
|
+
this.pio.txStall |= FDEBUG_TXSTALL << this.index;
|
|
465
|
+
this.pio.fdebug |= this.pio.txStall;
|
|
462
466
|
this.wait(WaitType.Out, false, arg);
|
|
463
467
|
}
|
|
464
468
|
}
|
|
@@ -488,7 +492,8 @@ class StateMachine {
|
|
|
488
492
|
this.pio.checkInterrupts();
|
|
489
493
|
}
|
|
490
494
|
else {
|
|
491
|
-
this.pio.
|
|
495
|
+
this.pio.txStall |= FDEBUG_TXSTALL << this.index;
|
|
496
|
+
this.pio.fdebug |= this.pio.txStall;
|
|
492
497
|
if (block) {
|
|
493
498
|
this.wait(WaitType.txFIFO, false, 0);
|
|
494
499
|
}
|
|
@@ -511,7 +516,8 @@ class StateMachine {
|
|
|
511
516
|
this.pio.checkInterrupts();
|
|
512
517
|
}
|
|
513
518
|
else {
|
|
514
|
-
this.pio.
|
|
519
|
+
this.pio.rxStall |= FDEBUG_RXSTALL << this.index;
|
|
520
|
+
this.pio.fdebug |= this.pio.rxStall;
|
|
515
521
|
if (block) {
|
|
516
522
|
this.wait(WaitType.rxFIFO, false, this.inputShiftReg);
|
|
517
523
|
}
|
|
@@ -831,6 +837,8 @@ class RPPIO extends peripheral_js_1.BasePeripheral {
|
|
|
831
837
|
];
|
|
832
838
|
this.stopped = true;
|
|
833
839
|
this.fdebug = 0;
|
|
840
|
+
this.txStall = 0;
|
|
841
|
+
this.rxStall = 0;
|
|
834
842
|
this.inputSyncBypass = 0;
|
|
835
843
|
this.irq = 0;
|
|
836
844
|
this.pinValues = 0;
|
|
@@ -977,6 +985,7 @@ class RPPIO extends peripheral_js_1.BasePeripheral {
|
|
|
977
985
|
}
|
|
978
986
|
case FDEBUG:
|
|
979
987
|
this.fdebug &= ~this.rawWriteValue;
|
|
988
|
+
this.fdebug |= this.txStall | this.rxStall;
|
|
980
989
|
break;
|
|
981
990
|
case TXF0:
|
|
982
991
|
this.machines[0].writeFIFO(value);
|
|
@@ -166,6 +166,7 @@ export class StateMachine {
|
|
|
166
166
|
return;
|
|
167
167
|
}
|
|
168
168
|
this.txFIFO.push(value);
|
|
169
|
+
this.pio.txStall &= ~(FDEBUG_TXSTALL << this.index);
|
|
169
170
|
this.updateDMATx();
|
|
170
171
|
this.checkWait();
|
|
171
172
|
if (this.txFIFO.full) {
|
|
@@ -178,6 +179,7 @@ export class StateMachine {
|
|
|
178
179
|
return 0;
|
|
179
180
|
}
|
|
180
181
|
const result = this.rxFIFO.pull();
|
|
182
|
+
this.pio.rxStall &= ~(FDEBUG_RXSTALL << this.index);
|
|
181
183
|
this.updateDMARx();
|
|
182
184
|
this.checkWait();
|
|
183
185
|
if (this.rxFIFO.empty) {
|
|
@@ -437,7 +439,8 @@ export class StateMachine {
|
|
|
437
439
|
this.pio.checkInterrupts();
|
|
438
440
|
}
|
|
439
441
|
else {
|
|
440
|
-
this.pio.
|
|
442
|
+
this.pio.rxStall |= FDEBUG_RXSTALL << this.index;
|
|
443
|
+
this.pio.fdebug |= this.pio.rxStall;
|
|
441
444
|
this.wait(WaitType.rxFIFO, false, this.inputShiftReg);
|
|
442
445
|
}
|
|
443
446
|
this.inputShiftCount = 0;
|
|
@@ -455,7 +458,8 @@ export class StateMachine {
|
|
|
455
458
|
this.pio.checkInterrupts();
|
|
456
459
|
}
|
|
457
460
|
else {
|
|
458
|
-
this.pio.
|
|
461
|
+
this.pio.txStall |= FDEBUG_TXSTALL << this.index;
|
|
462
|
+
this.pio.fdebug |= this.pio.txStall;
|
|
459
463
|
this.wait(WaitType.Out, false, arg);
|
|
460
464
|
}
|
|
461
465
|
}
|
|
@@ -485,7 +489,8 @@ export class StateMachine {
|
|
|
485
489
|
this.pio.checkInterrupts();
|
|
486
490
|
}
|
|
487
491
|
else {
|
|
488
|
-
this.pio.
|
|
492
|
+
this.pio.txStall |= FDEBUG_TXSTALL << this.index;
|
|
493
|
+
this.pio.fdebug |= this.pio.txStall;
|
|
489
494
|
if (block) {
|
|
490
495
|
this.wait(WaitType.txFIFO, false, 0);
|
|
491
496
|
}
|
|
@@ -508,7 +513,8 @@ export class StateMachine {
|
|
|
508
513
|
this.pio.checkInterrupts();
|
|
509
514
|
}
|
|
510
515
|
else {
|
|
511
|
-
this.pio.
|
|
516
|
+
this.pio.rxStall |= FDEBUG_RXSTALL << this.index;
|
|
517
|
+
this.pio.fdebug |= this.pio.rxStall;
|
|
512
518
|
if (block) {
|
|
513
519
|
this.wait(WaitType.rxFIFO, false, this.inputShiftReg);
|
|
514
520
|
}
|
|
@@ -827,6 +833,8 @@ export class RPPIO extends BasePeripheral {
|
|
|
827
833
|
];
|
|
828
834
|
this.stopped = true;
|
|
829
835
|
this.fdebug = 0;
|
|
836
|
+
this.txStall = 0;
|
|
837
|
+
this.rxStall = 0;
|
|
830
838
|
this.inputSyncBypass = 0;
|
|
831
839
|
this.irq = 0;
|
|
832
840
|
this.pinValues = 0;
|
|
@@ -973,6 +981,7 @@ export class RPPIO extends BasePeripheral {
|
|
|
973
981
|
}
|
|
974
982
|
case FDEBUG:
|
|
975
983
|
this.fdebug &= ~this.rawWriteValue;
|
|
984
|
+
this.fdebug |= this.txStall | this.rxStall;
|
|
976
985
|
break;
|
|
977
986
|
case TXF0:
|
|
978
987
|
this.machines[0].writeFIFO(value);
|