Bug 16044 - Arduino - Impossible to upload sketch
Summary: Arduino - Impossible to upload sketch
Status: RESOLVED DUPLICATE of bug 12919
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: 5
Hardware: x86_64 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Yann Cantin
QA Contact:
URL:
Whiteboard:
Keywords: NEEDINFO
Depends on:
Blocks:
 
Reported: 2015-05-27 06:45 CEST by Jan Pihlgren
Modified: 2018-04-18 12:00 CEST (History)
3 users (show)

See Also:
Source RPM: arduino-1.0.5 10.mga5
CVE:
Status comment:


Attachments

Description Jan Pihlgren 2015-05-27 06:45:52 CEST
OS: Mageia 4 x86-64

I use Arduino 1.6.4
Copilation looks like go OK.
But when I try to upload the sketch to Arduino I get the following error:
avrdude: stk500_recv(): programmer is not responding

Komplete errormessage:
Arduino:1.6.4 (Linux), Kort:"Arduino Uno"

Build options changed, rebuilding all

Sketch uses 22 406 bytes (69%) of program storage space. Maximum is 32 256 bytes.
Global variables use 1 247 bytes (60%) of dynamic memory, leaving 801 bytes for local variables. Maximum is 2 048 bytes.
/home/jan/Program1/arduino-1.6.4/hardware/tools/avr/bin/avrdude -C/home/jan/Program1/arduino-1.6.4/hardware/tools/avr/etc/avrdude.conf -v -patmega328p -carduino -P/dev/ttyACM0 -b115200 -D -Uflash:w:/tmp/build947764394737199160.tmp/HTTPServer_jan2.cpp.hex:i 

avrdude: Version 6.0.1, compiled on Apr 14 2015 at 19:04:16
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "/home/jan/Program1/arduino-1.6.4/hardware/tools/avr/etc/avrdude.conf"
         User configuration file is "/home/jan/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyACM0
         Using Programmer              : arduino
         Overriding Baud Rate          : 115200
         AVR Part                      : ATmega328P
         Chip Erase delay              : 9000 us
         PAGEL                         : PD7
         BS2                           : PC2
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : Arduino
         Description     : Arduino
         Hardware Version: 3
         Firmware Version: 4.4
         Vtarget         : 0.3 V
         Varef           : 0.3 V
         Oscillator      : 28.800 kHz
         SCK period      : 3.3 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f
avrdude: reading input file "/tmp/build947764394737199160.tmp/HTTPServer_jan2.cpp.hex"
avrdude: writing flash (22406 bytes):

Writing | avrdude: stk500_recv(): programmer is not responding
Problem at uploading. Look at http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

  This report would have more information with
  "Show verbose output during compilation"
  enabled in File > Preferences.
Rémi Verschelde 2015-05-27 08:54:52 CEST

CC: (none) => shlomif

Comment 1 Jan Pihlgren 2015-09-05 06:35:54 CEST
arduino			1.0.5 10.mga5 noarch
arduino-core 		1.0.5 10.mga5 noarch
arduino-doc 		1.0.5 10.mga5 noarch

avr-libc		1.7.1  8.mga5 noarch
avrdude			6.1    7.mga5 x86_64
cross-avr-binutils 	2.23.2 5.mga5 x86_64
cross-avr-gcc		4.8.1  5.mga5 x86_64
cross-avr-gcc-c++	4.8.1  5.mga5 x86_64

Board: Arduino Diecimila
Programmer: AVRISP mkII
 

Errormessage: Error compiling

In file included from /usr/share/arduino/hardware/arduino/cores/arduino/Platform.h:9:0,
                 from /usr/share/arduino/hardware/arduino/cores/arduino/CDC.cpp:19:
/usr/avr/include/util/delay.h: In function 'void _delay_ms(double)':
/usr/avr/include/util/delay.h:149:42: error: 'fabs' was not declared in this scope
   __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
                                          ^
/usr/avr/include/util/delay.h:149:43: error: 'ceil' was not declared in this scope
   __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
                                           ^
/usr/avr/include/util/delay.h: In function 'void _delay_us(double)':
/usr/avr/include/util/delay.h:226:42: error: 'fabs' was not declared in this scope
   __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
                                          ^
/usr/avr/include/util/delay.h:226:43: error: 'ceil' was not declared in this scope
   __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
                                           ^

==========================================
Arduino 1.6.6
------------
1.6.6 Hourly Build 2015/09/04 04:26
Board: Arduino Diecimila
Processor: ATmega168
Programmer: AVRISP mkII
Port: /dev/ttyUSB0

