6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Fri Oct 04, 2024 1:23 pm

All times are UTC




Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: V and C flag emulation
PostPosted: Sun Jun 28, 2009 5:27 pm 
Offline

Joined: Wed Jun 24, 2009 12:25 am
Posts: 29
hi! me again...
i'm having some problems while emulating the flags Carry and oVerflow. does anybody know an efficient way to emulate it? Or maybe somebody can explain me how these flags works, because i don't understand the docs i found (maybe my english level isn't very good? :( )


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Jun 28, 2009 6:09 pm 
Online
User avatar

Joined: Thu Dec 11, 2008 1:28 pm
Posts: 10943
Location: England
There are quite a few independent emulators out there, each will have source code to do exactly this. Reading the source is a good habit: you can always learn from other people's solutions.

You could start at http://6502.org/tools/emu/

Cheers
Ed


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Jun 28, 2009 6:14 pm 
Offline
Site Admin
User avatar

Joined: Fri Aug 30, 2002 1:08 am
Posts: 281
Location: Northern California
You might want to read The Overflow (V) Flag Explained by Bruce Clark.

Regards,
Mike

_________________
- Mike Naberezny (mike@naberezny.com) http://6502.org


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Sun Jun 28, 2009 7:17 pm 
Offline

Joined: Wed Jun 24, 2009 12:25 am
Posts: 29
thnaks fellas. lets see what comes out...


Top
 Profile  
Reply with quote  
PostPosted: Mon Jun 29, 2009 9:04 pm 
Offline

Joined: Tue Nov 18, 2003 8:41 pm
Posts: 250
ehguacho wrote:
hi! me again...
i'm having some problems while emulating the flags Carry and oVerflow. does anybody know an efficient way to emulate it? Or maybe somebody can explain me how these flags works, because i don't understand the docs i found (maybe my english level isn't very good? :( )


V is the exclusive or of the carrys out of bits 6 and 7


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Mon Jun 29, 2009 9:07 pm 
Offline

Joined: Tue Nov 18, 2003 8:41 pm
Posts: 250
Mike Naberezny wrote:
You might want to read The Overflow (V) Flag Explained by Bruce Clark.

Regards,
Mike


I think there's a goof there (appendix A) :

"Sure enough, 171 is the unsigned number represented by $AB (10101001)"


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC


Who is online

Users browsing this forum: BigEd and 10 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: