bxparks / AUniter

Command line tools for verifying Arduino sketches, uploading them to boards, validating AUnit unit tests, and integrating with continuous integration platforms.
MIT License
19 stars 2 forks source link

add Teensyduino into Arduino binary run by Jenkins #4

Open bxparks opened 6 years ago

bxparks commented 6 years ago

Jenkins owns its own copy of the Arduino IDE. I added ESP8266 and ESP32 to it, and documented the process. Do the same for Teensyduino.

bxparks commented 6 years ago

It looks like Teensyduino (1.42) is unable to run the --verify option (compile-only) in headless mode. For some reason, it wants to fire up the Teensy Loader, which wants to display a small window, but it can't in a headless environment.

$ DISPLAY='' auniter --boards teensy32 --verify AceButtonTest
======== Processing board=teensy32, port=
==== Processing AceButtonTest/AceButtonTest.ino
$ /home/brian/dev/arduino-1.8.5/arduino --verify  --board teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us   AceButtonTest/AceButtonTest.ino
Picked up JAVA_TOOL_OPTIONS: 
Loading configuration...
Initializing packages...
Preparing boards...
Verifying...
Archiving built core (caching) in: /tmp/arduino_cache_843051/core/core_teensy_avr_teensy31_usb_serial,speed_96,opt_o2std,keys_en-us_040d764db35341206dc0c9268568ddbb.a
Opening Teensy Loader...
Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
quitexit status 1
FAILED verify: teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us  AceButtonTest/AceButtonTest.ino
======== Summary
FAILED verify: teensy:avr:teensy31:usb=serial,speed=96,opt=o2std,keys=en-us  AceButtonTest/AceButtonTest.ino
FAILURES found
kbebs commented 5 years ago

Try running it in a virtual frame buffer with xvfb-run. I've had luck running Teensy Loader headless with xvfb.

bxparks commented 5 years ago

I haven't used xvrb in years, but that's a great idea. I'll give it a shot, thanks!