marlin2_i2/.travis.yml

220 lines
12 KiB
YAML
Raw Normal View History

---
language: c
before_install:
# Travis runs a detached head. We need to find the current branch
- git checkout `git branch --contains HEAD | grep -v '*'`
# Also tags for the root(s) of the minor version(s)
- git fetch origin --tags
2015-06-02 15:01:40 +02:00
- mkdir ~/bin
install:
2015-06-14 03:16:19 +02:00
# Install arduino 1.6.4
- wget http://downloads-02.arduino.cc/arduino-1.6.4-linux64.tar.xz
- tar Jxf arduino-1.6.4-linux64.tar.xz
- sudo mv arduino-1.6.4 /usr/local/share/arduino
- ln -s /usr/local/share/arduino/arduino ~/bin/arduino
# Our custom build commands
2015-06-02 15:01:40 +02:00
- mv LinuxAddons/bin/* ~/bin/
2015-06-14 03:16:19 +02:00
- ls -la ~/bin
# install our platform
- cp -r ArduinoAddons/Arduino_1.6.x/hardware/* /usr/local/share/arduino/hardware
# copy libraries to arduino dir, as conditional includes do not work in .ino files
- cp -r /usr/local/share/arduino/hardware/marlin/avr/libraries/* /usr/local/share/arduino/libraries/
- cp -r ArduinoAddons/Arduino_1.6.x/libraries/* /usr/local/share/arduino/libraries/
# add LiquidCrystal_I2C & LiquidTWI2 libraries
- git clone https://github.com/kiyoshigawa/LiquidCrystal_I2C.git
- mv LiquidCrystal_I2C/LiquidCrystal_I2C /usr/local/share/arduino/libraries/LiquidCrystal_I2C
- git clone https://github.com/lincomatic/LiquidTWI2.git
- mv LiquidTWI2 /usr/local/share/arduino/libraries/LiquidTWI2
2015-09-18 16:02:59 +02:00
# Install astyle
- wget https://github.com/timonwong/astyle-mirror/archive/master.zip
- unzip master.zip
- cd astyle-mirror-master/build/gcc/
- make prefix=$HOME astyle install
before_script:
2015-06-14 03:16:19 +02:00
# arduino requires an X server even with command line
# https://github.com/arduino/Arduino/issues/1981
- Xvfb :1 -screen 0 1024x768x16 &> xvfb.log &
# change back to home directory for compiling
- cd $TRAVIS_BUILD_DIR
2015-09-18 16:02:59 +02:00
# Check style
# ~/bin/astyle --recursive --options=.astylerc "Marlin/*.h" "Marlin/*.cpp"
script:
2015-09-18 16:02:59 +02:00
# Abort on style errors
# if [ "0" != `find . -name "*.orig" | wc -l` ] ; then echo "Improperly styled source -- run astyle" ; exit -999; fi
# Relaxed Travis check
# if [ "0" != `find . -name "*.orig" | wc -l` ] ; then echo "Improperly styled source -- run astyle" ; fi
# build default config
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# backup configuration.h
- cp Marlin/Configuration.h Marlin/Configuration.h.backup
- cp Marlin/Configuration_adv.h Marlin/Configuration_adv.h.backup
2016-02-29 08:23:17 +01:00
- cp Marlin/pins_RAMPS_14.h Marlin/pins_RAMPS_14.h.backup
# add sensor for bed
- sed -i 's/#define TEMP_SENSOR_BED 0/#define TEMP_SENSOR_BED 1/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# change extruder numbers from 1 to 2
2016-02-29 08:23:17 +01:00
- sed -i 's/#define MOTHERBOARD BOARD_RAMPS_14_EFB/#define MOTHERBOARD BOARD_RAMPS_14_EEB/g' Marlin/Configuration.h
- sed -i 's/#define EXTRUDERS 1/#define EXTRUDERS 2/g' Marlin/Configuration.h
- sed -i 's/#define TEMP_SENSOR_1 0/#define TEMP_SENSOR_1 1/g' Marlin/Configuration.h
#- cat Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# change extruder numbers from 2 to 3, needs to be a board with 3 extruders defined in pins.h
2016-02-29 08:23:17 +01:00
- sed -i 's/#define MOTHERBOARD BOARD_RAMPS_14_EEB/#define MOTHERBOARD BOARD_RUMBA/g' Marlin/Configuration.h
- sed -i 's/#define EXTRUDERS 2/#define EXTRUDERS 3/g' Marlin/Configuration.h
- sed -i 's/#define TEMP_SENSOR_2 0/#define TEMP_SENSOR_2 1/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# enable PIDTEMPBED
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define PIDTEMPBED/#define PIDTEMPBED/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# enable AUTO_BED_LEVELING
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define ENABLE_AUTO_BED_LEVELING/#define ENABLE_AUTO_BED_LEVELING/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# enable AUTO_BED_LEVELING with servos
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define ENABLE_AUTO_BED_LEVELING/#define ENABLE_AUTO_BED_LEVELING/g' Marlin/Configuration.h
- sed -i 's/\/\/#define NUM_SERVOS/#define NUM_SERVOS/g' Marlin/Configuration.h
- sed -i 's/\/\/#define Z_ENDSTOP_SERVO_NR/#define Z_ENDSTOP_SERVO_NR/g' Marlin/Configuration.h
- sed -i 's/\/\/#define SERVO_ENDSTOP_ANGLES/#define SERVO_ENDSTOP_ANGLES/g' Marlin/Configuration.h
- sed -i 's/\/\/#define DEACTIVATE_SERVOS_AFTER_MOVE/#define DEACTIVATE_SERVOS_AFTER_MOVE/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# enable EEPROM_SETTINGS & EEPROM_CHITCHAT
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define EEPROM_SETTINGS/#define EEPROM_SETTINGS/g' Marlin/Configuration.h
- sed -i 's/\/\/#define EEPROM_CHITCHAT/#define EEPROM_CHITCHAT/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
### LCDS ###
# ULTIMAKERCONTROLLER
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define ULTIMAKERCONTROLLER/#define ULTIMAKERCONTROLLER/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# MAKRPANEL
# Needs to use melzi and sanguino hardware
#- cp Marlin/Configuration.h.backup Marlin/Configuration.h
#- sed -i 's/\/\/#define MAKRPANEL/#define MAKRPANEL/g' Marlin/Configuration.h
#- rm -rf .build/
2015-06-14 03:16:19 +02:00
#- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# REPRAP_DISCOUNT_SMART_CONTROLLER
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
2016-03-10 03:06:00 +01:00
- sed -i 's/\/\/#define SDSUPPORT/#define SDSUPPORT/g' Marlin/Configuration.h
- sed -i 's/\/\/#define REPRAP_DISCOUNT_SMART_CONTROLLER/#define REPRAP_DISCOUNT_SMART_CONTROLLER/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# G3D_PANE
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define G3D_PANEL/#define G3D_PANEL/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER/#define REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# REPRAPWORLD_KEYPAD
# Cant find configuration details to get it to compile
#- cp Marlin/Configuration.h.backup Marlin/Configuration.h
#- sed -i 's/\/\/#define ULTRA_LCD/#define ULTRA_LCD/g' Marlin/Configuration.h
#- sed -i 's/\/\/#define REPRAPWORLD_KEYPAD/#define REPRAPWORLD_KEYPAD/g' Marlin/Configuration.h
#- sed -i 's/\/\/#define REPRAPWORLD_KEYPAD_MOVE_STEP 10.0/#define REPRAPWORLD_KEYPAD_MOVE_STEP 10.0/g' Marlin/Configuration.h
#- rm -rf .build/
2015-06-14 03:16:19 +02:00
#- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# RA_CONTROL_PANEL
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define RA_CONTROL_PANEL/#define RA_CONTROL_PANEL/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
### I2C PANELS ###
# LCD_I2C_SAINSMART_YWROBOT
# Failing at the moment needs different library
#- cp Marlin/Configuration.h.backup Marlin/Configuration.h
#- sed -i 's/\/\/#define LCD_I2C_SAINSMART_YWROBOT/#define LCD_I2C_SAINSMART_YWROBOT/g' Marlin/Configuration.h
#- rm -rf .build/
2015-06-14 03:16:19 +02:00
#- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# LCD_I2C_PANELOLU2
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define LCD_I2C_PANELOLU2/#define LCD_I2C_PANELOLU2/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# LCD_I2C_VIKI
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define LCD_I2C_VIKI/#define LCD_I2C_VIKI/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# LCM1602
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define LCM1602/#define LCM1602/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Enable filament sensor
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define FILAMENT_SENSOR/#define FILAMENT_SENSOR/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Enable filament sensor with LCD display
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define ULTIMAKERCONTROLLER/#define ULTIMAKERCONTROLLER/g' Marlin/Configuration.h
- sed -i 's/\/\/#define FILAMENT_SENSOR/#define FILAMENT_SENSOR/g' Marlin/Configuration.h
- sed -i 's/\/\/#define FILAMENT_LCD_DISPLAY/#define FILAMENT_LCD_DISPLAY/g' Marlin/Configuration.h
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
2015-07-23 17:59:09 +02:00
# Enable COREXY
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define COREXY/#define COREXY/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Enable COREXZ
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define COREXZ/#define COREXZ/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Enable Z_DUAL_STEPPER_DRIVERS, Z_DUAL_ENDSTOPS
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- sed -i 's/\/\/#define Z_DUAL_STEPPER_DRIVERS/#define Z_DUAL_STEPPER_DRIVERS/g' Marlin/Configuration_adv.h
- sed -i 's/\ \ \/\/\ \#define Z_DUAL_ENDSTOPS/#define Z_DUAL_ENDSTOPS/g' Marlin/Configuration_adv.h
2016-02-29 08:23:17 +01:00
- sed -i 's/#define X_MAX_PIN 2/#define X_MAX_PIN -1/g' Marlin/pins_RAMPS_14.h
- sed -i 's/\ \ \ \ \#define Z2_MAX_PIN 36/#define Z2_MAX_PIN 2/g' Marlin/Configuration_adv.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
- cp Marlin/Configuration.h.backup Marlin/Configuration.h
- cp Marlin/Configuration_adv.h.backup Marlin/Configuration_adv.h
2016-02-29 08:23:17 +01:00
- cp Marlin/pins_RAMPS_14.h.backup Marlin/pins_RAMPS_14.h
######## Example Configurations ##############
# Delta Config (generic)
- cp Marlin/example_configurations/delta/generic/Configuration* Marlin/
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Delta Config (generic) + ABL + ALLEN_KEY
- cp Marlin/example_configurations/delta/generic/Configuration* Marlin/
- sed -i 's/#define DISABLE_MIN_ENDSTOPS/\/\/#define DISABLE_MIN_ENDSTOPS/g' Marlin/Configuration.h
- sed -i 's/\/\/#define AUTO_BED_LEVELING_FEATURE/#define AUTO_BED_LEVELING_FEATURE/g' Marlin/Configuration.h
- sed -i 's/\/\/#define Z_PROBE_ALLEN_KEY/#define Z_PROBE_ALLEN_KEY/g' Marlin/Configuration.h
- rm -rf .build/
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Delta Config (Mini Kossel)
- cp Marlin/example_configurations/delta/kossel_mini/Configuration* Marlin/
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# Makibox Config need to check board type for Teensy++ 2.0
#- cp Marlin/example_configurations/makibox/Configuration* Marlin/
#- rm -rf .build/
2015-06-14 03:16:19 +02:00
#- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# SCARA Config
- cp Marlin/example_configurations/SCARA/Configuration* Marlin/
- rm -rf .build/
2015-06-14 03:16:19 +02:00
- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
# tvrrug Config need to check board type for sanguino atmega644p
#- cp Marlin/example_configurations/tvrrug/Round2/Configuration* Marlin/
#- rm -rf .build/
2015-06-14 03:16:19 +02:00
#- DISPLAY=:1.0 ~/bin/arduino --verify --board marlin:avr:mega Marlin/Marlin.ino
######## Board Types #############