Hi, has anybody work with the MAX31855 SPI and Rambo, looks straight foward to configer it as MAX6675, but when i check on adafruit they have two different library for them and RepetierMax using Arduino SPI library.
Will investigate this and post back.
Anders
Thermocouple with MAX31855
Re: Thermocouple with MAX31855
So 2560 SPI are taken by LCD, 32U2 SPI are free, do not know if its usable.
-
- ULTIMATE 3D JEDI
- Posts: 2430
- Joined: Mon Mar 26, 2012 1:44 pm
- Location: Redmond WA
Re: Thermocouple with MAX31855
The SPI is actually used by the SDCard, you can share it, you just need to assign a different ~CS line.Gimbal wrote:So 2560 SPI are taken by LCD, 32U2 SPI are free, do not know if its usable.
I believe repetier already has some code In it to deal with a MAX6675, the megatronics board has one on it.
Printer blog http://3dprinterhell.blogspot.com/
Re: Thermocouple with MAX31855
Hm, think i can use sensorpin as CS:
#ifdef SUPPORT_MAX6675
if(act->sensorType==101) {
WRITE(SCK_PIN,0);
SET_OUTPUT(SCK_PIN);
WRITE(MOSI_PIN,1);
SET_OUTPUT(MOSI_PIN);
WRITE(MISO_PIN,1);
SET_INPUT(MISO_PIN);
digitalWrite(act->tempControl.sensorPin,1);
pinMode(act->tempControl.sensorPin,OUTPUT);
}
#endif
}
#ifdef SUPPORT_MAX6675
if(act->sensorType==101) {
WRITE(SCK_PIN,0);
SET_OUTPUT(SCK_PIN);
WRITE(MOSI_PIN,1);
SET_OUTPUT(MOSI_PIN);
WRITE(MISO_PIN,1);
SET_INPUT(MISO_PIN);
digitalWrite(act->tempControl.sensorPin,1);
pinMode(act->tempControl.sensorPin,OUTPUT);
}
#endif
}
Re: Thermocouple with MAX31855
So i guess i have to piggyback the SPI connector and use SP0 as CS
// 101 is MAX6675
#define EXT0_TEMPSENSOR_TYPE 101
// Analog input pin for reading temperatures or pin enabling SS for MAX6675
#define EXT0_TEMPSENSOR_PIN TEMP_0_PIN
// WHich pin enables the heater
#define EXT0_HEATER_PIN HEATER_0_PIN
#define EXT0_STEP_PIN E0_STEP_PIN
#define EXT0_DIR_PIN E0_DIR_PIN
Will give it a go
// 101 is MAX6675
#define EXT0_TEMPSENSOR_TYPE 101
// Analog input pin for reading temperatures or pin enabling SS for MAX6675
#define EXT0_TEMPSENSOR_PIN TEMP_0_PIN
// WHich pin enables the heater
#define EXT0_HEATER_PIN HEATER_0_PIN
#define EXT0_STEP_PIN E0_STEP_PIN
#define EXT0_DIR_PIN E0_DIR_PIN
Will give it a go