Annotation of previous_trunk/src/includes/NextBus.hpp, revision 1.1.1.1

1.1       root        1: #pragma once
                      2: 
                      3: #ifndef __NEXT_BUS_H__
                      4: #define __NEXT_BUS_H__
                      5: 
                      6: #include <SDL_stdinc.h>
                      7: #include "log.h"
                      8: #include "cycInt.h"
                      9: 
                     10: #define LOG_NEXTBUS_LEVEL   LOG_NONE
                     11: 
                     12: #ifdef __cplusplus
                     13: extern "C" {
                     14: #endif /* __cplusplus */
                     15:     void nextbus_init(void);
                     16: 
                     17:     Uint32 nextbus_slot_lget(Uint32 addr);
                     18:     Uint32 nextbus_slot_wget(Uint32 addr);
                     19:     Uint32 nextbus_slot_bget(Uint32 addr);
                     20:     void nextbus_slot_lput(Uint32 addr, Uint32 val);
                     21:     void nextbus_slot_wput(Uint32 addr, Uint32 val);
                     22:     void nextbus_slot_bput(Uint32 addr, Uint32 val);
                     23: 
                     24:     Uint32 nextbus_board_lget(Uint32 addr);
                     25:     Uint32 nextbus_board_wget(Uint32 addr);
                     26:     Uint32 nextbus_board_bget(Uint32 addr);
                     27:     void nextbus_board_lput(Uint32 addr, Uint32 val);
                     28:     void nextbus_board_wput(Uint32 addr, Uint32 val);
                     29:     void nextbus_board_bput(Uint32 addr, Uint32 val);
                     30:     
                     31:     void NextBus_Reset(void);
                     32:     void NextBus_Pause(bool pause);
                     33: #ifdef __cplusplus
                     34: }
                     35: #endif /* __cplusplus */
                     36: 
                     37: #ifdef __cplusplus
                     38: 
                     39: #define FOR_EACH_SLOT(slot) for(int (slot) = 2; (slot) < 8; (slot) += 2)
                     40: #define IF_NEXT_DIMENSION(slot, nd) if(NextDimension* nd = dynamic_cast<NextDimension*>(nextbus[(slot)]))
                     41: 
                     42: class NextBusSlot {
                     43: public:
                     44:     int slot;
                     45:     
                     46:     NextBusSlot(int slot);
                     47:     
                     48:     virtual ~NextBusSlot();
                     49:     
                     50:     virtual Uint32 slot_lget(Uint32 addr);
                     51:     virtual Uint16 slot_wget(Uint32 addr);
                     52:     virtual Uint8  slot_bget(Uint32 addr);
                     53:     virtual void   slot_lput(Uint32 addr, Uint32 val);
                     54:     virtual void   slot_wput(Uint32 addr, Uint16 val);
                     55:     virtual void   slot_bput(Uint32 addr, Uint8 val);
                     56:     
                     57:     virtual Uint32 board_lget(Uint32 addr);
                     58:     virtual Uint16 board_wget(Uint32 addr);
                     59:     virtual Uint8  board_bget(Uint32 addr);
                     60:     virtual void   board_lput(Uint32 addr, Uint32 val);
                     61:     virtual void   board_wput(Uint32 addr, Uint16 val);
                     62:     virtual void   board_bput(Uint32 addr, Uint8 val);
                     63:     
                     64:     virtual void   reset(void);
                     65:     virtual void   pause(bool pause);
                     66: };
                     67: 
                     68: class NextBusBoard : public NextBusSlot {
                     69: public:
                     70:     NextBusBoard(int slot);
                     71: };
                     72: 
                     73: extern NextBusSlot* nextbus[];
                     74: 
                     75: #endif /* __cplusplus */
                     76: 
                     77: #endif /* __NEXT_BUS_H__ */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.