Cant compile teensy 3.2 on Win7 machine

Status
Not open for further replies.

KrisKasprzak

Well-known member
I usually can get teensy to compile and upload. But not today.

Win7 machine
Teensy 1.41
program is new file with no new lines.
tried rebooting
tried plugging in again, and pressing button (I get a beep by Win when I press button)
Device manager can see Teensy until I press button then it's removed from the ports section

I get this error.


c:\program files (x86)\arduino\hardware\tools\arm\bin\../lib/gcc/arm-none-eabi/5.4.1/../../../../arm-none-eabi/bin/ar.exe: unable to rename 'C:\Users\ADMINI~1\AppData\Local\Temp\arduino_build_859608\core\core.a'; reason: File exists

Error compiling for board Teensy 3.2 / 3.1.



H E L P
 
Save the sketch to another folder location perhaps? Compile from there. I don't see a details that tells me the source of the problem - seems I've seen that but too long and that doesn't trigger the memory.

Close the IDE to dump the temp files.

Is this a full Arduino Build and upload through TeensyLoader? Probably not relevant - but there is a 1.42 version of Teensy - so if you get to reinstall - use that perhaps.

TeensyLoader has Verbose under Help that will provide more log info on what it is seeing?
 
still cant compile OR upload.


tried all that, upgraded to 1.42

