Thermocouple with MAX31855

A place for the physical connections
Gimbal
Printmaster!
Posts: 44
Joined: Tue May 28, 2013 10:25 am

Thermocouple with MAX31855

Postby Gimbal » Sat Jun 15, 2013 9:47 am

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

Gimbal
Printmaster!
Posts: 44
Joined: Tue May 28, 2013 10:25 am

Re: Thermocouple with MAX31855

Postby Gimbal » Sat Jun 15, 2013 10:12 am

So 2560 SPI are taken by LCD, 32U2 SPI are free, do not know if its usable.

Polygonhell
ULTIMATE 3D JEDDI
Posts: 2430
Joined: Mon Mar 26, 2012 1:44 pm
Location: Redmond WA

Re: Thermocouple with MAX31855

Postby Polygonhell » Sat Jun 15, 2013 11:33 am

Gimbal wrote:So 2560 SPI are taken by LCD, 32U2 SPI are free, do not know if its usable.


The SPI is actually used by the SDCard, you can share it, you just need to assign a different ~CS line.
I believe repetier already has some code In it to deal with a MAX6675, the megatronics board has one on it.

Gimbal
Printmaster!
Posts: 44
Joined: Tue May 28, 2013 10:25 am

Re: Thermocouple with MAX31855

Postby Gimbal » Sat Jun 15, 2013 1:08 pm

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
}

Gimbal
Printmaster!
Posts: 44
Joined: Tue May 28, 2013 10:25 am

Re: Thermocouple with MAX31855

Postby Gimbal » Sat Jun 15, 2013 4:33 pm

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


Return to “Nuts and Bolts”

Who is online

Users browsing this forum: No registered users and 1 guest