Moving the Troodon V2 Printer from board.txt defined pins to firmware defined pins


The Troodon V2 Printer is supplied with a firmware and firmware files that, rather than having the supplied mainboard natively configured, use a different firmware profile and override the pins configured using board.txt. There is nothing wrong with the approach Formbot have taken and the firmware can be updated without issue. However, in the future, changes may be made to the firmware profile its using that may cause issues. TeamGloomy therefore recommend making some changes to your board.txt to prevent any issues going forwards.

Default board.txt file

The default board.txt file can be found here in case you need to go back to it.

Modified board.txt file

Below is the modified board.txt file which uses native firmware pin assignments

// This board.txt file has come from the teamgloomy wiki
// version: 1.1
board = troodon_v2

//LED blinks to indicate Platform is spinning or other diagnostic 
leds.diagnostic = LED

heat.tempSensePins = {PA_0, PF_3}

//ESP Settings
8266wifi.espDataReadyPin = PD_0
8266wifi.TfrReadyPin = PD_3
8266wifi.espResetPin = PG_14
8266wifi.csPin = PA_15
//ESP RX/TX Settings
8266wifi.serialRxTxPins = { PD_6, PD_5 }
8266wifi.spiChannel = 2

// External Display settings
serial.aux.rxTxPins = {NoPin, NoPin};

//MINI 12864
lcd.encoderPinA = BTNEN1
lcd.encoderPinB = BTNEN2
lcd.encoderPinSw = BTNENC
lcd.lcdCSPin = LCDEN
lcd.lcdDCPin = LCDRS
lcd.spiChannel = 1
lcd.lcdBeepPin = BEEP
sdCard.external.spiChannel = 1
sdCard.external.csPin = LCDSS
sdCard.external.cardDetectPin = LCDCD
led.neopixelPin = LCDD5

Config.g Changes

Switching to native firmware support also allows you adjust the pin assignments used in config.g from using a pin number to using an alias. For example

M574 X1 S1 P"PF_2"   

would become

M574 X1 S1 P"xstop"   

This is not a critical change, it just makes config.g easier to read.
To find the alias names for each pin, look here