verbose stuff
09:23:47.560 (ports 1): Begin, version=1.42, 1ms res time
09:23:47.560 (ports 1): LoadLibrary cfgmgr32 ok
09:23:47.560 (ports 1): LoadLibrary ntdll ok
09:23:47.560 (ports 1): callback 0024
09:23:47.560 (ports 1): callback 0081
09:23:47.560 (ports 1): callback 0083
09:23:47.560 (ports 1): hWnd = 393488
09:23:47.560 (ports 1): callback 000D
09:23:47.560 (ports 1): not already running
09:23:47.560 (ports 1): socket created
09:23:47.560 (ports 1): bound to port 28542
09:23:47.560 (ports 1): found_usb_device, id=\\?\usb#vid_16c0&pid_0483#3959870#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:23:47.560 (ports 1): found_usb_device, loc=usb:0/140000/0/E Port_#0014.Hub_#0001
09:23:47.560 (ports 1): found_usb_device, hwid=USB\VID_16C0&PID_0483&REV_0275
09:23:47.560 (ports 1): found_usb_device, devinst=000008a0
09:23:47.560 (ports 1): add: loc=usb:0/140000/0/E, class=Ports, vid=16C0, pid=0483, ver=0275, serial=395, dev=\\?\usb#vid_16c0&pid_0483#3959870#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:23:47.560 (ports 1): comport_from_devinst_list attempt
09:23:47.560 (ports 1): found Ports in classguid_list at index=0
09:23:47.560 (ports 1): port COM36 found from devnode
09:23:47.560 (ports 1): found_usb_device complete
09:23:47.560 (ports 1): usb_add: usb:0/140000/0/E COM36 (Teensy 3.2) Serial
09:23:47.600 (ports 1): incoming connection, port 49198
09:23:57.954 (ports 1): got command: "list"
09:23:57.957 (ports 1): nothing new, skipping HID & Ports enum
09:24:58.787 (loader): Teensy Loader 1.42, begin program
09:24:58.830 (loader): Listening for remote control on port 3149
09:24:58.831 (loader): initialized, showing main window
09:24:59.085 (loader): HID/win32: vid:413C pid:2113 ver:0108
09:24:59.085 (loader): HID/win32: vid:413C pid:2113 ver:0108
09:25:03.602 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:03.632 (loader): remote connection 808 opened
09:25:03.634 (ports 1): remove: loc=usb:0/140000/0/E
09:25:03.634 (ports 1): usb_remove: usb:0/140000/0/E
09:25:03.634 (ports 1): nothing new, skipping HID & Ports enum
09:25:03.634 (ports 1): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
09:25:03.635 (ports 1): nothing new, skipping HID & Ports enum
09:25:07.602 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:07.605 (ports 1): nothing new, skipping HID & Ports enum
09:25:07.656 (ports 1): WM_DEVICECHANGE DBT_DEVICEARRIVAL
09:25:07.658 (ports 1): found_usb_device, id=\\?\usb#vid_16c0&pid_0483#3959870#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:25:07.658 (ports 1): found_usb_device, loc=usb:0/140000/0/E Port_#0014.Hub_#0001
09:25:07.658 (ports 1): found_usb_device, hwid=USB\VID_16C0&PID_0483&REV_0275
09:25:07.658 (ports 1): found_usb_device, devinst=000008a0
09:25:07.658 (ports 1): add: loc=usb:0/140000/0/E, class=Ports, vid=16C0, pid=0483, ver=0275, serial=395, dev=\\?\usb#vid_16c0&pid_0483#3959870#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:25:07.659 (ports 1): comport_from_devinst_list attempt
09:25:07.659 (ports 1): found Ports in classguid_list at index=0
09:25:07.659 (ports 1): port COM36 found from devnode
09:25:07.659 (ports 1): found_usb_device complete
09:25:07.660 (ports 1): usb_add: usb:0/140000/0/E COM36 (Teensy 3.2) Serial
09:25:07.660 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:07.662 (ports 1): nothing new, skipping HID & Ports enum
09:25:09.670 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:09.672 (ports 1): remove: loc=usb:0/140000/0/E
09:25:09.672 (ports 1): usb_remove: usb:0/140000/0/E
09:25:09.672 (ports 1): nothing new, skipping HID & Ports enum
09:25:09.691 (ports 1): WM_DEVICECHANGE DBT_DEVICEREMOVECOMPLETE
09:25:09.692 (ports 1): nothing new, skipping HID & Ports enum
09:25:10.148 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:10.149 (ports 1): nothing new, skipping HID & Ports enum
09:25:10.205 (ports 1): WM_DEVICECHANGE DBT_DEVICEARRIVAL
09:25:10.208 (ports 1): found_usb_device, id=\\?\usb#vid_16c0&pid_0478#00060ad3#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:25:10.208 (ports 1): found_usb_device, loc=usb:0/140000/0/E Port_#0014.Hub_#0001
09:25:10.208 (ports 1): found_usb_device, hwid=USB\VID_16C0&PID_0478&REV_0103
09:25:10.208 (ports 1): found_usb_device, devinst=00000c24
09:25:10.208 (ports 1): add: loc=usb:0/140000/0/E, class=HID, vid=16C0, pid=0478, ver=0103, serial=000, dev=\\?\usb#vid_16c0&pid_0478#00060ad3#{a5dcbf10-6530-11d2-901f-00c04fb951ed}
09:25:10.208 (ports 1): hiddev_from_devinst_list: iface=0
09:25:10.209 (ports 1): found_usb_device complete
09:25:10.210 (ports 1): hid, found devinst=00000C68
09:25:10.210 (ports 1): hid, path=\\?\hid#vid_16c0&pid_0478#6&1238800&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
09:25:10.210 (ports 1): hid, opened handle
09:25:10.210 (ports 1): devinst=00000C68, location=usb:0/140000/0/E
09:25:10.210 (ports 1): vid=16C0, pid=0478, ver=0103, usepage=FF9C, use=0021
09:25:10.210 (ports 1): devpath=\\?\hid#vid_16c0&pid_0478#6&1238800&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030}
09:25:10.211 (ports 1): usb_add: usb:0/140000/0/E \\?\hid#vid_16c0&pid_0478#6&1238800&0&0000#{4d1e55b2-f16f-11cf-88cb-001111000030} (Teensy 3.2) Bootloader
09:25:10.211 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:10.214 (ports 1): nothing new, skipping HID & Ports enum
09:25:10.214 (ports 1): WM_DEVICECHANGE DBT_DEVNODES_CHANGED
09:25:10.216 (ports 1): nothing new, skipping HID & Ports enum
09:25:10.255 (loader): Device came online, code_size = 262144
09:25:10.255 (loader): Board is: Teensy 3.2 (MK20DX256), version 1.03
09:25:10.255 (loader): set background IMG_ONLINE
09:25:10.517 (loader): HID/win32: HidD_GetPreparsedData ok, device still online :)
09:25:11.713 (ports 1): got command: "list"
09:25:11.715 (ports 1): nothing new, skipping HID & Ports enum
09:26:47.425 (ports 1): got command: "list"
09:27:33.089 (loader): Verbose Info event
 
Which Virus protection are you using on your machine? My guess is Symantec ...

Been there. You have a couple of options:
a) temporarily turn off real time scanning at least for the first build ...
b) I think you can maybe add some directories to the don't scan list... Been awhile, but search for virus or symantec or ??? as there have been a few threads on this.
c) Get rid of Symantec.

I ended up choosing option c)... Currently have Norton... Still not great. Others use defender...
 
No standard SATA local hard drive. Win 7 64 bit, 16 GB ram. Intel i7 CPU, HB USB scanner, parallel printer (yea old HP 5L), dual monitors, not much else connected.

