code block repeat macro? (art tech)
I am interested in finding a short hand way in the compiler to represent the following Nx2 lines of code (where N=9 at the moment, but may increase): case modeDisplay1: Display(0);break;case...
View ArticleCan't get an interrupt from my timer(s) (Peter Fournier)
PIC32MZ DA, MPLAB X IDE v4.15, Harmony 2.06, XC32 2.05 toolchain. My timers are causing me no end of grief. I have 2 timers Timer2 and Timer4, Timer1 is set as the system timer. I used MHC to set up...
View ArticleTimers and how to set up in MHC (Peter Fournier)
PIC32MZ DAMPLAB X IDE 4.15, Harmony 2.06 I want to use 2 timers Timer 2 and Timer 4in "pic32mz_da_sk_intddr_adma.mhc" belowI notice the system timer is CONFIG_SYS_TMR_DRIVER_INDEX="DRV_TMR_INDEX_0"I...
View ArticleMemory corruption- Makefile Generation (RobL12)
I'm having an issue where the first long word of the .sdata section (initialized STATICs) initializes properly but is cleared sometime following a breakpoint. reserve_data_0_kseg0 is reserved for the...
View ArticleMASTERs Conference - After-Hours MPLAB XC Compiler discussion - Wednesday,...
The Microchip Worldwide MASTERs Conference is this week! Like last year, we will be hosting an evening discussion regarding the 8-, 16-, and 32-bit compilers. Join the Microchip compiler team for an...
View ArticleDRV_TMR_Open does not seem to work properly (Pete F)
PIC32MZ DA MPLAB X IDE 4.15, Harmony 2.06 This was part of previous problem, but the question got out of focus and there was no resolution. I want to use 2 timers Timer 2 and Timer 4 (besides the...
View ArticleAnyone know why PIC32MX274 is coming up yellow in 1.44 & 2.x, not green?...
All,Been wading through linker errors because the MX274 is not supported under plib. Most of these came from the Oscillator registers being split up. Anyway I am a little concerned that the indicator...
View Article_vfprintf_cdfFnop causes Data Bus Error (suprastar)
I am stuck with this one.Sometimes, my app enters the General Exception Handler, and says a Data Bus Error occured, somewhere in the _vfprintf_cdfFnop functionAccording the .map...
View ArticleHow to write and read float numbers to Flash with PIC32MX (seccoxiru)
Hello.This is the first time that I will need to write to and read from flash of a PIC32MX (795F512L) some float numbers using microchip NVM functions (if possible). I know that each flash address of...
View ArticleManaged to break app with MicroSD card (Pete F)
MPLAB X IDE v4.15, Compiler 2.10, Harmony 2.06 Starter Kit DM320010, PIC32MZ DA I have a design which started with the "pmp_lcd" in harmony. While experimenting I also ran the "sdcard_fat_single_disk"...
View ArticleA simple technique to enforce a specific GCC compiler version to be used when...
Sometimes you might want to enforce, in source code, that all developers (and build machines) use the same compiler version to develop/build your product's source code. Here is a simple technique to...
View ArticleCMSIS support for SAMD in XC32 / MPLAB X ? (onnimikki)
Hi,Am wondering if anyone knows about support for the ARM CMSIS programming standard with the SAMD chips with XC32? CMSIS (http://www.keil.com/pack/doc/CMSIS/General/html/index.html) is a way of...
View Articlevoid pointer not casting correctly in v2.05 (PIC32MZDA2064DAH176) (rmorley78)
In my function I have data passed to it as a void pointer. This void pointer is a structure containing other data needed to perform my task. Within the structure being passed is another void pointer...
View ArticleConfused why my small-data section exceeds 64kb (tmbarton)
I'm getting a linker error "small-data section exceeds 64KB" is I compile with the default GP relative addressing threshold of 8 which I can resolve by setting the threshold to 2 using the -G 2 flag....
View ArticlePIC32 MPU6050 output not stable (ArmstrongSubero)
So I have working code for the MPU6050 sensor running on the STM32F103C8T6 with a madgwick filter for sensor fusion and it works great! very stable output with the MikroC for ARM compiler. I ported it...
View ArticlePIC32 USB Host Connection? (ArmstrongSubero)
Hey everyone I have working code for the PIC32MX270F256B micro I worked on like 3 years ago, only on problem I forgot how to connect these devices for reading a flashdrive. Anyone have any schematics?...
View ArticleLocal variable address points to location in heap (boyfreda)
Hello, I am currently debugging an issue I have been having with malloc calls throwing an exception. What I have found was that the heap linked list seems to be getting corrupted. After tracing back...
View ArticlePIC32: How to Pool all string literals globally? (mawadre)
Imagine a header-file mystrings.h which looks like that: #define STRING1 "Lorem ipsum dolor sit amet"#define STRING2 "consetetur sadipscing elitr"#define STRING3 "sed diam nonumy eirmod tempor"... Now...
View ArticleHow to place implicit strings into a common read only section in flash and...
Given that I use strings all over the firmware like that: file1.c:printf(STR("string1");printf(STR("string2"); file2.c:printf(STR("string1");printf(STR("string2"); and the macro STR() is defined...
View ArticlePersistent variable working in debug mode only (hulaomr)
Hello, In summary, my goal is to share data between the bootloader and the application. In debug mode (using ICD4) the approach used is working. However, when the microcontroller is programmed in...
View Article