| ??? 04/27/01 07:48 Read: times |
#11179 - RE: Dynamic Arrays (calloc) |
Hi Marshall,
you must forget totally your programming style for PC programms, since you have only 128 byte of RAM on the 2051 ! If I assume, that any memory control block need 8 byte, than its pure waste to do it for any single byte. I assume the error occur, since calloc() only available for the large memory model with 64kB external RAM connected. There was also no sense to use calloc() for a serial buffer, since the buffer can never be released (receive can occur anytime). My hint: Try first to program the 2051 in assembler to find out how it works and how the special features (UART, timers, interrupts) should be used. Then compile with generating the assembler listing and look how awkward you have programmed at first. On my home page you can found some examples, which are written in respect to the resources available on the 8051: http://www.specs.de/~danni/contents.htm Also look on the C51-primer: http://www.esacademy.com/automatio...c51primer/ Peter |
| Topic | Author | Date |
| Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
| RE: Dynamic Arrays (calloc) | 01/01/70 00:00 | |
RE: Dynamic Arrays (calloc) | 01/01/70 00:00 |



