WordPress database error: [Disk got full writing 'information_schema.(temporary)' (Errcode: 28 "No space left on device")]
SHOW FULL COLUMNS FROM `mb_options`


Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896

Warning: Cannot modify header information - headers already sent by (output started at /var/www/wordpress.matbra.com/wp-includes/class-wpdb.php:1851) in /var/www/wordpress.matbra.com/wp-includes/rest-api/class-wp-rest-server.php on line 1896
{"id":1489,"date":"2013-01-09T19:57:15","date_gmt":"2013-01-09T22:57:15","guid":{"rendered":"http:\/\/wordpress.matbra.com\/?p=1489"},"modified":"2013-01-09T19:57:15","modified_gmt":"2013-01-09T22:57:15","slug":"compilando-para-teensy-3-0-no-windows-utilizando-makefile","status":"publish","type":"post","link":"https:\/\/wordpress.matbra.com\/en\/2013\/01\/09\/compilando-para-teensy-3-0-no-windows-utilizando-makefile\/","title":{"rendered":"Compile to Teensy 3.0 on Windows using Makefile"},"content":{"rendered":"

Good Night,<\/p>\n

If you don’t want to use Arduino IDE (Or Teensy IDE? \ud83d\ude09 to programming and uploading your code to Teensy 3.0 you can use Makefiles.<\/p>\n

The last IDE version can be found on PJRC Forum <\/a>. As he said in the Beta 10 version, there is an Makefile example on “arduino-1.0.3\\hardware\/teensy\/cores\/teensy3” but to use it you need to add the arm binaries to your system path. To do this, open your command prompt. Start – execute – cmd.<\/p>\n

And then type:<\/p>\n

PATH = %PATH%;C:\\CAMINHO_PARA_O_ARDUINO\\arduino-1.0.3\\hardware\\tools\\arm-none-eabi\\bin<\/p><\/blockquote>\n

[If you don’t want to know the modifications that I did, just jump to the end where you can find a resume]<\/strong><\/p>\n

To guarantee that I will not screw everything, I did a copy of “arduino-1.0.3\\hardware\/teensy\/cores\/teensy3” and did my modifications on it. I executed:<\/p>\n

cs-make.exe<\/p><\/blockquote>\n

Receveid this error message:<\/p>\n

C:\\CAMINHO_PARA_O_ARDUINO\\arduino-1.0.3\\Projects\\Example_not_working>cs-make.exe
\nC:\/Users\/X-warrior\/Desktop\/tools\/arm-none-eabi\/bin\/arm-none-eabi-gcc -Wall -g -Os -mcpu=cortex-m4 -mthumb -nostdlib -MMD -DF_CPU=48000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I. -c -o analog.o analog.c
\nprocess_begin: CreateProcess(NULL, C:\/Users\/X-warrior\/Desktop\/tools\/arm-none-eabi\/bin\/arm-none-eabi-gcc -Wall -g -Os -mcpu=cortex-m4 -mthumb -nostdlib -MMD -DF_CPU=48000000 -DUSB_SERIAL -DLAYOUT_US_ENGLISH -I. -c -o analog.o analog.c, …) failed.
\nmake (e=2): The system cannot find the file specified.
\ncs-make.exe: *** [analog.o] Error 2<\/p><\/blockquote>\n

Checking the Makefile I decided to change some configs and used FULL PATH for it.
\nTOOLSPATH = C:\\CAMINHO_PARA_O_ARDUINO\\arduino-1.0.3\\hardware\\tools
\nCOMPILERPATH = C:\\CAMINHO_PARA_O_ARDUINO\\arduino-1.0.3\\hardware\\tools\\arm-none-eabi\\bin<\/p>\n

The error received was the same, so checking the code again I saw the “abspath” and thought that maybe the problem was this, since I changed my folder location. So I removed all “$(abspath” remember that it has a parenthesis that closes the command. So for example:<\/p>\n

$(abspath $(COMPILERPATH)) will be<\/strong> $(COMPILERPATH)<\/p><\/blockquote>\n

Trying to get it working again with cs-make, it started compiling it, but on the end I received this error:<\/p>\n

\nC:\\Users\\X-warrior\\Desktop\\arduino-1.0.3\\hardware\\tools\\arm-none-eabi\\bin\/arm-none-eabi-objcopy -O ihex -R .eeprom main.elf main.hex
\nC:\\Users\\X-warrior\\Desktop\\arduino-1.0.3\\hardware\\tools\/teensy_post_compile -file=main -path= -tools=C:\\Users\\X-warrior\\Desktop\\arduino-1.0.3\\hardware\\tools
\nOpening Teensy Loader…
\nTeensy Loader could not find the file main
\ncs-make.exe: *** [main.hex] Error 1<\/p><\/blockquote>\n

Triple checking the Makefile I found “path=$(shell pwd)” and I didn’t remember this pwm command on windows so I tried to execute it and it didn’t work. So I changed it to “path=$(shell echo %cd%)”. Before I start compiling again I decide to clean directory using cs-make clean<\/p>\n

I received the following errors:<\/p>\n

C:\\Users\\X-warrior\\Desktop\\arduino-1.0.3\\Projects\\Example_not_working>cs-make.exe clean
\nrm -f *.o *.d main.elf main.hex
\nprocess_begin: CreateProcess(NULL, rm -f *.o *.d main.elf main.hex, …) failed.
\nmake (e=2): The system cannot find the file specified.
\ncs-make.exe: *** [clean] Error 2<\/p><\/blockquote>\n

And then I noticed that it was calling rm -f which isn’t a windows command too. I changed the rm command to:<\/p>\n

\tdel *.o
\n\tdel *.d
\n\tdel $(TARGET).elf
\n\tdel $(TARGET).hex<\/p><\/blockquote>\n

With this I managed to clean the files and tried to compile again, and… IT WORKS! I did a few tests using main.cpp that was being compiled and uploaded to my Teensy 3. Anyways to work with all that files wasn’t attractive so I decided to go a little further and do some cleaning. So inside my “Project” folder I copied all files excluding Makefile and main.cpp to my new folder inside my project “teensy\/”. This way I can compile it without all that files on my working folder. I needed to do a few more changes on Makefile as follow:<\/p>\n

C_FILES := $(wildcard *.c) \\
\n\t $(wildcard $(addprefix teensy\/, *.c)) \\
\n\t\t $(wildcard $(addprefix teensy\/util, *.c)) \\
\n\t\t $(wildcard $(addprefix teensy\/avr, *.c))
\nCPP_FILES := $(wildcard *.cpp) \\
\n\t\t $(wildcard $(addprefix teensy\/, *.cpp)) \\
\n\t\t $(wildcard $(addprefix teensy\/util, *.cpp)) \\
\n\t\t $(wildcard $(addprefix teensy\/avr, *.cpp))
\nOBJS := $(C_FILES:.c=.o) $(CPP_FILES:.cpp=.o)<\/p><\/blockquote>\n

Linker configuration to:<\/p>\n

LDFLAGS = -Os -Wl,–gc-sections -mcpu=cortex-m4 -mthumb -Tteensy\/mk20dx128.ld<\/p><\/blockquote>\n

And to keep it consistent:<\/p>\n

$(TARGET).elf: $(OBJS) teensy\/mk20dx128.ld
\n\t$(CC) $(LDFLAGS) -o $@ $(OBJS)<\/p><\/blockquote>\n

And then I found this error:<\/p>\n

\nteensy\/keylayouts.c:1: fatal error: avr\/pgmspace.h: No such file or directory
\ncompilation terminated.
\ncs-make: *** [teensy\/keylayouts.o] Error 1\n<\/p><\/blockquote>\n

So I updated the CPPFLAGS to:<\/p>\n

CPPFLAGS = -Wall -g -Os -mcpu=cortex-m4 -mthumb -nostdlib -MMD $(OPTIONS) -I. -Iteensy\/<\/p><\/blockquote>\n

And also remembered that the clean should be updated too.<\/p>\n

clean:
\n\tdel *.o
\n\tdel *.d
\n\tdel $(TARGET).elf
\n\tdel $(TARGET).hex
\n\tdel $(CURRENT_PATH)\\teensy\\*.o
\n\tdel $(CURRENT_PATH)\\teensy\\*.d<\/p><\/blockquote>\n

And add this on the begin of “Configurations that shouldn’t be updated”<\/p>\n

CURRENT_PATH=$(shell echo %cd%)<\/p><\/blockquote>\n

With all this I managed to get the Makefile working on Windows compiling and uploading for Teensy 3.0<\/p>\n

Summary:<\/strong>
\nYou must update TOOLSPATH , COMPILERPATH and use your FULL PATH
\nThen create a folder “My_Project”
\nCreate another folder inside your project called “teensy” (My_Project\/teensy\/)
\nCopy “arduino-1.0.3\\hardware\/teensy\/cores\/teensy3\/” to “My_Project\/teensy\/” (subdir too, but not the Makefile)
\nAdd the Makefile that you can download on the end of this post inside “My_Project”
\nCopy “Meu_Projeto\/teensy\/main.cpp” too “Meu_Projeto\/main.cpp”
\nProgramm inside main.cpp
\nCompile and upload with cs-make.exe<\/p>\n

Makefile to Teensy on Windows<\/a><\/p>\n

Matheus<\/p>\n

<\/p>","protected":false},"excerpt":{"rendered":"

Good Night, If you don’t want to use Arduino IDE (Or Teensy IDE? \ud83d\ude09 to programming and uploading your code to Teensy 3.0 you can…<\/p>\n