Version 0.78za-dc42

Fixed bug with M220 speed control (wasn't working properly after recent
merge). Added missing newline at end of output from M569.
This commit is contained in:
David Crocker 2014-12-15 18:24:33 +00:00
parent 52b78a8f8b
commit 8fed48f088
6 changed files with 26 additions and 29 deletions

View file

@ -67,16 +67,16 @@ environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPIL
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.ELF.CMD/value=arm-none-eabi-g++
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.ELF.FLAGS/delimiter=\;
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.ELF.FLAGS/operation=replace
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.ELF.FLAGS/value=-Os -Wl,--gc-sections
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.ELF.FLAGS/value=-O2 -Wl,--gc-sections
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.FLAGS/delimiter=\;
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.FLAGS/operation=replace
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.FLAGS/value=-c -g -Os -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single\=500 -Dprintf\=iprintf
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.C.FLAGS/value=-c -g -O2 -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single\=500 -Dprintf\=iprintf
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.CMD/delimiter=\;
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.CMD/operation=replace
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.CMD/value=arm-none-eabi-g++
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.FLAGS/delimiter=\;
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.FLAGS/operation=replace
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.FLAGS/value=-c -g -Os -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single\=500 -fno-rtti -fno-exceptions -Dprintf\=iprintf
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.CPP.FLAGS/value=-c -g -O2 -w -ffunction-sections -fdata-sections -nostdlib --param max-inline-insns-single\=500 -fno-rtti -fno-exceptions -Dprintf\=iprintf
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.DEFINE/delimiter=\;
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.DEFINE/operation=replace
environment/project/it.baeyens.arduino.core.toolChain.release.674980254/A.COMPILER.DEFINE/value=-DARDUINO\=

View file

@ -24,8 +24,8 @@ Licence: GPL
#define CONFIGURATION_H
#define NAME "RepRapFirmware"
#define VERSION "0.78z-dc42"
#define DATE "2014-12-03"
#define VERSION "0.78za-dc42"
#define DATE "2014-12-15"
#define AUTHORS "reprappro, dc42, zpl"
// Other firmware that we might switch to be compatible with.

View file

@ -27,7 +27,8 @@
const char GCodes::axisLetters[AXES] = {'X', 'Y', 'Z'};
const float secondsToMinutes = 1.0/60.0;
const float minutesToSeconds = 60.0;
const float secondsToMinutes = 1.0/minutesToSeconds;
GCodes::GCodes(Platform* p, Webserver* w)
{
@ -369,7 +370,7 @@ bool GCodes::LoadMoveBufferFromGCode(GCodeBuffer *gb, bool doingG92, bool applyL
if(gb->Seen(feedrateLetter))
{
moveBuffer[DRIVES] = gb->GetFValue() * distanceScale * secondsToMinutes; // G Code feedrates are in mm/minute; we need mm/sec
moveBuffer[DRIVES] = gb->GetFValue() * distanceScale * speedFactor;
}
// First do extrusion, and check, if we are extruding, that we have a tool to extrude with
@ -2777,7 +2778,7 @@ bool GCodes::HandleMcode(GCodeBuffer* gb)
case 220: // Set/report speed factor override percentage
if (gb->Seen('S'))
{
float newSpeedFactor = gb->GetFValue()/(60.0 * 100.0); // include the conversion from mm/minute to mm/second
float newSpeedFactor = (gb->GetFValue()/100.0) * secondsToMinutes; // include the conversion from mm/minute to mm/second
if (newSpeedFactor > 0)
{
speedFactorChange *= newSpeedFactor/speedFactor;
@ -2786,7 +2787,7 @@ bool GCodes::HandleMcode(GCodeBuffer* gb)
}
else
{
reply.printf("Speed factor override: %.1f%%\n", speedFactor * (60.0 * 100.0));
reply.printf("Speed factor override: %.1f%%\n", speedFactor * minutesToSeconds * 100.0);
}
break;

4
Move.h
View file

@ -448,9 +448,7 @@ inline void Move::LiveCoordinates(float m[]) const
}
// These are the actual numbers that we want to be the coordinates, so
// don't transform them.
// These are the actual numbers that we want to be the coordinates, so don't transform them.
inline void Move::SetLiveCoordinates(float coords[])
{
for(int8_t drive = 0; drive <= DRIVES; drive++)

View file

@ -762,6 +762,21 @@ void Platform::InitialiseInterrupts()
active = true; // this enables the tick interrupt, which keeps the watchdog happy
}
void Platform::SetInterrupt(float s) // Seconds
{
if (s <= 0.0)
{
//NVIC_DisableIRQ(TC3_IRQn);
Message(BOTH_ERROR_MESSAGE, "Negative interrupt!\n");
s = STANDBY_INTERRUPT_RATE;
}
uint32_t rc = (uint32_t)( (((long)(TIME_TO_REPRAP*s))*84l)/128l );
TC_SetRA(TC1, 0, rc/2); //50% high, 50% low
TC_SetRC(TC1, 0, rc);
TC_Start(TC1, 0);
NVIC_EnableIRQ(TC3_IRQn);
}
//void Platform::DisableInterrupts()
//{
// NVIC_DisableIRQ(TC3_IRQn);
@ -1199,23 +1214,6 @@ float Platform::GetFanRPM()
: 0.0; // else assume fan is off or tacho not connected
}
// Interrupts
void Platform::SetInterrupt(float s) // Seconds
{
if (s <= 0.0)
{
//NVIC_DisableIRQ(TC3_IRQn);
Message(BOTH_ERROR_MESSAGE, "Negative interrupt!\n");
s = STANDBY_INTERRUPT_RATE;
}
uint32_t rc = (uint32_t)( (((long)(TIME_TO_REPRAP*s))*84l)/128l );
TC_SetRA(TC1, 0, rc/2); //50% high, 50% low
TC_SetRC(TC1, 0, rc);
TC_Start(TC1, 0);
NVIC_EnableIRQ(TC3_IRQn);
}
//-----------------------------------------------------------------------------------------------------
FileStore* Platform::GetFileStore(const char* directory, const char* fileName, bool write)

Binary file not shown.