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

 
 

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

Submitter:  Keith Rothman <keith_rothman>
Submitted:  Tue 06 Mar 2012 03:30:07 AM UTC
   
 
Category:  Simulation Severity:  3 - Normal
Item Group:  None Status:  Postponed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed Component Version:  * simulavrxx
* Mandatory Fields

Add a New Comment Rich Markup
   

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>
Group 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 Files:
   
   
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
  • -email is unavailable- added by petrh (Posted a comment)
  • -email is unavailable- added by keith_rothman (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 4 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2012-03-22 petrh StatusNone Postponed
        Open/ClosedOpen Closed
        Component Versionsimulavr simulavrxx
    2012-03-06 keith_rothman Attached File- Added test.c, #25274

    Back to the top

    Powered by Savane 3.13-4b48.
    Corresponding source code