Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
U
ucbus-stepper
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jake Read
ucbus-stepper
Commits
073f103c
Commit
073f103c
authored
3 years ago
by
Jake Read
Browse files
Options
Downloads
Patches
Plain Diff
stepper firmware now tracks most up-to-date bus work
parent
5902196a
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
firmware/stepper-drop/src/main.cpp
+2
-39
2 additions, 39 deletions
firmware/stepper-drop/src/main.cpp
firmware/stepper-drop/src/osape-d51
+1
-1
1 addition, 1 deletion
firmware/stepper-drop/src/osape-d51
with
3 additions
and
40 deletions
firmware/stepper-drop/src/main.cpp
+
2
−
39
View file @
073f103c
...
...
@@ -151,6 +151,7 @@ void setup() {
ERRLIGHT_SETUP
;
CLKLIGHT_SETUP
;
DEBUG1PIN_SETUP
;
// limit switch
//limitSetup();
// osap
...
...
@@ -175,47 +176,13 @@ void setup() {
osapAddVertex
(
homeStateEp
);
// 8
// stepper init
stepper_hw
->
init
(
false
,
c_scale
);
// bare serial
//Serial.begin(9600);
//ucBusDrop_setup(true, 0);
}
// have available,
// stepper_hw->setCurrent(currentChunks[AXIS_PICK].f);
//#define TEST_TX
unsigned
long
lastTx
=
0
;
uint8_t
tstTx
[
14
]
=
{
1
,
2
,
3
,
4
,
5
,
0
,
7
,
8
,
9
,
10
,
11
,
12
,
13
,
14
};
uint8_t
tstRx
[
256
];
uint8_t
testRx
[
256
];
void
loop
()
{
/*
if(ucBusDrop_ctrB()){
ERRLIGHT_TOGGLE;
uint16_t len = ucBusDrop_readB(tstRx);
logPacket(tstRx, len);
if(ucBusDrop_ctsB()){
CLKLIGHT_TOGGLE;
ucBusDrop_transmitB(tstRx, len);
}
}
*/
osapLoop
();
stepper_hw
->
dacRefresh
();
#ifdef TEST_TX
if
(
millis
()
>
lastTx
+
500
){
lastTx
=
millis
();
if
(
ucBusDrop_ctsB
()){
ERRLIGHT_TOGGLE
;
ucBusDrop_transmitB
(
tstTx
,
14
);
for
(
uint8_t
i
=
0
;
i
<
14
;
i
++
){
//tstTx[i] ++;
}
}
}
#endif
/*
// still not sure: this registers as "made" on init (?)
if(limitIsMade()){
...
...
@@ -237,8 +204,6 @@ volatile float move_counter = 0.0F;
volatile
boolean
setBlock
=
false
;
void
ucBusDrop_onPacketARx
(
uint8_t
*
inBufferA
,
volatile
uint16_t
len
){
#warning debug-d out
return
;
// don't execute when we have been given a set-position block
if
(
setBlock
)
return
;
// don't execute if we are currently homing
...
...
@@ -314,8 +279,6 @@ void ucBusDrop_onPacketARx(uint8_t* inBufferA, volatile uint16_t len){
}
void
ucBusDrop_onRxISR
(
void
){
#warning debug-d out
return
;
// no-op when given a set block,
if
(
setBlock
)
return
;
// incremental motion if is homing
...
...
This diff is collapsed.
Click to expand it.
osape-d51
@
eeabe1a1
Compare
af5f9a0e
...
eeabe1a1
Subproject commit
af5f9a0e004a6134b38f0f1996bebda271f9c655
Subproject commit
eeabe1a173dc1c7270b0099a7a1a0e0e7735e1be
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment