Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
10/01/04 13:01
Read: times


 
#78503 - RE: Port 0 as memory mapped i/o
Responding to: ???'s previous message

If you can show us how you access it in assembler code, we might be able to give you some hints as to converting it to 'c'. If your asm code access the port as port0 then the 'c' compiler with do the same, if you want to access it as memory, then you need to tell the 'c' compiler to access it the same way. See the Keil site for instructions on accessing absolute memory locations.

Andy - it's not unreasonable to convert from asm to 'c'. At the least it can be instructive. Many people in my office can program in 'c' whereas I'm about the only one fluent in assembler - so I use 'c' where possible so I'm not stuck with maintaining everything! But I understand your point. Sometimes coping with the vagaries of the 8051 'c' compilers and trying to interface assembler routines can be a little daunting. I switched brands of 'c' compiler on the 8051 and that kept me pulling my hair out for a little while!




List of 16 messages in thread
TopicAuthorDate
Port 0 as memory mapped i/o            01/01/70 00:00      
   RE: Port 0 as memory mapped i/o            01/01/70 00:00      
      RE: Port 0 as memory mapped i/o            01/01/70 00:00      
         Pointless excercise #1            01/01/70 00:00      
            RE: Pointless excercise #1            01/01/70 00:00      
               RE: Pointless excercise #1            01/01/70 00:00      
         RE: Port 0 as memory mapped i/o            01/01/70 00:00      
         RE: Port 0 as memory mapped i/o            01/01/70 00:00      
   RE: Port 0 as memory mapped i/o            01/01/70 00:00      
      RE: Port 0 as memory mapped i/o            01/01/70 00:00      
         Does the Pepsi generation not use Asm?            01/01/70 00:00      
      RE: Port 0 as memory mapped i/o            01/01/70 00:00      
         RE: Port 0 as memory mapped i/o            01/01/70 00:00      
            RE: Converting assembler to C            01/01/70 00:00      
         RE: Port 0 as memory mapped i/o            01/01/70 00:00      
            RE: Port 0 as memory mapped i/o            01/01/70 00:00      

Back to Subject List