Skip to content
Snippets Groups Projects
Commit 437d197c authored by Jake Read's avatar Jake Read
Browse files

invert!

parent 4d34a339
Branches
No related tags found
No related merge requests found
......@@ -72,7 +72,7 @@ Package="8-MSOP-FAB"
Type="Board Editor"
Number=2
File="fab-step-ucbus.brd"
View="5.46577 -7.35987 53.2628 45.1766"
View="15.3672 -9.80361 55.198 33.9768"
WireWidths=" 0.1016 0.127 0.2 1.016 1.27 2.54 0.15 0.0762 0.4064 0.254 0.508 0.6096 0.8128 0.1524 0.2032 0.3048"
PadDiameters=" 0.254 0.3048 0.4064 0.6096 0.8128 1.016 1.27 1.4224 1.6764 1.778 1.9304 2.1844 2.54 3.81 6.4516 0"
PadDrills=" 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.65 0.7 0.75 0.8 0.85 0.9 1 0.6"
......@@ -116,7 +116,7 @@ Layer=1
Type="Schematic Editor"
Number=1
File="fab-step-ucbus.sch"
View="-45.6318 -41.6491 418.164 207.16"
View="83.7509 2.30664 239.075 85.6323"
WireWidths=" 0.0762 0.1016 0.127 0.15 0.2 0.2032 0.254 0.3048 0.4064 0.508 0.6096 0.8128 1.016 1.27 2.54 0.1524"
PadDiameters=" 0.254 0.3048 0.4064 0.6096 0.8128 1.016 1.27 1.4224 1.6764 1.778 1.9304 2.1844 2.54 3.81 6.4516 0"
PadDrills=" 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.65 0.7 0.75 0.8 0.85 0.9 1 0.6"
......@@ -155,7 +155,7 @@ ArcDirection=0
AddLevel=2
PadsSameType=0
Layer=91
Views=" 1: -45.6318 -41.6491 418.164 207.16"
Views=" 1: 83.7509 2.30664 239.075 85.6323"
Sheet="1"
[Win_4]
......@@ -163,7 +163,7 @@ Type="Control Panel"
Number=0
[Desktop]
Screen="1920 1080"
Screen="3171 2520"
Window="Win_1"
Window="Win_2"
Window="Win_3"
......
......@@ -73,7 +73,7 @@ Sheet="1"
Type="Board Editor"
Number=2
File="fab-step-cl.brd"
View="6.73721 19.6027 34.3972 48.5169"
View="8.79415 -3.43188 66.1499 56.5246"
WireWidths=" 0.127 0.2 1.016 1.27 2.54 0.15 0.0762 0.8128 0 0.254 0.2032 0.3048 0.4064 0.508 0.6096 0.1524"
PadDiameters=" 0.254 0.3048 0.4064 0.6096 0.8128 1.016 1.27 1.4224 1.6764 1.778 1.9304 2.1844 2.54 3.81 6.4516 0"
PadDrills=" 0.2 0.25 0.3 0.35 0.4 0.45 0.5 0.55 0.65 0.7 0.75 0.8 0.85 0.9 1 0.6"
......@@ -118,7 +118,7 @@ Type="Control Panel"
Number=0
[Desktop]
Screen="1920 1080"
Screen="3171 2520"
Window="Win_1"
Window="Win_2"
Window="Win_3"
......@@ -135,6 +135,8 @@ void loop() {
}
}
// -------------------------------------------------------- BUS INTERRUPT / STEP
uint8_t stepCache[2];
volatile uint8_t cachePtr = 0;
volatile boolean stepValid = false;
......@@ -155,7 +157,11 @@ void ucBusDrop_onRxISR(void){
// extract our step mask
stepMask = 0b00000011 & (stepCache[cachePtr] >> (axisPick * 2));
// mask -> step api:
if(invert){
(stepMask & 0b00000001) ? step_a4950_dir(true) : step_a4950_dir(false); // dir bit,
} else {
(stepMask & 0b00000001) ? step_a4950_dir(false) : step_a4950_dir(true); // dir bit,
}
if (stepMask & 0b00000010) step_a4950_step(); // step bit
// increment ptr -> next step mask, if over-wrap, steps no longer valid
cachePtr ++; if(cachePtr >= 2) stepValid = false;
......
......@@ -168,7 +168,7 @@ Assembling this now,
| 10uF 1206 | 2 |
| 10uF 0805 | 1 |
| LED 0805 | 2 |
| 100mOhm 1206 | 2 |
| 300mOhm 1206 | 2 |
| 470R | 2 |
| 10k | 2 |
| 1M | 1 |
......@@ -178,6 +178,7 @@ Assembling this now,
| RS485 | 2 |
| DRV | 1 |
| D21 | 1 |
| Vertical USB | 1 |
The two sizes of 10uf was a mistake, corrected that now.
......@@ -337,3 +338,7 @@ OK I've diffed all that... need to make a microstep update actually do something
12520 / 24976
Done, for the time being. Probably needs in-mcu guards against large rates.
## 2022 01 11
Back to assembling the -cl versions here.
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment