Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/makerbot/G3Firmware
Browse files Browse the repository at this point in the history
  • Loading branch information
aleonard committed Aug 24, 2012
2 parents 2bf291f + 65df127 commit e8d15d1
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 6 deletions.
4 changes: 2 additions & 2 deletions dist/load-firmware-ECv3.6.bat
Expand Up @@ -8,8 +8,8 @@ set /p port= < serialPort

set firmware=ECv3.6\EC-ecv34-v3.1_328.hex
set programmer=stk500v1
set baud=19200
set part=m168
set baud=57600
set part=atmega328p


echo Attempting to connect to port %port%
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion firmware/src/Motherboard/boards/mb24/Configuration.hh
Expand Up @@ -26,7 +26,7 @@
/// possible time between steps; in practical terms, your time between steps should
/// be at least eight times this large. Reducing the interval can cause resource
/// starvation; leave this at 64uS or greater unless you know what you're doing.
#define INTERVAL_IN_MICROSECONDS 128
#define INTERVAL_IN_MICROSECONDS 64

// --- Secure Digital Card configuration ---
// NOTE: If SD support is enabled, it is implicitly assumed that the
Expand Down
14 changes: 12 additions & 2 deletions firmware/src/Motherboard/boards/mb24/Motherboard.cc
Expand Up @@ -133,7 +133,8 @@ void Motherboard::reset() {
DEBUG_PIN.setDirection(true);

// Check if the interface board is attached
hasInterfaceBoard = interface::isConnected();
//hasInterfaceBoard = interface::isConnected();
hasInterfaceBoard = true;

if (hasInterfaceBoard) {
// Make sure our interface board is initialized
Expand Down Expand Up @@ -165,6 +166,7 @@ micros_t Motherboard::getCurrentMicros() {

/// Run the motherboard interrupt
void Motherboard::doInterrupt() {

if (hasInterfaceBoard) {
interfaceBoard.doInterrupt();
}
Expand All @@ -183,10 +185,16 @@ void Motherboard::runMotherboardSlice() {
}
}


/// Timer one comparator match interrupt
ISR(TIMER1_COMPA_vect) {
#ifdef OVERRIDE_DEBUG_LED
DEBUG_PIN.setValue(true);
#endif
Motherboard::getBoard().doInterrupt();
#ifdef OVERRIDE_DEBUG_LED
DEBUG_PIN.setValue(false);
#endif

}

/// Number of times to blink the debug LED on each cycle
Expand Down Expand Up @@ -231,6 +239,7 @@ int blinked_so_far = 0;

/// Timer 2 overflow interrupt
ISR(TIMER2_OVF_vect) {
#ifdef OVERRIDE_DEBUG_LED
if (blink_ovfs_remaining > 0) {
blink_ovfs_remaining--;
} else {
Expand All @@ -255,4 +264,5 @@ ISR(TIMER2_OVF_vect) {
DEBUG_PIN.setValue(true);
}
}
#endif OVERRIDE_DEBUG_LED
}
8 changes: 7 additions & 1 deletion firmware/src/SConscript.motherboard
Expand Up @@ -42,7 +42,8 @@ platform = ARGUMENTS.get('platform','mb24')
# fived only applicable for rrmbv12
fived = ARGUMENTS.get('fived','false')
f_cpu='16000000L'

# Profiling flag
profiling = ARGUMENTS.get('profiling','0')

def parse_version(v):
if not v:
Expand Down Expand Up @@ -113,6 +114,11 @@ flags=[
if (os.environ.has_key('BUILD_NAME')):
flags.append('-DBUILD_NAME=' + os.environ['BUILD_NAME'])

if (profiling == '1'):
flags.append('-DOVERRIDE_DEBUG_LED=1')

profiling = ARGUMENTS.get('profiling','0')

if (os.environ.has_key('AVR_TOOLS_PATH')):
avr_tools_path = os.environ['AVR_TOOLS_PATH']
elif (os.environ.has_key('AVR32_HOME')):
Expand Down

0 comments on commit e8d15d1

Please sign in to comment.