~ubuntu-branches/ubuntu/breezy/tiemu/breezy

« back to all changes in this revision

Viewing changes to src/core/ti_sw/romcalls.h

  • Committer: Bazaar Package Importer
  • Author(s): Julien BLACHE
  • Date: 2005-06-02 16:50:15 UTC
  • mfrom: (1.2.1 upstream) (2.1.1 sarge)
  • Revision ID: james.westby@ubuntu.com-20050602165015-59ab24414tl2wzol
Tags: 1.99+svn1460-1
* New snapshot.
* debian/control:
  + Updated build-depends.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Hey EMACS -*- linux-c -*- */
 
2
/* $Id: romcalls.h 1455 2005-05-31 18:38:03Z roms $ */
 
3
 
 
4
/*  TiEmu - an TI emulator
 
5
 *
 
6
 *  Copyright (c) 2000-2001, Thomas Corvazier, Romain Lievin
 
7
 *  Copyright (c) 2001-2003, Romain Lievin
 
8
 *  Copyright (c) 2003, Julien Blache
 
9
 *  Copyright (c) 2004, Romain Li�vin
 
10
 *  Copyright (c) 2005, Romain Li�vin, Kevin Kofler
 
11
 *
 
12
 *  This program is free software; you can redistribute it and/or modify
 
13
 *  it under the terms of the GNU General Public License as published by
 
14
 *  the Free Software Foundation; either version 2 of the License, or
 
15
 *  (at your option) any later version.
 
16
 *
 
17
 *  This program is distributed in the hope that it will be useful,
 
18
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
19
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
20
 *  GNU General Public License for more details.
 
21
 *
 
22
 *  You should have received a copy of the GNU General Public License
 
23
 *  along with this program; if not, write to the Free Software
 
24
 *  Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
 
25
 */
 
26
 
 
27
/*
 
28
  Breakpoint definitions
 
29
*/
 
30
 
 
31
#ifndef __ROMCALLS__
 
32
#define __ROMCALLS__
 
33
 
 
34
#include <stdio.h>
 
35
#include <stdint.h>
 
36
#include <glib.h>
 
37
 
 
38
#define NMAX_ROMCALLS   0x800
 
39
 
 
40
/* Types */
 
41
 
 
42
typedef struct
 
43
{
 
44
        int                     id;
 
45
    uint32_t    addr;
 
46
    char*       name;
 
47
} ROM_CALL;
 
48
 
 
49
/* Functions */
 
50
 
 
51
void romcalls_get_table_infos(uint32_t *base, uint32_t *size);
 
52
void romcalls_get_symbol_address(int id, uint32_t *addr);
 
53
int romcalls_preload(const char* filename);
 
54
int romcalls_is_loaded(void);
 
55
 
 
56
GList* romcalls_sort_by_id(void);
 
57
GList* romcalls_sort_by_addr(void);
 
58
GList* romcalls_sort_by_name(void);
 
59
GList* romcalls_sort_by_iname(void);
 
60
 
 
61
int romcalls_is_addr(uint32_t addr);
 
62
int romcalls_is_name(const char *name);
 
63
 
 
64
const char* romcalls_get_name(int id);
 
65
uint32_t romcalls_get_addr(int id);
 
66
 
 
67
const char* ercodes_get_name(unsigned id);
 
68
 
 
69
#define ROMCALL_ID(elt)         (((ROM_CALL *)(elt->data))->id)
 
70
#define ROMCALL_NAME(elt)       (((ROM_CALL *)(elt->data))->name)
 
71
#define ROMCALL_ADDR(elt)       (((ROM_CALL *)(elt->data))->addr)
 
72
 
 
73
#endif