porting C code from AVR to 8051

The code does alot of IO port operations.
Keil uses SFR and SBIT declarations whereas the AVR code uses defines to set IO port locations and
byte operations to set/clear/test bits. There has to be a better way than slogging through the text conversion and then slogging through the debug???

Parents
  • before you port the code, you need to understand how it relates to the underlying hardware.

    Keil SFR and SBIT relate directly to the 8051 hardware - you're going to have to determine how the existing code relates to the AVR hardware, how that can be translated to 8051 hardware, and how that, in turn can be represented in software.

Reply
  • before you port the code, you need to understand how it relates to the underlying hardware.

    Keil SFR and SBIT relate directly to the 8051 hardware - you're going to have to determine how the existing code relates to the AVR hardware, how that can be translated to 8051 hardware, and how that, in turn can be represented in software.

Children
More questions in this forum