Result: OK!!!!

So when will the Arduino package in Mageia be updated to latest Arduino software release?
Comment 2 Marja Van Waes 2015-09-05 09:15:48 CEST
(In reply to Jan Pihlgren from comment #1)
> arduino			1.0.5 10.mga5 noarch
> arduino-core 		1.0.5 10.mga5 noarch
> arduino-doc 		1.0.5 10.mga5 noarch
> 
> avr-libc		1.7.1  8.mga5 noarch
> avrdude			6.1    7.mga5 x86_64
> cross-avr-binutils 	2.23.2 5.mga5 x86_64
> cross-avr-gcc		4.8.1  5.mga5 x86_64
> cross-avr-gcc-c++	4.8.1  5.mga5 x86_64
> 
> Board: Arduino Diecimila
> Programmer: AVRISP mkII
>  
> 
> Errormessage: Error compiling
> 
> In file included from
> /usr/share/arduino/hardware/arduino/cores/arduino/Platform.h:9:0,
>                  from
> /usr/share/arduino/hardware/arduino/cores/arduino/CDC.cpp:19:
> /usr/avr/include/util/delay.h: In function 'void _delay_ms(double)':
> /usr/avr/include/util/delay.h:149:42: error: 'fabs' was not declared in this
> scope
>    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
>                                           ^
> /usr/avr/include/util/delay.h:149:43: error: 'ceil' was not declared in this
> scope
>    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
>                                            ^
> /usr/avr/include/util/delay.h: In function 'void _delay_us(double)':
> /usr/avr/include/util/delay.h:226:42: error: 'fabs' was not declared in this
> scope
>    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
>                                           ^
> /usr/avr/include/util/delay.h:226:43: error: 'ceil' was not declared in this
> scope
>    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
>                                            ^
> 
> ==========================================
> Arduino 1.6.6
> ------------
> 1.6.6 Hourly Build 2015/09/04 04:26
> Board: Arduino Diecimila
> Processor: ATmega168
> Programmer: AVRISP mkII
> Port: /dev/ttyUSB0
> 
> Result: OK!!!!
> 
> So when will the Arduino package in Mageia be updated to latest Arduino
> software release?

Changing version to 5, because that's what you're apparently using now and Mageia 4 is nearly EOL.

In cauldron we now have arduino-1.0.6-1.mga6. Could you, by any chance, check whether 1.0.6 fixes your problem, too?

Keywords: (none) => NEEDINFO
CC: (none) => marja11, yann.cantin
Version: 4 => 5
Assignee: bugsquad => shlomif

Marja Van Waes 2015-09-05 09:17:30 CEST

Source RPM: (none) => arduino-1.0.5 10.mga5

Comment 3 Shlomi Fish 2015-09-05 09:19:51 CEST
I should note that my former apprentice (now a graduated packager) Yann Cantin wanted to look into upgrading the arduino package. It's an ongoing work due to the fact that the source package contains some proprietary software.
Comment 4 Yann Cantin 2015-09-05 10:06:05 CEST
For the error in comment 2, see bug 12919 :

Add #include <math.h> after #include <inttypes.h> in /usr/avr/include/util/delay.h
or
add #include <math.h> to the script

Concerning Arduino 1.6.x, the proprietary part is done, but it still need a lot of libs that are currently outdated in mageia's java stack.
Comment 5 Yann Cantin 2015-10-23 19:25:51 CEST
Arduino 1.6.5 ready in cauldron.

Jan, did the fix in comment 4 solve the problem ?
Comment 6 Jan Pihlgren 2015-10-24 06:20:34 CEST
(In reply to Yann Cantin from comment #5)
> Arduino 1.6.5 ready in cauldron.
> 
> Jan, did the fix in comment 4 solve the problem ?

Yes. Now it possible to compile and upload a sketch in version 1.0.5
Comment 7 Jan Pihlgren 2015-10-24 06:23:02 CEST
(In reply to Marja van Waes from comment #2)
> (In reply to Jan Pihlgren from comment #1)
> > arduino			1.0.5 10.mga5 noarch
> > arduino-core 		1.0.5 10.mga5 noarch
> > arduino-doc 		1.0.5 10.mga5 noarch
> > 
> > avr-libc		1.7.1  8.mga5 noarch
> > avrdude			6.1    7.mga5 x86_64
> > cross-avr-binutils 	2.23.2 5.mga5 x86_64
> > cross-avr-gcc		4.8.1  5.mga5 x86_64
> > cross-avr-gcc-c++	4.8.1  5.mga5 x86_64
> > 
> > Board: Arduino Diecimila
> > Programmer: AVRISP mkII
> >  
> > 
> > Errormessage: Error compiling
> > 
> > In file included from
> > /usr/share/arduino/hardware/arduino/cores/arduino/Platform.h:9:0,
> >                  from
> > /usr/share/arduino/hardware/arduino/cores/arduino/CDC.cpp:19:
> > /usr/avr/include/util/delay.h: In function 'void _delay_ms(double)':
> > /usr/avr/include/util/delay.h:149:42: error: 'fabs' was not declared in this
> > scope
> >    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
> >                                           ^
> > /usr/avr/include/util/delay.h:149:43: error: 'ceil' was not declared in this
> > scope
> >    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
> >                                            ^
> > /usr/avr/include/util/delay.h: In function 'void _delay_us(double)':
> > /usr/avr/include/util/delay.h:226:42: error: 'fabs' was not declared in this
> > scope
> >    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
> >                                           ^
> > /usr/avr/include/util/delay.h:226:43: error: 'ceil' was not declared in this
> > scope
> >    __ticks_dc = (uint32_t)(ceil(fabs(__tmp)));
> >                                            ^
> > 
> > ==========================================
> > Arduino 1.6.6
> > ------------
> > 1.6.6 Hourly Build 2015/09/04 04:26
> > Board: Arduino Diecimila
> > Processor: ATmega168
> > Programmer: AVRISP mkII
> > Port: /dev/ttyUSB0
> > 
> > Result: OK!!!!
> > 
> > So when will the Arduino package in Mageia be updated to latest Arduino
> > software release?
> 
> Changing version to 5, because that's what you're apparently using now and
> Mageia 4 is nearly EOL.
> 
> In cauldron we now have arduino-1.0.6-1.mga6. Could you, by any chance,
> check whether 1.0.6 fixes your problem, too?

I don't know howto access caulderon. I can't find it when using MCC.
Comment 8 Shlomi Fish 2015-12-05 09:38:08 CET
Assigning to Yann Cantin.

Assignee: shlomif => yann.cantin

Comment 9 Yann Cantin 2015-12-21 13:17:04 CET
Jan : Cauldron is the generic name of the development version of the distribution (mga6). It's not just a additional repo, you have to fully upgrade your distro.
Not meant to be used on production.

Anyway : fixed in bug 12919.

*** This bug has been marked as a duplicate of bug 12919 ***

Status: NEW => RESOLVED
Resolution: (none) => DUPLICATE

Comment 10 Jan Pihlgren 2015-12-21 14:36:54 CET
I have my Mageia 5 allways updated.
 Marja van Waes said that I have to try Cauldron with arduino-1.0.6-1.mga6.
Arduino-1.0.6 isn't the latest version.
An as I think the bug is still not fixed.
The latest version is 1.6.6. 
So I still have the question "When will Mageia upgrade Arduino to 1.6.6?
Jan Pihlgren 2015-12-21 14:37:44 CET

Status: RESOLVED => REOPENED
Resolution: DUPLICATE => (none)

Comment 11 Yann Cantin 2015-12-22 03:01:34 CET
No update to 1.6.x is planned for Mageia 5 : package update policy prevent major version change in released distro and there's some dependencies not met in mga5 for the 1.6.x package.

If the current bug is fixed for 1.0.5 (mga5 current version), please revert it to resolved/duplicate.

The 1.6 branch is present in Cauldron (but please, see https://wiki.mageia.org/en/Cauldron ) and so will be in Mageia 6.

In the meantime, you can manually install the upstream 1.6 build in mga5, as I do.
Comment 12 Marja Van Waes 2018-04-18 12:00:19 CEST
(In reply to Yann Cantin from comment #11)
> No update to 1.6.x is planned for Mageia 5 : package update policy prevent
> major version change in released distro and there's some dependencies not
> met in mga5 for the 1.6.x package.
> 
> If the current bug is fixed for 1.0.5 (mga5 current version), please revert
> it to resolved/duplicate.
> 

Doing so now. As a packager, you should have been able to revert it yourself. BugSquad doesn't often look at bug reports that aren't assigned to BugSquad.

@ Jan,

Maybe you were right to not revert the Status of this report, but if you were: you had only said that you thought this bug wasn't fixed, not that you could still reproduce it! We need proof :-)

Anyway, non-security bugs for Mageia 5 no longer get fixed, closing.

*** This bug has been marked as a duplicate of bug 12919 ***

Resolution: (none) => DUPLICATE
Status: REOPENED => RESOLVED


Note You need to log in before you can comment on or make changes to this bug.