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

Made Arduino DUE port compile and work again #24809

Merged
merged 5 commits into from
Sep 29, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
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
2 changes: 1 addition & 1 deletion Marlin/src/HAL/DUE/HAL.h
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ class MarlinHAL {
static void adc_init() {}

// Called by Temperature::init for each sensor at startup
static void adc_enable(const uint8_t ch) {}
static void adc_enable(const uint8_t) {}

// Begin ADC sampling on the given channel. Called from Temperature::isr!
static void adc_start(const uint8_t ch) { adc_result = analogRead(ch); }
Expand Down
4 changes: 2 additions & 2 deletions Marlin/src/HAL/DUE/HAL_SPI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -247,12 +247,12 @@
b <<= 1; // little setup time

WRITE(SD_SCK_PIN, HIGH);
DELAY_NS(spiDelayNS);
DELAY_NS_VAR(spiDelayNS);

b |= (READ(SD_MISO_PIN) != 0);

WRITE(SD_SCK_PIN, LOW);
DELAY_NS(spiDelayNS);
DELAY_NS_VAR(spiDelayNS);
} while (--bits);
return b;
}
Expand Down
11 changes: 10 additions & 1 deletion Marlin/src/HAL/DUE/InterruptVectors.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,16 @@
practice, we need alignment to 256 bytes to make this work in all
cases */
__attribute__ ((aligned(256)))
static DeviceVectors ram_tab = { nullptr };
static DeviceVectors ram_tab = {
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,nullptr,
nullptr,nullptr,nullptr,nullptr,nullptr
};

/**
* This function checks if the exception/interrupt table is already in SRAM or not.
Expand Down