??? 06/15/09 14:04 Read: times |
#166092 - If I read this correctly Responding to: ???'s previous message |
Hardware:
I'm thinking on making a bus system where there are 4 identical PCB's linked together trough the AD lines. (P0 & P2) On each PCB there are 4 identical components which each have 28 registers that can be programmed. (thus using 6 address lines) i am using the upper 2 latched address lines to select which of the 4 devices to program. P2.0 and P2.1 are used to enable communication with each individual PCB board. Code: Since the devices are similar I would like to memory map the struct specified in the external.h file 16 times to the corresponding addressed device. * Can i just do so by assigning an address to it as done in the parameter.c file? If I read this correctly, I read that you want device a to read from device b by mov a,@dptr or var = xxxx; this will not work, device b will not present the data in any 'stable' fashion, it will only be there during a device b read from memory (1us or less). The traditional faulty way to parallel communicate parallel between devices is as follows two registers: address and data bits: read request and data available, both true low this works till you have two simultaneous read requests (may take a second, may take a year) I know of two methods that will work 1) a MASTER controller that, in a round robin fashion interrogates the slaves 2) a (in your case (4-controllers) quad port memory with sentinels (Cypress has those) What memory model should I choose best, do i really need the large memory specifier since, according to the data sheet enabling and disabling EXTRAM bit in the AUXR register should activate switching between internal and external memory access. I ask this question cause I would also like to keep use of the internal XRAM of the chip. wrong again 1) the LARGE memory model does NOT set the AUXR, you need to do that in startup 2) the LARGE memory model will increase your program size dramatically and make it run far slower, use the SMALL model and the xdata qualifier for variables/MMIO you have in xdata * Can it be done by using the #pragma large in the parameter.c file? yes, but don't *aside of setting the size and start address of the XRAM do there need to be made any other alterations to the linker? 1) you do not set the XDATA addresses in the linker 2) no alterations needed Erik |
Topic | Author | Date |
AT89c51cc01 and External memory (keil/C51) | 01/01/70 00:00 | |
Cross posted | 01/01/70 00:00 | |
Is your problem with FLIP ? | 01/01/70 00:00 | |
No, think it's keil compiler | 01/01/70 00:00 | |
Sounds like an error in the data sheet | 01/01/70 00:00 | |
bible time | 01/01/70 00:00 | |
Itterations | 01/01/70 00:00 | |
just won't get flashed into the µc?? | 01/01/70 00:00 | |
The compile will compile what you tell it | 01/01/70 00:00 | |
RE: your example does not access any xdata at all | 01/01/70 00:00 | |
RE: Rob Stoffels said:I think there is something that needs | 01/01/70 00:00 | |
Going to try something different | 01/01/70 00:00 | |
Broken Boards? | 01/01/70 00:00 | |
Memmory mapping question/ Bord fixed | 01/01/70 00:00 | |
If I read this correctly | 01/01/70 00:00 | |
Missunderstanding | 01/01/70 00:00 | |
xdata will just be whatever EXTRAM says | 01/01/70 00:00 | |
do you have any external RAM?![]() | 01/01/70 00:00 | |
CC03 is working | 01/01/70 00:00 |