Generally i can get Teensy 3.2 to compile and upload without issues 80% of the time, the remainder fails--either I have to unplug the teensy, press the program button, restart Arduino IDE, close serial monitor.

This last day, nothing works, compile fails, upload fails, and none of my tricks above work. I've even tried removing my Teensy from the PCB board.

Paul, If others run into this issue, i'm more than happy to share my desktop (using some internet sharing app) and let you poke around my system.
 
holy cow. disabled and teensy programmed.

KurtE, if I ever meet you I will happily buy you are beer for that.

I'll see if adding my folders will make the fix permanent.
 
@KurtE - Any ideas how future Teensyduino might try to detect whether McAfee real time scan is at play? I've heard people talk about insanely long compile times, like over a minute.
 
@paul - Sorry, not really sure. I finally got fed up enough with them, and went to another one, but even it (Norton) still slows things down.

Not sure if you would get anywhere with trying to contact them, on how to configure your system to minimize there overhead (hopefully automatically)
 
KurtE, that explains a lot. While McAfee is enabled my first compile is 3-4 minutes. Second is around 30 sec. Disabling McAfee, first compile is around 20 sec, second is like 5.

I see no way to add a folder to McAfee's white list so i guess i'll have to disable first.

Thanks again
 
oh yeah that was it - everything watching for ransomeware attacks and monitoring spastic disk I/O [ like compiles ] and being ready to stop nefarious file rewrite encryption … and slowing the system down in the process.

Noted this before Windows not too far back incorporated it into the system ideally in a non-obstrusive way - IIRC correctly was limited to common user file areas - but the add on guys hook into file I/O to watch/slow things down across the board and stop when they feel triggered.

If it can't be told to ignore on a folder basis it will get in the way slowing stuff down. I noted Malwarebytes can ignore locations - I moved all my temp to an SSD and had it ignore that and all sped up, but it didn't block. And Windows 10 with Defender alone seems permissive enough for normal stuff.
 
Is this PC using a SSD or normal mechanical hard drive?

If you're willing to experiment, I'm curious what sort to first & second compile speed you see if you grab the latest arduino-builder.exe. To get this, go to Arduino's download page and get the "Hourly Build". Extract the ZIP file. Inside you'll see arduino-builder.exe. Copy that to your C:\Program Files (x86)\Arduino folder, replacing the copy from 1.8.5. Or if you want to be able to go back, first rename or back up the old arduino-builder.exe.

The new arduino-builder.exe is supposed to leverage more than 1 core in your CPU, assuming you have a dual or quad core processor (as nearly all modern PCs do). Curious to hear how it affects these speeds on your PC.
 
I have a mechanical SATA HDD--it's about 3 years old or so. My CPU is 3 year old and is an Intel i7 quad core, but shows up as 8 processors in the task manager.

Here are the test results
- McAfee disabled
- 1200 lines of code

Arduino 1.8.5 with original arduino-builder.exe
Compile and upload
1st go 14.5 sec (includes time to launch teensyduino)
2nd go 6.2 sec

Arduino 1.8.5 with NEW arduino-builder.exe
Compile and upload
1st go 10.6 sec (includes time to launch teensyduino)
2nd go 5.4 sec

Better, but the holy grail was disabling the virus scanner....

PS in my desperate attempt to get something working I ran one of the exe's in the Arduino folder--don't remember which one. But upon a successful compile i now get a strange message in the status window "gettimeofday" is listed several times. Know what's up?
 
'gettimeofday' is a debug holdover in the TD 1.42 build for Win 7 builds.
Look for it to go away in 1.43 as it is already on Paul's list

<edit>doing Verify build one of the AUDIO examples would give a comparable baseline with a large code base

<edit 2> pulled nightly build and did Verify Build as below on my Win 10 i7 - building from SSD with to TEMP on same SSD with Malwarebytes active but excluding that Drive::

libraries\Audio\examples\Effects\Freeverb_Stereo\Freeverb_Stereo.ino
Sketch uses 43688 bytes (4%) of program storage space. Maximum is 1048576 bytes.
Global variables use 65736 bytes (25%) of dynamic memory, leaving 196408 bytes for local variables. Maximum is 262144 bytes.

TD 1.42 on IDE 1.85
First Verify:: 68 sec
Rebuild:: 7 sec

TD 1.42 on IDE 1.85 - with nightly arduino-builder.exe
First Verify:: 40 sec
Rebuild:: 5-7 sec
 
Last edited:
Status
Not open for further replies.
Back
Top