Author |
Message |
Topic: Problem with structure size |
Benjamin
Replies: 3
Views: 8437
|
Forum: General CCS C Discussion Posted: Wed Feb 09, 2011 10:07 am Subject: Problem with structure size |
Here's an update in case someone else runs into the same problem.
The CCS manual does mention that the compiler will align 16 bit fields in a structure to even bytes.
And when asked if it is pos ... |
Topic: Problem with structure size |
Benjamin
Replies: 3
Views: 8437
|
Forum: General CCS C Discussion Posted: Fri Jan 28, 2011 3:27 pm Subject: Problem with structure size |
Thanks! You're right. The compiler does "pad" the elements to 'int16' size.
offsetof(fDiskInfo,BytsPerSec); returns 12. So the compiler adds a byte after OEMName and probably adds on ... |
Topic: Problem with structure size |
Benjamin
Replies: 3
Views: 8437
|
Forum: General CCS C Discussion Posted: Fri Jan 28, 2011 2:49 pm Subject: Problem with structure size |
Hello,
I've been having problems with structures lately, and found that the size of my structures are not giving what I expected. To simplify my problem, I've written the following program:
v ... |
Topic: Larger than 5x7 fonts |
Benjamin
Replies: 3
Views: 9704
|
Forum: General CCS C Discussion Posted: Thu Jan 20, 2011 8:32 am Subject: Larger than 5x7 fonts |
Thanks!
I've downloaded both Microchip's App Lib and the GLCD Font Creator.
I've started with the Font Creator and really like it, especially it's flexibility and the ability to import system fonts. ... |
Topic: Larger than 5x7 fonts |
Benjamin
Replies: 3
Views: 9704
|
Forum: General CCS C Discussion Posted: Wed Jan 19, 2011 3:44 pm Subject: Larger than 5x7 fonts |
Hello,
I'm looking for a table of fonts in 'c' that is larger than 5x7. The 5x7 font is a little small on my LCD, and I don't want to double the size (to big, and to ugly). I also don't know what ... |
Topic: Union + Structure = me go crazy |
Benjamin
Replies: 6
Views: 10038
|
Forum: General CCS C Discussion Posted: Wed Dec 22, 2010 8:59 am Subject: Union + Structure = me go crazy |
Yes it's a typo, the example is just something I typed in my question.
Should of been:
TD_INFO variable_info;
variable_info.byte = read_data();
switch(variable_info.bits.type ... |
Topic: Union + Structure = me go crazy |
Benjamin
Replies: 6
Views: 10038
|
Forum: General CCS C Discussion Posted: Wed Dec 22, 2010 8:40 am Subject: Union + Structure = me go crazy |
Short question on unions. Is this legal:
typedef union _TYPE_DONNEES
{
unsigned char byte;
struct _BITS
{
unsigned int8 format:4; // LSB
unsigned in ... |
Topic: Using bits on 16bit microcontroller |
Benjamin
Replies: 3
Views: 5314
|
Forum: General CCS C Discussion Posted: Mon Dec 13, 2010 2:16 pm Subject: Using bits on 16bit microcontroller |
Very logic. Thanks for the fast answers for a not so bright question (.B = Byte). I wasn't sure that we could access the registers by byte.
Thanks again! |
Topic: Using bits on 16bit microcontroller |
Benjamin
Replies: 3
Views: 5314
|
Forum: General CCS C Discussion Posted: Mon Dec 13, 2010 1:32 pm Subject: Using bits on 16bit microcontroller |
Hello,
I'm new with 16 bit microcontrollers, and using DSPIC33FJ256GP710. I've changed my register addressing to "#word" instead of "#byte", but when I set a bit in a register, ... |
Topic: Debugging and ram breakpoints. |
Benjamin
Replies: 3
Views: 5272
|
Forum: General CCS C Discussion Posted: Thu Aug 20, 2009 10:02 am Subject: Debugging and ram breakpoints. |
Hello Jim,
Just wondering if you got the Ram Breakpoints working because I'm having the same problem as you did.
Thank you,
Benjamin. |
Topic: Version 4 Comments |
Benjamin
Replies: 270
Views: 438477
|
Forum: General CCS C Discussion Posted: Tue Nov 04, 2008 3:29 pm Subject: Version 4 Comments |
Guest: you can save your configuration in the Options ribbon. |
Topic: Version 4 Comments |
Benjamin
Replies: 270
Views: 438477
|
Forum: General CCS C Discussion Posted: Thu Nov 22, 2007 2:18 pm Subject: Hi Ed |
I haven't tried multiple compilation units and I haven't had to change anything in my programs for them to work (no v3 compatilibity stuff), they compile and work fine. |
Topic: Version 4 Comments |
Benjamin
Replies: 270
Views: 438477
|
Forum: General CCS C Discussion Posted: Wed Nov 21, 2007 4:09 pm Subject: Version 4 Comments |
I've switched to version 4 since 4.060, (been using 3.249) and tried two very big projects on PIC18F6722, using UARTS, SPI, external memory (using addressmod), I2C... and everything compiles and works ... |
Topic: Another MMC Over SPI FAT32 code! |
Benjamin
Replies: 84
Views: 571659
|
Forum: Code Library Posted: Tue Aug 07, 2007 1:57 pm Subject: Another MMC Over SPI FAT32 code! |
Thanks for the answer,
I did write the same question to Tomi and I'm waiting for his response. I believe the code should work with any disk smaller than 260 MB, since Microsoft formats these disks ... |
Topic: FAT32 code for MultiMedia Cards |
Benjamin
Replies: 66
Views: 554857
|
Forum: Code Library Posted: Tue Aug 07, 2007 11:55 am Subject: FAT32 code for MultiMedia Cards |
Tomi,
There's something that I don't get in your code. You don't seem to bother about the number of sectors per cluster? (see Boot Sector variable SecPerClus) Your code is writen as if there was ... |
|