From nanda.chinmay at gmail.com Sun Aug 5 06:15:16 2012 From: nanda.chinmay at gmail.com (Chinmay Nanda) Date: Sun, 5 Aug 2012 02:15:16 -0400 Subject: [arm-gnu] Big project problems STM32F4 Discovery with G++ Message-ID: Dear All, Greetings !! I am a newbie to the ARM processors but have worked with micro controllers in general for quite some time. I recently got my hands on the STM32F4 Discovery board(the price was the real motivation I would admit )and started exploring all that I could do with it. Going through the various resources that I could get my hands on I could set up the GNU tool chain for the eclipse environment and debug a simple LED blinking code. So, I decided to give try out some of the bigger projects such as the audio player example given in the ST code examples. After putting every single path on the includes , folder and the related source folders(I followed the Atollic directory structure) I am getting the following errors. *"D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:139:6: error: #error "USB_OTG_HS_CORE or USB_OTG_FS_CORE should be defined"* *D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:152:6: error: #error "USE_USB_OTG_HS or USE_USB_OTG_FS should be defined"* *cs-make: *** [temp_folder/usb_bsp.o] Error 1"* While this may seem as simple problems related to the path/symbols not being included, that does not seem to be the case. Kindly point me in the right direction. -- *Regards,* *c_nanda* -------------- next part -------------- An HTML attachment was scrubbed... URL: From spen at spen-soft.co.uk Mon Aug 6 16:09:33 2012 From: spen at spen-soft.co.uk (Spencer Oliver) Date: Mon, 6 Aug 2012 17:09:33 +0100 Subject: [arm-gnu] Big project problems STM32F4 Discovery with G++ In-Reply-To: References: Message-ID: On 5 August 2012 07:15, Chinmay Nanda wrote: > > "D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:139:6: > error: #error "USB_OTG_HS_CORE or USB_OTG_FS_CORE should be defined" > D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:152:6: > error: #error "USE_USB_OTG_HS or USE_USB_OTG_FS should be defined" > cs-make: *** [temp_folder/usb_bsp.o] Error 1" > By looking at the above the error it is quite self explanatory - you need to setup the st usb libs correctly. > While this may seem as simple problems related to the path/symbols not > being included, that does not seem to be the case. > Kindly point me in the right direction. > -- As you are using gcc included with Atollic, i would guess http://www.atollic.com/ Spen From nanda.chinmay at gmail.com Tue Aug 7 00:38:07 2012 From: nanda.chinmay at gmail.com (Chinmay Nanda) Date: Mon, 6 Aug 2012 20:38:07 -0400 Subject: [arm-gnu] Big project problems STM32F4 Discovery with G++ In-Reply-To: References: Message-ID: Hello Spencer, Many thanks for your reply. I am trying to build a custom opensource tool chain , I could get the atollic tool chain to work. without much effort. But, it has a code limitation of 32K , that I cannot live with at the moment. So I searched on the internet and could come up with the following option. Project details: Board: STM32F4 Discovery IDE: Eclipse Indigo Compiler: Code sourcery G++ Lite Debugger: Atollic I could run the LED blinking example but was facing the problem that I mentioned for the sample wave project. So, that's the long story short.. I may sound dumb but, what do you mean by setting up the usb libraries correctly, do you wnat me to edit the libraries, or some header file ? I could try the latter, but dont have much expertise with the former.. On Mon, Aug 6, 2012 at 12:09 PM, Spencer Oliver wrote: > On 5 August 2012 07:15, Chinmay Nanda wrote: > > > > > "D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:139:6: > > error: #error "USB_OTG_HS_CORE or USB_OTG_FS_CORE should be defined" > > > D:/eclipse_indigo/stm32f4discovery_fw/STM32F4-Discovery_FW_V1.1.0/Project/Audio_playback_and_record/inc/usb_conf.h:152:6: > > error: #error "USE_USB_OTG_HS or USE_USB_OTG_FS should be defined" > > cs-make: *** [temp_folder/usb_bsp.o] Error 1" > > > > By looking at the above the error it is quite self explanatory - you > need to setup the st usb libs correctly. > > > While this may seem as simple problems related to the path/symbols not > > being included, that does not seem to be the case. > > Kindly point me in the right direction. > > -- > > As you are using gcc included with Atollic, i would guess > http://www.atollic.com/ > > Spen > -- *Regards,* *Chinmay Nanda* -------------- next part -------------- An HTML attachment was scrubbed... URL: From peter at seng.de Thu Aug 16 20:10:20 2012 From: peter at seng.de (Peter Seng) Date: Thu, 16 Aug 2012 22:10:20 +0200 Subject: [arm-gnu] strtoull - Newlib C Library - NoGo Message-ID: <1345147820.4666.39.camel@seng-P560> Hello, for me there is a problem with the use of the Newlib C Library (1.18.0-sg++) (stdlib.h) included in ?Sourcery CodeBench Lite?. When including function ?strtoull? in program code, communication via USART switches to baudrate x 4 (?!), sometimes HardFault_Handler interrupt occurs. No error messages, no warnings during compile and run (when not HardFault), other part of program seems to run correctly. Same behavior when using 2011.03 / 2011.09 and 2012.03 versions of Sourcery Codebench Lite. Function ?strtoul? seems to be not affected, other functions out of this library are working without problems since months. Any ideas? -- with best regards Peter Seng =========================== eMail: info at seng.de =========================== From carlos_odonell at mentor.com Thu Aug 16 21:01:10 2012 From: carlos_odonell at mentor.com (Carlos O'Donell) Date: Thu, 16 Aug 2012 17:01:10 -0400 Subject: [arm-gnu] strtoull - Newlib C Library - NoGo In-Reply-To: <1345147820.4666.39.camel@seng-P560> References: <1345147820.4666.39.camel@seng-P560> Message-ID: <502D5F96.90502@mentor.com> On 8/16/2012 4:10 PM, Peter Seng wrote: > Hello, > > for me there is a problem with the use of the Newlib C Library > (1.18.0-sg++) (stdlib.h) included in ?Sourcery CodeBench Lite?. When > including function ?strtoull? in program code, communication via USART > switches to baudrate x 4 (?!), sometimes HardFault_Handler interrupt > occurs. > No error messages, no warnings during compile and run (when not > HardFault), other part of program seems to run correctly. Same behavior > when using 2011.03 / 2011.09 and 2012.03 versions of Sourcery Codebench > Lite. > Function ?strtoul? seems to be not affected, other functions out of this > library are working without problems since months. > > Any ideas? Look for stack corruption when you call strtoull? Is the stack correctly aligned when the function call is made? Is another function misaligning the stack? Cheers, Carlos. -- Carlos O'Donell Mentor Graphics / CodeSourcery carlos_odonell at mentor.com carlos at codesourcery.com +1 (613) 963 1026 From andre at bluewatersys.com Thu Aug 16 21:06:50 2012 From: andre at bluewatersys.com (Andre Renaud) Date: Fri, 17 Aug 2012 09:06:50 +1200 Subject: [arm-gnu] New 2012 linux gnueabi lite release soon? Message-ID: Hi, I'm doing some work under Linux on a Cortex-A9 system, and having some difficulty getting a working compiler. I've tried both arm-2012.03-57 and arm-2011.09-70, but each of them suffers from a different GLIBC bug. I'm trying to avoid doing a compiler build, as this has always given me grief in the past. Does anyone know if there is a new 2012 release expected soon? For reference, the bugs I'm hitting are: 2011.09: http://sourceware.org/bugzilla/show_bug.cgi?id=12454 2012.03: http://sourceware.org/bugzilla/show_bug.cgi?id=13906 Regards, Andre -- Bluewater Systems - An Aiotec Company Andre Renaud andre at bluewatersys.com 5 Amuri Park, 404 Barbadoes St www.bluewatersys.com PO Box 13 889, Christchurch 8013 www.aiotec.co.nz New Zealand Phone: +64 3 3779127 Freecall: Australia 1800 148 751 Fax: +64 3 3779135 USA 1800 261 2934 From carlos_odonell at mentor.com Thu Aug 16 21:32:17 2012 From: carlos_odonell at mentor.com (Carlos O'Donell) Date: Thu, 16 Aug 2012 17:32:17 -0400 Subject: [arm-gnu] New 2012 linux gnueabi lite release soon? In-Reply-To: References: Message-ID: <502D66E1.8080904@mentor.com> On 8/16/2012 5:06 PM, Andre Renaud wrote: > Hi, > I'm doing some work under Linux on a Cortex-A9 system, and having some > difficulty getting a working compiler. I've tried both arm-2012.03-57 > and arm-2011.09-70, but each of them suffers from a different GLIBC > bug. I'm trying to avoid doing a compiler build, as this has always > given me grief in the past. Does anyone know if there is a new 2012 > release expected soon? > > For reference, the bugs I'm hitting are: > 2011.09: http://sourceware.org/bugzilla/show_bug.cgi?id=12454 > 2012.03: http://sourceware.org/bugzilla/show_bug.cgi?id=13906 The releases are typically Spring then Fall. I can't comment on when the next Lite edition release will be out, or if it will contain the fix for BZ#13906. We do offer the option of buying a Professional edition subscription with support, through which you can request a release of the commercial product with a fix for BZ#13906. Cheers, Carlos. -- Carlos O'Donell Mentor Graphics / CodeSourcery carlos_odonell at mentor.com carlos at codesourcery.com +1 (613) 963 1026 From info at seng.de Wed Aug 29 14:16:24 2012 From: info at seng.de (info at seng.de) Date: Wed, 29 Aug 2012 16:16:24 +0200 Subject: [arm-gnu] strtoull - Newlib C Library - No Message-ID: <1346249784.1894.7.camel@seng-P560> Hello, Already increased stack size --> same result. replaced "strtoull" by some source-code I fished from the net. Hopefully started the program - and had the same result... Identified the following sequence inside the code that leads to the strange result: long long test1 = 10, test2 = 4, test3; test3 = test1 / test2; As soon as the code of a division of a long long variable exists inside the program (no matter where), the program shows the strange results. Think that the code of strtoull contains a division too. Manual "Using the GNU Compiler Collection, chapter 6.9" tells that long long divisions are open coded and are available only on machines 'providing special support'. So the solution is just to not use long long division, which is OK for me. It would be just of interest for me how the code of the division can alter the program in a way that: + everything still works + debug functionality is still fine + even the result of the long long division is OK - the baudrate changes to baudrate X 4 (which is defined by the content of a CPU-register, not by the translated code itself) Any Ideas? -- with best regards Peter Seng =========================== Peter Seng eMail: info at seng.de =========================== From raproskie at tellumat.com Fri Aug 31 10:05:52 2012 From: raproskie at tellumat.com (Robin Aproskie) Date: Fri, 31 Aug 2012 12:05:52 +0200 Subject: [arm-gnu] PC-Lint Message-ID: Hi I am using Make File project to compile C code for My ARM7 ADuC7020 uC Compiler: BIN=C:/CodeSourcery/Sourcery_CodeBench_Lite_for_ARM_EABI/bin/arm-none-eabi- I am also using freeRTOS. I am using PC-LINT V8.00 and would like to know if there are any option.lnt files anywhere that can help sort out problems with the stdint.h that sre ARM7 / Code Sourcery Lite specific There are so many errors i can't even lint my code. Thanks Example errors: 1. #define IRQEN (*(volatile unsigned long *) 0XFFFF0008) saveIRQ = IRQEN; C:\projects\workspace\PDLU_PA\changeMode.c:40:19: Note 923: cast from unsigned int to pointer [MISRA Rule 45] 2. IRQCLR = 0xFFFF; Multiple markers at this line - Note 970: Use of modifier or type 'unsigned' outside of a typedef [MISRA Rule 13] - Note 970: Use of modifier or type 'long' outside of a typedef [MISRA Rule 13] - Note 923: cast from unsigned int to pointer [MISRA Rule 45] Others C:\projects\workspace\PDLU_PA\stdint.h:34:30: Warning 553: Undefined preprocessor variable 'LONG_MAX', assumed 0 [MISRA Rule 97] C:\projects\workspace\PDLU_PA\stdint.h:36:47: Note 961: Violates MISRA Advisory Rule 12.1, dependence placed on C's operator precedence; operators: '==' and '&&' C:\projects\workspace\PDLU_PA\stdint.h:36:63: Warning 553: Undefined preprocessor variable 'LONG_MAX', assumed 0 [MISRA Rule 97] C:\projects\workspace\PDLU_PA\stdint.h:40:32: Warning 553: Undefined preprocessor variable 'SCHAR_MAX', assumed 0 [MISRA Rule 97] Rob ********************************************************************** Relevant company disclaimers are available at the following addresses: Tellumat (Pty) Ltd e-mail: mailto:disclaimer at tellumat.com?Subject=Tellumat_Disclaimer Web: http://www.tellumat.com/email.aspx ********************************************************************** -------------- next part -------------- An HTML attachment was scrubbed... URL: