forked from luc-github/ESP3D
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.gitlab-ci.yml
66 lines (63 loc) · 2.75 KB
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
before_script:
- cd $HOME
- wget https://pypi.python.org/packages/df/c9/d9da7fafaf2a2b323d20eee050503ab08237c16b0119c7bbf1597d53f793/pyserial-2.7.tar.gz#md5=794506184df83ef2290de0d18803dd11
- tar -xvf pyserial-2.7.tar.gz
- cd pyserial-2.7
- python ./setup.py install
- wget http://downloads.arduino.cc/arduino-1.8.0-linux64.tar.xz
- tar xf ./arduino-1.8.0-linux64.tar.xz
- mv arduino-1.8.0 $HOME/arduino_ide
- cd $HOME/arduino_ide/hardware
- mkdir esp8266com
- cd esp8266com
- git clone https://github.com/esp8266/Arduino.git esp8266
- cd esp8266/tools
- python get.py
- cd ..
- touch pt.txt
- echo 'build.flash_ld=eagle.flash.4m.ld' >> pt.txt
- echo 'build.flash_freq=40' >> pt.txt
- echo 'build.flash_size=4M' >> pt.txt
- echo 'build.f_cpu=160000000L' >> pt.txt
- echo 'build.flash_mode=dio' >> pt.txt
- cat ./platform.txt >> pt.txt
- rm -fr platform.txt
- mv pt.txt platform.txt
- mv $CI_PROJECT_DIR/libraries/SdFat/SdFat $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/IniFile $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/ESPAsyncWebServer $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/ESPAsyncTCP $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/AsyncTCP $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/oled-ssd1306 $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/ESP32SSDP $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/arduinoWebSockets $HOME/arduino_ide/libraries/
- mv $CI_PROJECT_DIR/libraries/DHT_sensor_library_for_ESPx $HOME/arduino_ide/libraries/
- mkdir $HOME/arduino_ide/libraries/ESP3D
- mv $CI_PROJECT_DIR/src $HOME/arduino_ide/libraries/ESP3D
- mv $CI_PROJECT_DIR/library.properties $HOME/arduino_ide/libraries/ESP3D
- cd $HOME/arduino_ide/hardware
- mkdir esp32
- cd esp32
- git clone https://github.com/espressif/arduino-esp32.git esp32
- cd esp32
- cd tools
- python get.py
- cd ..
- touch pt.txt
- echo 'build.flash_freq=80m' >> pt.txt
- cat ./platform.txt >> pt.txt
- rm -fr platform.txt
- mv pt.txt platform.txt
job1:
script:
- cd $CI_PROJECT_DIR
- source command.sh
- export PATH="$HOME/arduino_ide:$PATH"
- arduino --get-pref
- arduino --board esp8266com:esp8266:generic --save-prefs
- sed -i "s/\/\/#define SDCARD_FEATURE /#define SDCARD_FEATURE/g" $HOME/arduino_ide/libraries/ESP3D/src/config.h
- echo "build ESP8266"
- build_sketch $CI_PROJECT_DIR/examples/basicesp3d/basicesp3d.ino
- arduino --board esp32:esp32:esp32 --save-prefs
- echo "build ESP32"
- build_sketch $CI_PROJECT_DIR/examples/basicesp3d/basicesp3d.ino