Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

here are a number of futher optimizations for the g3firmware #87

Open
wants to merge 43 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
7cd9b0b
modify code to use optimized AVR code via PinTmplt
craiglink Nov 17, 2011
acb4c13
remove bogus const's on integral return types
craiglink Nov 17, 2011
4377f13
remove bogus const
craiglink Nov 17, 2011
8fa9ae3
clean up some atomic block code
craiglink Nov 17, 2011
244912f
delete softwareservo.cc
craiglink Nov 17, 2011
a9cbd7b
add class for dual displays and modtronix
craiglink Nov 17, 2011
b79f6aa
add twi libraries for Modtronix.
craiglink Nov 17, 2011
adb5b50
custom pin changes for my bot
craiglink Nov 19, 2011
c092b0e
add condition compilation to turn off interface board, as well as jus…
craiglink Nov 19, 2011
a9bbb08
abstract out the display so that it can easily be changed
craiglink Nov 19, 2011
27daf4d
Merge branch 'optimized' into customized
craiglink Nov 19, 2011
c193f8a
customize CraigBot
craiglink Nov 19, 2011
c3341e1
display monitor if now interface buttons are present
craiglink Nov 19, 2011
093362e
Merge branch 'optimized' into customized
craiglink Nov 19, 2011
dd184f9
set the display type
craiglink Nov 19, 2011
4601bfa
turn on interface buttons
craiglink Nov 19, 2011
f5813bd
Merge branch 'optimized' into customized
craiglink Nov 19, 2011
9283ec5
turn off interface buttons
craiglink Nov 19, 2011
ddb13eb
initialize the interface outside of the atomic block because we need …
craiglink Nov 20, 2011
e412ae1
delete unused file
craiglink Nov 20, 2011
04a9f6b
adjust width of modtronix screen
craiglink Nov 20, 2011
6b218a9
initialize the interface outside of the atomic block because we need …
craiglink Nov 20, 2011
b0350c1
delete unused file
craiglink Nov 20, 2011
faeb397
adjust width of modtronix screen
craiglink Nov 20, 2011
0c8a6a0
fix liquid crystal display and make the second argument to setValue a…
craiglink Nov 22, 2011
95296e1
remove deleted files from solution
craiglink Nov 22, 2011
156fec5
delete unused file
craiglink Nov 22, 2011
8d490ed
Merge branch 'customized' into optimized
craiglink Nov 22, 2011
de31fc8
revert the ordering of steppers A and B to what users expect, even th…
craiglink Nov 22, 2011
0de55c5
missed change for 2nd parameters for the because I inverted the param…
craiglink Nov 22, 2011
f8f91ba
use inline statements where appropriate to reduce function call stack.
craiglink Dec 1, 2011
65760e8
change code to use a more efficient switch statement.
craiglink Dec 1, 2011
e2028e3
optimize position code for retrieving and appending position data.
craiglink Dec 1, 2011
f7ad615
optimized monitoring the tool during building
craiglink Dec 1, 2011
0b4a959
pre-template
craiglink Dec 1, 2011
6ae5671
comment out unused code
craiglink Dec 1, 2011
f393127
optimized packet handling. CRC of incoming packets are calculated af…
craiglink Dec 1, 2011
7ca069c
optimized and use and int16_t for PID controller
craiglink Dec 1, 2011
83b925f
remove debugging
craiglink Dec 1, 2011
b4bd882
inline a bunch of stuff and slice the temperature control across mult…
craiglink Dec 1, 2011
b7e6f0a
remove debugging code
craiglink Dec 1, 2011
7c6cd5e
remove non-standard MakerBot code - ie support for Modtronix
craiglink Dec 1, 2011
ad38c12
fix compilation of ecv22
craiglink Dec 1, 2011
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#added by jmil on 2010-04-20

.sconsign.dblite
G3Firmware.suo
build
html
*.o
158 changes: 158 additions & 0 deletions G3Firmware.sln
Original file line number Diff line number Diff line change
@@ -0,0 +1,158 @@

Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Extruder", "Extruder", "{B8BCEC9D-EBA2-47E3-A7DF-2D668B3AC267}"
ProjectSection(SolutionItems) = preProject
firmware\src\Extruder\DebugPacketProcessor.cc = firmware\src\Extruder\DebugPacketProcessor.cc
firmware\src\Extruder\DebugPacketProcessor.hh = firmware\src\Extruder\DebugPacketProcessor.hh
firmware\src\Extruder\EepromMap.cc = firmware\src\Extruder\EepromMap.cc
firmware\src\Extruder\EepromMap.hh = firmware\src\Extruder\EepromMap.hh
firmware\src\Extruder\Host.cc = firmware\src\Extruder\Host.cc
firmware\src\Extruder\Host.hh = firmware\src\Extruder\Host.hh
firmware\src\Extruder\Main.cc = firmware\src\Extruder\Main.cc
firmware\src\Extruder\Main.hh = firmware\src\Extruder\Main.hh
firmware\src\Extruder\MotorController.cc = firmware\src\Extruder\MotorController.cc
firmware\src\Extruder\MotorController.hh = firmware\src\Extruder\MotorController.hh
firmware\src\Extruder\Version.hh = firmware\src\Extruder\Version.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "shared", "shared", "{AE577DDE-9F1C-404B-9AF4-5A9C8D8BF39B}"
ProjectSection(SolutionItems) = preProject
firmware\src\shared\AnalogPin.cc = firmware\src\shared\AnalogPin.cc
firmware\src\shared\AnalogPin.hh = firmware\src\shared\AnalogPin.hh
firmware\src\shared\ButtonArray.hh = firmware\src\shared\ButtonArray.hh
firmware\src\shared\CircularBuffer.hh = firmware\src\shared\CircularBuffer.hh
firmware\src\shared\Commands.hh = firmware\src\shared\Commands.hh
firmware\src\shared\CoolingFan.cc = firmware\src\shared\CoolingFan.cc
firmware\src\shared\CoolingFan.hh = firmware\src\shared\CoolingFan.hh
firmware\src\shared\Display.hh = firmware\src\shared\Display.hh
firmware\src\shared\Eeprom.cc = firmware\src\shared\Eeprom.cc
firmware\src\shared\Eeprom.hh = firmware\src\shared\Eeprom.hh
firmware\src\shared\Heater.cc = firmware\src\shared\Heater.cc
firmware\src\shared\Heater.hh = firmware\src\shared\Heater.hh
firmware\src\shared\HeatingElement.hh = firmware\src\shared\HeatingElement.hh
firmware\src\shared\Interface.cc = firmware\src\shared\Interface.cc
firmware\src\shared\Interface.hh = firmware\src\shared\Interface.hh
firmware\src\shared\InterfaceBoard.cc = firmware\src\shared\InterfaceBoard.cc
firmware\src\shared\InterfaceBoard.hh = firmware\src\shared\InterfaceBoard.hh
firmware\src\shared\LiquidCrystal.cc = firmware\src\shared\LiquidCrystal.cc
firmware\src\shared\LiquidCrystal.hh = firmware\src\shared\LiquidCrystal.hh
firmware\src\shared\Menu.cc = firmware\src\shared\Menu.cc
firmware\src\shared\Menu.hh = firmware\src\shared\Menu.hh
firmware\src\shared\Packet.cc = firmware\src\shared\Packet.cc
firmware\src\shared\Packet.hh = firmware\src\shared\Packet.hh
firmware\src\shared\PID.cc = firmware\src\shared\PID.cc
firmware\src\shared\PID.hh = firmware\src\shared\PID.hh
firmware\src\shared\PinTmplt.hh = firmware\src\shared\PinTmplt.hh
firmware\src\shared\ProtocolDocumentation.hh = firmware\src\shared\ProtocolDocumentation.hh
firmware\src\shared\PSU.cc = firmware\src\shared\PSU.cc
firmware\src\shared\PSU.hh = firmware\src\shared\PSU.hh
firmware\src\shared\StepperAxis.cc = firmware\src\shared\StepperAxis.cc
firmware\src\shared\StepperAxis.hh = firmware\src\shared\StepperAxis.hh
firmware\src\shared\StepperInterface.hh = firmware\src\shared\StepperInterface.hh
firmware\src\shared\TemperatureSensor.hh = firmware\src\shared\TemperatureSensor.hh
firmware\src\shared\Thermistor.cc = firmware\src\shared\Thermistor.cc
firmware\src\shared\Thermistor.hh = firmware\src\shared\Thermistor.hh
firmware\src\shared\ThermistorTable.cc = firmware\src\shared\ThermistorTable.cc
firmware\src\shared\ThermistorTable.hh = firmware\src\shared\ThermistorTable.hh
firmware\src\shared\Thermocouple.cc = firmware\src\shared\Thermocouple.cc
firmware\src\shared\Thermocouple.hh = firmware\src\shared\Thermocouple.hh
firmware\src\shared\Timeout.cc = firmware\src\shared\Timeout.cc
firmware\src\shared\Timeout.hh = firmware\src\shared\Timeout.hh
firmware\src\shared\Types.hh = firmware\src\shared\Types.hh
firmware\src\shared\UART.cc = firmware\src\shared\UART.cc
firmware\src\shared\UART.hh = firmware\src\shared\UART.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Motherboard", "Motherboard", "{C51D0777-6F43-435A-B194-9FB6DE71E516}"
ProjectSection(SolutionItems) = preProject
firmware\src\Motherboard\Command.cc = firmware\src\Motherboard\Command.cc
firmware\src\Motherboard\Command.hh = firmware\src\Motherboard\Command.hh
firmware\src\Motherboard\DebugPacketProcessor.cc = firmware\src\Motherboard\DebugPacketProcessor.cc
firmware\src\Motherboard\DebugPacketProcessor.hh = firmware\src\Motherboard\DebugPacketProcessor.hh
firmware\src\Motherboard\EepromMap.cc = firmware\src\Motherboard\EepromMap.cc
firmware\src\Motherboard\EepromMap.hh = firmware\src\Motherboard\EepromMap.hh
firmware\src\Motherboard\Errors.hh = firmware\src\Motherboard\Errors.hh
firmware\src\Motherboard\Host.cc = firmware\src\Motherboard\Host.cc
firmware\src\Motherboard\Host.hh = firmware\src\Motherboard\Host.hh
firmware\src\Motherboard\Main.cc = firmware\src\Motherboard\Main.cc
firmware\src\Motherboard\Main.hh = firmware\src\Motherboard\Main.hh
firmware\src\Motherboard\Point.hh = firmware\src\Motherboard\Point.hh
firmware\src\Motherboard\SDCard.cc = firmware\src\Motherboard\SDCard.cc
firmware\src\Motherboard\SDCard.hh = firmware\src\Motherboard\SDCard.hh
firmware\src\Motherboard\Steppers.cc = firmware\src\Motherboard\Steppers.cc
firmware\src\Motherboard\Steppers.hh = firmware\src\Motherboard\Steppers.hh
firmware\src\Motherboard\Tool.cc = firmware\src\Motherboard\Tool.cc
firmware\src\Motherboard\Tool.hh = firmware\src\Motherboard\Tool.hh
firmware\src\Motherboard\Version.hh = firmware\src\Motherboard\Version.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "mb24", "mb24", "{C338C176-CD4F-4133-8B44-BA1B2EFD66B8}"
ProjectSection(SolutionItems) = preProject
firmware\src\Motherboard\boards\mb24\ButtonArray.cc = firmware\src\Motherboard\boards\mb24\ButtonArray.cc
firmware\src\Motherboard\boards\mb24\Configuration.hh = firmware\src\Motherboard\boards\mb24\Configuration.hh
firmware\src\Motherboard\boards\mb24\Motherboard.cc = firmware\src\Motherboard\boards\mb24\Motherboard.cc
firmware\src\Motherboard\boards\mb24\Motherboard.hh = firmware\src\Motherboard\boards\mb24\Motherboard.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "rrmbv12", "rrmbv12", "{5B20E4BA-3A26-4273-8495-099508DE2D96}"
ProjectSection(SolutionItems) = preProject
firmware\src\Motherboard\boards\rrmbv12\Configuration.hh = firmware\src\Motherboard\boards\rrmbv12\Configuration.hh
firmware\src\Motherboard\boards\rrmbv12\Motherboard.cc = firmware\src\Motherboard\boards\rrmbv12\Motherboard.cc
firmware\src\Motherboard\boards\rrmbv12\Motherboard.hh = firmware\src\Motherboard\boards\rrmbv12\Motherboard.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "lib_sd", "lib_sd", "{656CB7F3-AB12-4881-9A8F-22644216D524}"
ProjectSection(SolutionItems) = preProject
firmware\src\Motherboard\lib_sd\byteordering.c = firmware\src\Motherboard\lib_sd\byteordering.c
firmware\src\Motherboard\lib_sd\byteordering.h = firmware\src\Motherboard\lib_sd\byteordering.h
firmware\src\Motherboard\lib_sd\ChangeLog = firmware\src\Motherboard\lib_sd\ChangeLog
firmware\src\Motherboard\lib_sd\fat.c = firmware\src\Motherboard\lib_sd\fat.c
firmware\src\Motherboard\lib_sd\fat.h = firmware\src\Motherboard\lib_sd\fat.h
firmware\src\Motherboard\lib_sd\fat_config.h = firmware\src\Motherboard\lib_sd\fat_config.h
firmware\src\Motherboard\lib_sd\partition.c = firmware\src\Motherboard\lib_sd\partition.c
firmware\src\Motherboard\lib_sd\partition.h = firmware\src\Motherboard\lib_sd\partition.h
firmware\src\Motherboard\lib_sd\partition_config.h = firmware\src\Motherboard\lib_sd\partition_config.h
firmware\src\Motherboard\lib_sd\README.txt = firmware\src\Motherboard\lib_sd\README.txt
firmware\src\Motherboard\lib_sd\sd-reader_config.h = firmware\src\Motherboard\lib_sd\sd-reader_config.h
firmware\src\Motherboard\lib_sd\sd_raw.c = firmware\src\Motherboard\lib_sd\sd_raw.c
firmware\src\Motherboard\lib_sd\sd_raw.h = firmware\src\Motherboard\lib_sd\sd_raw.h
firmware\src\Motherboard\lib_sd\sd_raw_config.h = firmware\src\Motherboard\lib_sd\sd_raw_config.h
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "boards", "boards", "{2BF72BB7-EC26-4DFE-AE91-AA5F8996EF2A}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ecv22", "ecv22", "{717E20D4-3D03-4098-BC43-782400939F44}"
ProjectSection(SolutionItems) = preProject
firmware\src\Extruder\boards\ecv22\Configuration.hh = firmware\src\Extruder\boards\ecv22\Configuration.hh
firmware\src\Extruder\boards\ecv22\ExtruderBoard.cc = firmware\src\Extruder\boards\ecv22\ExtruderBoard.cc
firmware\src\Extruder\boards\ecv22\ExtruderBoard.hh = firmware\src\Extruder\boards\ecv22\ExtruderBoard.hh
firmware\src\Extruder\boards\ecv22\ExtruderMotor.cc = firmware\src\Extruder\boards\ecv22\ExtruderMotor.cc
firmware\src\Extruder\boards\ecv22\ExtruderMotor.hh = firmware\src\Extruder\boards\ecv22\ExtruderMotor.hh
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "ecv34", "ecv34", "{489403D6-ED19-4806-9E94-093A2570008C}"
ProjectSection(SolutionItems) = preProject
firmware\src\Extruder\boards\ecv34\.UART.cc.swp = firmware\src\Extruder\boards\ecv34\.UART.cc.swp
firmware\src\Extruder\boards\ecv34\Configuration.cc = firmware\src\Extruder\boards\ecv34\Configuration.cc
firmware\src\Extruder\boards\ecv34\Configuration.hh = firmware\src\Extruder\boards\ecv34\Configuration.hh
firmware\src\Extruder\boards\ecv34\ExtruderBoard.cc = firmware\src\Extruder\boards\ecv34\ExtruderBoard.cc
firmware\src\Extruder\boards\ecv34\ExtruderBoard.hh = firmware\src\Extruder\boards\ecv34\ExtruderBoard.hh
firmware\src\Extruder\boards\ecv34\ExtruderMotor.cc = firmware\src\Extruder\boards\ecv34\ExtruderMotor.cc
firmware\src\Extruder\boards\ecv34\ExtruderMotor.hh = firmware\src\Extruder\boards\ecv34\ExtruderMotor.hh
firmware\src\Extruder\boards\ecv34\SoftwareServo.hh = firmware\src\Extruder\boards\ecv34\SoftwareServo.hh
EndProjectSection
EndProject
Global
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{2BF72BB7-EC26-4DFE-AE91-AA5F8996EF2A} = {B8BCEC9D-EBA2-47E3-A7DF-2D668B3AC267}
{C338C176-CD4F-4133-8B44-BA1B2EFD66B8} = {C51D0777-6F43-435A-B194-9FB6DE71E516}
{5B20E4BA-3A26-4273-8495-099508DE2D96} = {C51D0777-6F43-435A-B194-9FB6DE71E516}
{656CB7F3-AB12-4881-9A8F-22644216D524} = {C51D0777-6F43-435A-B194-9FB6DE71E516}
{717E20D4-3D03-4098-BC43-782400939F44} = {2BF72BB7-EC26-4DFE-AE91-AA5F8996EF2A}
{489403D6-ED19-4806-9E94-093A2570008C} = {2BF72BB7-EC26-4DFE-AE91-AA5F8996EF2A}
EndGlobalSection
EndGlobal
2 changes: 2 additions & 0 deletions firmware/src/Extruder/DebugPacketProcessor.cc
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,12 @@ bool processDebugPacket(const InPacket& from_host, OutPacket& to_host) {
to_host.append8(from_host.read8(i));
}
return true;
/*
} else if (command == CommandCode::DEBUG_GENERATE_BAD_PACKET) {
// TODO
} else if (command == CommandCode::DEBUG_SIMULATE_BAD_PACKET) {
// TODO
*/
} else if (command == CommandCode::DEBUG_SLAVE_PASSTHRU) {
return true;
}
Expand Down
16 changes: 8 additions & 8 deletions firmware/src/Extruder/Main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,16 @@
#include "MotorController.hh"

