bugSimulavr: an AVR simulator - Bugs: bug #35726, Programs compiled with...

 
 

bug #35726: Programs compiled with -mmcu=atmega32hvb cannot be simulated as expected

Submitted by:  Keith Rothman <keith_rothman>
Submitted on:  Tue 06 Mar 2012 03:30:07 AM UTC  
 
Category: SimulationSeverity: 3 - Normal
Item Group: NoneStatus: Postponed
Privacy: PublicAssigned to: None
Open/Closed: ClosedComponent Version: simulavrxx

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 22 Mar 2012 10:18:22 PM UTC, comment #1:

The parts have different IO range:
ATmega32 has 0x20 - 0x5f
ATmega32hvb has 0x20 - 0xFF

In the common subset range the registers are quite different (0x20: TWBR vs PINA), Timer0 is 8bit vs 16bit etc.

The ATmega32hvb is not supported, not even partially supported.
Someone has to contribute a patch to add this support.

Petr Hluzin <petrh>
Project Member
Tue 06 Mar 2012 03:30:07 AM UTC, original submission:

Compiling attached file test.c with:
avr-gcc -mmcu=atmega32hvb test.c

And run the output with simulavr:
simulavr -d atmega32 -W 0x20,- -f a.out -T exit

Results in:
WARNING: file rwmem.cpp: line 124: Invalid write access to IO[0x8fb]=0x0, PC=0xd0
WARNING: file rwmem.cpp: line 124: Invalid write access to IO[0x8fa]=0x1, PC=0xd2
WARNING: file rwmem.cpp: line 115: Invalid read access from IO[0x8fa], PC=0xd4
WARNING: file rwmem.cpp: line 115: Invalid read access from IO[0x8fb], PC=0xd6
aWARNING: file rwmem.cpp: line 115: Invalid read access from IO[0x8fa], PC=0xca
WARNING: file rwmem.cpp: line 115: Invalid read access from IO[0x8fb], PC=0xcc

Repeating forever. My understanding was that atmega32* parts should be equivalent from a CPU standpoint and it would be reasonable to expect this to work. What am I missing?

Keith Rothman <keith_rothman>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #25274:  test.c added by keith_rothman (124B - text/x-csrc)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by petrh (Posted a comment)
  • -unavailable- added by keith_rothman (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu 22 Mar 2012 10:18:22 PM UTCpetrhStatusNone=>Postponed
      Open/ClosedOpen=>Closed
      Component Versionsimulavr=>simulavrxx
    Tue 06 Mar 2012 03:30:21 AM UTCkeith_rothmanAttached File-=>Added test.c, #25274

    Back to the top


    Powered by Savane 3.1-cleanup1