Dear Sirs, Mr. Coppi! ...I use the CAN-Module of a CA-step. Because everything was fine using the Board, I burned it without looking at the errata sheed...I was surprised at the result! Now I want to please You help me avoid another mistake. The behavior can be avoided if a message object is not updated by software when a transmission of the corresponding message object is pending (TXRQ element is set) and the CAN module is active (INIT = 0). Does that mean, if I would disable the CAN module each time I change something (data) in an object and enable it after that everything will be o.K.? The nodes in the CAN system ignore the remote frame with the identifier=0 and no data frame is triggered by this remote frame. Is this another or additional possibility? Is there a way to disable only the identifier '0'? I'm not so sure if I did understand the errata well, so please don't wonder about this questions. Do You know about a distributor who could have a flash device of the C164? (It's really expensive for me to burn them so often and this could prevent al least wrong startup configurations other mistakes which are not step-specific?!) Thanks a lot for helping me hannes P.S. why differs the behaviour using the RAM of the Board instead of OTP??
Dear Mr.Coppi-it's me again.. Sorry, i became a little lazy knowing You are there kind of a speaking/writing book... but also did not think and know about the things that were done by KEIL ide automaticly case-tool-like... I looked at the manual v1.00 ( because CA-step is indexed by 8EM: The descriptions in this manual refer to the following derivatives of the C164-class: l C164CI-8EM Version with 64 KByte on-chip OTP memory ...correct?? Following given addressranges i found: 0x0000-0x8000 :lower 32kB OTP 0xEF00-0xEFFF :CAN !!! is this wrong? You wrote:If you try to allocate segments in the space E000-E7FF, they are allocated into nowhere.!!! 0xF000-0xF1FF :esfr 0xFE00-0xFFFF :sfr 0xF600-0xFDFF :RAM 0xE000-0xF000 :XRAM + CAN !!!!!same question as above!!!!!!!!! (Does there exist exact tables of Memory organization for all the Steps?) These values i wrote into the Memory Map and tested. Programm "crashed" (error message appeared), because indirect addressed Memory at address 0xE200 was accessed. Looking at the device database the Memory is defined at these addresses:CPU=IRAM(0xF600-0xFDFF) XRAM(0xE000-0xE7FF) CLOCK(20000000) IROM (0-0xFFFF) ICAN(0xE800-0xEFFF) MOD167 I could define a new C164CI_CA e.g. to avoid the wrong accesses, i think???! I'm sorry, but don't really know where to find the exact Memoryorganization of CA step. Please could You help again? hannes
I don't know anything about the C164 but for the C167, I had to enable the XRAM before I used it,
MOV XPERCON,#0403H ; Enable CAN 1 and CAN 2 Xbus peripherals ; Enable XRAM 2 KByte memory ; Disable XRAM 6 KByte memory NOP NOP MOV SYSCON,#8184H ; Stack size = 512 words ; Internal rom starts at 00'0000 ; Segmentation enabled ; Internal rom disabled ; BHE pin enabled ; Clock out pin enabled ; WR is write low, BHE is write high ; Xbus peripherals are enabled ; Xbus accesses are not visible on external bus ; Xbus peripherals not accessable on external bus
Hi Brad, the C164 is older than other C16x derivatives so the XPERCON register is not present, you just have a more generic bit XPEN in the SYSCON register used to enable/disable XRAM (when present) and CAN.