We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi,
I found some demo applications on the website of TI, but it seems that those aren't working in Keil uVision, or with the headerfile I can download from the Keil site located here: http://www.keil.com/dd/chip/4070.htm
I was wondering if I can find somewhere any demo codes, like GPIO, CAN and SPI for this microcontroller using Keil uVision. Does anyone here has some demo code/examples available?
Thanks a lot.
I get the error "This file should only be compiled by ARM IAR compiler and assembler" so it seems that is does not work with Keil uVision.
I can compile with IAR Embedded Workbench, but I would like to use Keil uVision for the programming. Maybe there are somewhere other code examples? I cannot find them.. or a good header file with the register separated.
"I get the error 'This file should only be compiled by ARM IAR compiler and assembler'"
If you have the files as source then, surely, that could only come from a #error directive?
So part of your porting from IAR to Keil would be to adjust that!
Keil's header file is available on the link you gave in your original post.
I couldn't see any TMS470-specific examples at http://www.keil.com/download/list/arm.htm
TI seem to be in bed with IAR for this controller - there's no mention of Keil on their "TMS470 Third-Party Network" page: focus.ti.com/.../mcugeneralcontent.tsp
So, the pragmatic approach would seem to be to go with IAR - at least while you gain basic familiarity with the chip...?
We have TMS470 support in the folder Keil\ARM\Boards\TI. Did you look to this examples?
Yes the error is coming from a #error handler. Here it is
#if (((__TID__ >> 8) & 0x7F) != 0x4F) /* 0x4F = 79 dec */ #error This file should only be compiled by ARM IAR compiler and assembler #endif
but when I comment this code and try to compile it in Keil uVision I get the error message something like "The instruction at 0x00752533 is refering to memory address 0x00000030. The read-adaption on the memory has failed" something like that.. I get these message in dutch so maybe it's a bit different in english :) It's about this line in the header file iotms470r1a256.h
/* ** ** System module control (SMC) ** */
__IO_REG32_BIT(SMCR0, 0xfffffd00,__READ_WRITE,__smcr0_bits);
so I guess if I want to use these code examples I have to go with IAR like you said Neil.
I saw the Blinky example in Keil\ARM\Boards\TI\ folder and I can compile that one but I am more looking for code examples of SPI and CAN. But maybe I can figure it out with the user manuael and the header file in the Blinky example. I guess there are no examples of these peripherals somewhere, working with uVision?
Well thanks already.