void reset() {
cli();
ATOMIC_BLOCK(ATOMIC_FORCEON) {

uint8_t resetFlags = MCUSR & 0x0f;
MCUSR = 0x0;
uint8_t resetFlags = MCUSR & 0x0f;
MCUSR = 0x0;

// Intialize various modules
initThermistorTables();
eeprom::init();
ExtruderBoard::getBoard().reset(resetFlags);
sei();
// Intialize various modules
initThermistorTables();
eeprom::init();
ExtruderBoard::getBoard().reset(resetFlags);
}
}

int main() {
Expand Down
2 changes: 2 additions & 0 deletions firmware/src/Extruder/boards/ecv22/Configuration.hh
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
#ifndef BOARDS_ECV22_CONFIGURATION_HH_
#define BOARDS_ECV22_CONFIGURATION_HH_

#include "PinTmplt.hh"

// Board configuration files define pin configurations
// for different motherboards, as well as available
// features.
Expand Down
38 changes: 15 additions & 23 deletions firmware/src/Extruder/boards/ecv22/ExtruderBoard.cc
Original file line number Diff line number Diff line change
Expand Up @@ -107,13 +107,13 @@ void ExtruderBoard::reset(uint8_t resetFlags) {
TIMSK2 = 0x00; // turn off channel A PWM by default
// TIMER2 is used to PWM mosfet channel B on OC2A, and channel A on
// PC1 (using the OC2B register).
DEBUG_LED.setDirection(true);
CHANNEL_A.setValue(false);
CHANNEL_A.setDirection(true); // set channel A as output
CHANNEL_B.setValue(false);
CHANNEL_B.setDirection(true); // set channel B as output
CHANNEL_C.setValue(false);
CHANNEL_C.setDirection(true); // set channel C as output
DEBUG_LED::setDirection(true);
CHANNEL_A::setValue(false);
CHANNEL_A::setDirection(true); // set channel A as output
CHANNEL_B::setValue(false);
CHANNEL_B::setDirection(true); // set channel B as output
CHANNEL_C::setValue(false);
CHANNEL_C::setDirection(true); // set channel C as output
TCCR2A = 0b10000011;
TCCR2B = 0b00000110; // prescaler 1/256
OCR2A = 0;
Expand Down Expand Up @@ -209,14 +209,6 @@ void ExtruderBoard::setMotorSpeedRPM(uint32_t speed, bool direction) {
setExtruderMotorRPM(speed, direction);
}

micros_t ExtruderBoard::getCurrentMicros() {
micros_t micros_snapshot;
ATOMIC_BLOCK(ATOMIC_RESTORESTATE) {
micros_snapshot = micros;
}
return micros_snapshot;
}

// ms between servo updates; conservative to avoid 7805 overheating
#define SERVO_CYCLE_LENGTH 8
volatile uint8_t servo_cycle = 0;
Expand All @@ -243,10 +235,10 @@ void setChannel(ChannelChoice c, uint8_t value, bool binary) {
ATOMIC_BLOCK(ATOMIC_RESTORESTATE) {
if (binary) {
pwmAOn(false);
CHANNEL_A.setValue(value != 0);
CHANNEL_A::setValue(value != 0);
} else if (value == 0 || value == 255) {
pwmAOn(false);
CHANNEL_A.setValue(value == 255);
CHANNEL_A::setValue(value == 255);
} else {
OCR2B = value;
pwmAOn(true);
Expand All @@ -256,18 +248,18 @@ void setChannel(ChannelChoice c, uint8_t value, bool binary) {
ATOMIC_BLOCK(ATOMIC_RESTORESTATE) {
if (binary) {
pwmBOn(false);
CHANNEL_B.setValue(value != 0);
CHANNEL_B::setValue(value != 0);
} else if (value == 0 || value == 255) {
pwmBOn(false);
CHANNEL_B.setValue(value == 255);
CHANNEL_B::setValue(value == 255);
} else {
OCR2A = value;
pwmBOn(true);
}
}
} else {
// channel C -- no pwm
CHANNEL_C.setValue(value == 0?false:true);
CHANNEL_C::setValue(value == 0?false:true);
}
}

Expand All @@ -288,7 +280,7 @@ void ExtruderBoard::setValve(bool on) {
}

void ExtruderBoard::indicateError(int errorCode) {
DEBUG_LED.setValue(errorCode != 0);
DEBUG_LED::setValue(errorCode != 0);
}

void ExtruderBoard::setUsingPlatform(bool is_using) {
Expand Down Expand Up @@ -322,12 +314,12 @@ void BuildPlatformHeatingElement::setHeatingElement(uint8_t value) {

ISR(TIMER2_OVF_vect) {
if (OCR2B != 0) {
CHANNEL_A.setValue(true);
CHANNEL_A::setValue(true);
}
}

ISR(TIMER2_COMPB_vect) {
CHANNEL_A.setValue(false);
CHANNEL_A::setValue(false);
}

#ifdef DEFAULT_EXTERNAL_STEPPER
Expand Down
2 changes: 1 addition & 1 deletion firmware/src/Extruder/boards/ecv22/ExtruderBoard.hh
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public:
/// Get the number of microseconds that have passed since
/// the board was initialized. This value will wrap after
/// 2**16 microseconds; callers should compensate for this.
micros_t getCurrentMicros();
inline micros_t getCurrentMicros() { ATOMIC_BLOCK(ATOMIC_RESTORESTATE) {return micros;} }
/// Perform the timer interrupt routine.
void doInterrupt();
/// Indicate an error by manipulating the debug LED.
Expand Down
Loading