Assembla home | Assembla project page
 

Changeset 77

Show
Ignore:
Timestamp:
04/03/07 17:23:02 (2 years ago)
Author:
vitalyb
Message:

* parameter api: support more cameras

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/platform/a610/sub/100f/lib.c

    r28 r77  
    2525    return (void*)0x10670d50; 
    2626} 
     27 
     28void *get_parameter_data_magic_pointer() 
     29{ 
     30    return (void*)0x785C0; 
     31} 
     32 
  • trunk/platform/a620/main.c

    r75 r77  
    2626extern long IsStrobeChargeCompleted(); 
    2727 
     28extern long GetParameterData(long id, long unk, void *buf, long size); 
     29extern long SetParameterData(long id, long unk, void *buf, long size); 
     30 
    2831/* Ours stuff */ 
    2932extern long wrs_kernel_bss_start; 
     
    3134 
    3235extern void boot(); 
    33  
     36extern void *get_parameter_data_magic_pointer(); 
    3437 
    3538/* 
     
    630633    RefreshPhysicalScreen(1); 
    631634} 
     635 
     636 
     637long get_parameter_data(long id, void *buf, long bufsize) 
     638{ 
     639    long *magic = get_parameter_data_magic_pointer(); 
     640    return GetParameterData(id, magic[1], buf, bufsize); 
     641} 
     642 
     643long set_parameter_data(long id, void *buf, long bufsize) 
     644{ 
     645    long *magic = get_parameter_data_magic_pointer(); 
     646    return SetParameterData(id, magic[1], buf, bufsize); 
     647} 
     648 
  • trunk/platform/a620/sub/100f/lib.c

    r28 r77  
    2525    return (void*)0x1066fc70; 
    2626} 
     27 
     28void *get_parameter_data_magic_pointer() 
     29{ 
     30    return (void*)0x77220; 
     31} 
     32 
  • trunk/platform/a620/sub/100f/stubs_entry.S

    r33 r77  
    1919NSTUB(Fseek_Fut, 0xffc5664c) 
    2020NSTUB(Fwrite_Fut, 0xffc565b4) 
     21NSTUB(GetParameterData, 0xffd50890) 
    2122NSTUB(GetPropertyCase, 0xffc14188) 
    2223NSTUB(GetSystemTime, 0xffc04b10) 
     
    4647NSTUB(Read, 0xffc5cf20) 
    4748NSTUB(RefreshPhysicalScreen, 0xffd60708) 
     49NSTUB(SetParameterData, 0xffd50790) 
    4850NSTUB(SetPropertyCase, 0xffc1406c) 
    4951NSTUB(SleepTask, 0xffc11144) 
  • trunk/platform/a630/main.c

    r75 r77  
    2626extern long IsStrobeChargeCompleted(); 
    2727 
     28extern long GetParameterData(long id, long unk, void *buf, long size); 
     29extern long SetParameterData(long id, long unk, void *buf, long size); 
     30 
    2831/* Ours stuff */ 
    2932extern long wrs_kernel_bss_start; 
     
    3134 
    3235extern void boot(); 
    33  
     36extern void *get_parameter_data_magic_pointer(); 
    3437 
    3538/* 
     
    630633    RefreshPhysicalScreen(1); 
    631634} 
     635 
     636 
     637long get_parameter_data(long id, void *buf, long bufsize) 
     638{ 
     639    long *magic = get_parameter_data_magic_pointer(); 
     640    return GetParameterData(id, magic[1], buf, bufsize); 
     641} 
     642 
     643long set_parameter_data(long id, void *buf, long bufsize) 
     644{ 
     645    long *magic = get_parameter_data_magic_pointer(); 
     646    return SetParameterData(id, magic[1], buf, bufsize); 
     647} 
     648 
  • trunk/platform/a630/sub/100c/lib.c

    r34 r77  
    2525    return (void*)0; 
    2626} 
     27 
     28void *get_parameter_data_magic_pointer() 
     29{ 
     30    return (void*)0x6B6E8; 
     31} 
     32 
  • trunk/platform/a630/sub/100c/stubs_entry.S

    r34 r77  
    2323NSTUB(Fseek_Fut, 0xffc5a6a4) 
    2424NSTUB(Fwrite_Fut, 0xffc5a60c) 
     25NSTUB(GetParameterData, 0xffd6edc8) 
    2526NSTUB(GetPropertyCase, 0xffc14de4) 
    2627NSTUB(GetSystemTime, 0xffc04d38) 
     
    5253NSTUB(Read, 0xffc6157c) 
    5354NSTUB(RefreshPhysicalScreen, 0xffd7f49c) 
     55NSTUB(SetParameterData, 0xffd6ecd4) 
    5456NSTUB(SetPropertyCase, 0xffc14c94) 
    5557NSTUB(SleepTask, 0xffc119d0) 
  • trunk/platform/a640/main.c

    r75 r77  
    2626extern long IsStrobeChargeCompleted(); 
    2727 
     28extern long GetParameterData(long id, long unk, void *buf, long size); 
     29extern long SetParameterData(long id, long unk, void *buf, long size); 
     30 
    2831/* Ours stuff */ 
    2932extern long wrs_kernel_bss_start; 
     
    3134 
    3235extern void boot(); 
    33  
     36extern void *get_parameter_data_magic_pointer(); 
    3437 
    3538/* 
     
    630633    RefreshPhysicalScreen(1); 
    631634} 
     635 
     636 
     637long get_parameter_data(long id, void *buf, long bufsize) 
     638{ 
     639    long *magic = get_parameter_data_magic_pointer(); 
     640    return GetParameterData(id, magic[1], buf, bufsize); 
     641} 
     642 
     643long set_parameter_data(long id, void *buf, long bufsize) 
     644{ 
     645    long *magic = get_parameter_data_magic_pointer(); 
     646    return SetParameterData(id, magic[1], buf, bufsize); 
     647} 
     648 
  • trunk/platform/a640/sub/100b/lib.c

    r64 r77  
    2525    return (void*)0; 
    2626} 
     27 
     28void *get_parameter_data_magic_pointer() 
     29{ 
     30    return (void*)0x6B9E0; 
     31} 
     32 
  • trunk/platform/a640/sub/100b/stubs_entry.S

    r64 r77  
    2626// Best match: 61% 
    2727NSTUB(Fwrite_Fut, 0xffc5b6f4) 
     28NSTUB(GetParameterData, 0xffd71a6c) 
    2829// Best match: 89% 
    2930NSTUB(GetPropertyCase, 0xffc15484) 
     
    5657NSTUB(Read, 0xffc6263c) 
    5758NSTUB(RefreshPhysicalScreen, 0xffd822a0) 
     59NSTUB(SetParameterData, 0xffd71978) 
    5860NSTUB(SetPropertyCase, 0xffc15334) 
    5961NSTUB(SleepTask, 0xffc12068) 
  • trunk/platform/a710/main.c

    r75 r77  
    2626extern long IsStrobeChargeCompleted(); 
    2727 
     28extern long GetParameterData(long id, long unk, void *buf, long size); 
     29extern long SetParameterData(long id, long unk, void *buf, long size); 
     30 
    2831/* Ours stuff */ 
    2932extern long wrs_kernel_bss_start; 
     
    3134 
    3235extern void boot(); 
    33  
     36extern void *get_parameter_data_magic_pointer(); 
    3437 
    3538/* 
     
    630633    RefreshPhysicalScreen(1); 
    631634} 
     635 
     636 
     637long get_parameter_data(long id, void *buf, long bufsize) 
     638{ 
     639    long *magic = get_parameter_data_magic_pointer(); 
     640    return GetParameterData(id, magic[1], buf, bufsize); 
     641} 
     642 
     643long set_parameter_data(long id, void *buf, long bufsize) 
     644{ 
     645    long *magic = get_parameter_data_magic_pointer(); 
     646    return SetParameterData(id, magic[1], buf, bufsize); 
     647} 
     648 
  • trunk/platform/a710/sub/100a/lib.c

    r28 r77  
    2525    return (void*)0x10670ee0; 
    2626} 
     27 
     28void *get_parameter_data_magic_pointer() 
     29{ 
     30    return (void*)0x765D8; 
     31} 
     32 
  • trunk/platform/a710/sub/100a/stubs_entry.S

    r33 r77  
    2222NSTUB(Fseek_Fut, 0xffc5a180) 
    2323NSTUB(Fwrite_Fut, 0xffc5a0e8) 
     24NSTUB(GetParameterData, 0xffd7734c) 
    2425NSTUB(GetPropertyCase, 0xffc14dec) 
    2526NSTUB(GetSystemTime, 0xffc04d38) 
     
    5152NSTUB(Read, 0xffc61058) 
    5253NSTUB(RefreshPhysicalScreen, 0xffd8752c) 
     54NSTUB(SetParameterData, 0xffd77280) 
    5355NSTUB(SetPropertyCase, 0xffc14c9c) 
    5456NSTUB(SleepTask, 0xffc119d0) 
  • trunk/tools/gensigs.sh

    r33 r77  
    11#!/bin/sh 
    22 
    3 VERSIONS="1 2
     3VERSIONS="1 2 3
    44 
    55echo 
  • trunk/tools/readme.txt

    r33 r77  
    11sig_ref_1.bin : should contain a610-100e primary 
    22sig_ref_2.bin : should contain a710-100a primary 
     3sig_ref_3.bin : should contain a630-100c primary 
  • trunk/tools/sig_ref_2.txt

    r33 r77  
    44RefreshPhysicalScreen 0xFFD8752C 
    55DisplayImagePhysicalScreen 0xffd36fe0 
     6GetParameterData 0xFFD7734C 
     7SetParameterData 0xFFD77280 
  • trunk/tools/signatures.h

    r76 r77  
    16221622}; 
    16231623 
     1624static FuncSig func_sig_GetParameterData_2[] = { 
     1625        {   0, 0xe1a00800, 0xfdffffff }, 
     1626        {   1, 0xe1a03803, 0xfdffffff }, 
     1627        {   2, 0xe1a00820, 0xfdffffff }, 
     1628        {   4, 0xe1a07002, 0xfdffffff }, 
     1629        {   5, 0xe1a08001, 0xfdffffff }, 
     1630        {   6, 0xe1a04843, 0xfdffffff }, 
     1631        {   7, 0xeb000000, 0xff000000 }, 
     1632        {   8, 0xe1a05000, 0xfdffffff }, 
     1633        {   9, 0xe1d530b4, 0xfdffffff }, 
     1634        {  10, 0xe1c33003, 0xfdffffff }, 
     1635        {  11, 0xe1a03803, 0xfdffffff }, 
     1636        {  13, 0xe1a03823, 0xfdffffff }, 
     1637        {  14, 0xe0833002, 0xfdffffff }, 
     1638        {  15, 0xe1570000, 0xfdffffff }, 
     1639        {  17, 0xe1a01094, 0xfdffffff }, 
     1640        {  18, 0xe0836005, 0xfdffffff }, 
     1641        {  19, 0x1a000000, 0xff000000 }, 
     1642        {  20, 0xeb000000, 0xff000000 }, 
     1643        {  21, 0xe1a03804, 0xfdffffff }, 
     1644        {  22, 0xe1d520b6, 0xfdffffff }, 
     1645        {  23, 0xe1a04823, 0xfdffffff }, 
     1646        {  24, 0xe1540002, 0xfdffffff }, 
     1647        {  26, 0xe1a01095, 0xfdffffff }, 
     1648        {  27, 0x9a000000, 0xff000000 }, 
     1649        {  28, 0xeb000000, 0xff000000 }, 
     1650        {  29, 0xe1a00008, 0xfdffffff }, 
     1651        {  30, 0xe1a01006, 0xfdffffff }, 
     1652        {  31, 0xe1a02004, 0xfdffffff }, 
     1653        { -1, -1, -1 }, 
     1654        /* 28/32 */ 
     1655}; 
     1656 
     1657static FuncSig func_sig_SetParameterData_2[] = { 
     1658        {   0, 0xe1a00800, 0xfdffffff }, 
     1659        {   2, 0xe1a08820, 0xfdffffff }, 
     1660        {   3, 0xe1a03803, 0xfdffffff }, 
     1661        {   4, 0xe1a00008, 0xfdffffff }, 
     1662        {   5, 0xe1a06002, 0xfdffffff }, 
     1663        {   6, 0xe1a0a001, 0xfdffffff }, 
     1664        {   7, 0xe1a04843, 0xfdffffff }, 
     1665        {   9, 0xeb000000, 0xff000000 }, 
     1666        {  10, 0xe1a05000, 0xfdffffff }, 
     1667        {  11, 0xe1d530b4, 0xfdffffff }, 
     1668        {  12, 0xe1c33003, 0xfdffffff }, 
     1669        {  13, 0xe1a03803, 0xfdffffff }, 
     1670        {  15, 0xe1a03823, 0xfdffffff }, 
     1671        {  16, 0xe1560000, 0xfdffffff }, 
     1672        {  18, 0xe1a01072, 0xfdffffff }, 
     1673        {  19, 0xe0837002, 0xfdffffff }, 
     1674        {  20, 0x1a000000, 0xff000000 }, 
     1675        {  21, 0xeb000000, 0xff000000 }, 
     1676        {  22, 0xe1a03804, 0xfdffffff }, 
     1677        {  23, 0xe1d520b6, 0xfdffffff }, 
     1678        {  24, 0xe1a04823, 0xfdffffff }, 
     1679        {  25, 0xe1540002, 0xfdffffff }, 
     1680        {  27, 0xe1a01073, 0xfdffffff }, 
     1681        {  28, 0x9a000000, 0xff000000 }, 
     1682        {  29, 0xeb000000, 0xff000000 }, 
     1683        {  30, 0xe1a01006, 0xfdffffff }, 
     1684        {  31, 0xe1a02004, 0xfdffffff }, 
     1685        { -1, -1, -1 }, 
     1686        /* 27/32 */ 
     1687}; 
     1688 
     1689static FuncSig func_sig_GetParameterData_3[] = { 
     1690        {   0, 0xe1a00800, 0xfdffffff }, 
     1691        {   1, 0xe1a00820, 0xfdffffff }, 
     1692        {   3, 0xe1a04803, 0xfdffffff }, 
     1693        {   4, 0xe1a09002, 0xfdffffff }, 
     1694        {   5, 0xe1a0a001, 0xfdffffff }, 
     1695        {   6, 0xeb000000, 0xff000000 }, 
     1696        {   7, 0xe1a05000, 0xfdffffff }, 
     1697        {   8, 0xe1d530b4, 0xfdffffff }, 
     1698        {   9, 0xe1c33003, 0xfdffffff }, 
     1699        {  10, 0xe1a03803, 0xfdffffff }, 
     1700        {  12, 0xe1a04844, 0xfdffffff }, 
     1701        {  13, 0xe1a03823, 0xfdffffff }, 
     1702        {  14, 0xe1a08804, 0xfdffffff }, 
     1703        {  15, 0xe0837002, 0xfdffffff }, 
     1704        {  16, 0xe1590000, 0xfdffffff }, 
     1705        {  17, 0xe1a06828, 0xfdffffff }, 
     1706        {  19, 0xe1a01094, 0xfdffffff }, 
     1707        {  20, 0xe0874005, 0xfdffffff }, 
     1708        {  21, 0x1a000000, 0xff000000 }, 
     1709        {  22, 0xeb000000, 0xff000000 }, 
     1710        {  23, 0xe1d530b6, 0xfdffffff }, 
     1711        {  24, 0xe1560003, 0xfdffffff }, 
     1712        {  26, 0xe1a01095, 0xfdffffff }, 
     1713        {  27, 0x9a000000, 0xff000000 }, 
     1714        {  28, 0xeb000000, 0xff000000 }, 
     1715        {  29, 0xe1d5c0ba, 0xfdffffff }, 
     1716        {  30, 0xe1a03cff, 0xfdffffff }, 
     1717        {  31, 0xe08330ff, 0xfdffffff }, 
     1718        { -1, -1, -1 }, 
     1719        /* 28/32 */ 
     1720}; 
     1721 
     1722static FuncSig func_sig_SetParameterData_3[] = { 
     1723        {   1, 0xe1a08800, 0xfdffffff }, 
     1724        {   2, 0xe1a03803, 0xfdffffff }, 
     1725        {   3, 0xe1a00828, 0xfdffffff }, 
     1726        {   4, 0xe1a06002, 0xfdffffff }, 
     1727        {   5, 0xe1a0a001, 0xfdffffff }, 
     1728        {   6, 0xe1a04843, 0xfdffffff }, 
     1729        {   8, 0xeb000000, 0xff000000 }, 
     1730        {   9, 0xe1a05000, 0xfdffffff }, 
     1731        {  10, 0xe1d530b4, 0xfdffffff }, 
     1732        {  11, 0xe1c33003, 0xfdffffff }, 
     1733        {  12, 0xe1a03803, 0xfdffffff }, 
     1734        {  14, 0xe1a03823, 0xfdffffff }, 
     1735        {  15, 0xe1560000, 0xfdffffff }, 
     1736        {  17, 0xe1a01072, 0xfdffffff }, 
     1737        {  18, 0xe0837002, 0xfdffffff }, 
     1738        {  19, 0x1a000000, 0xff000000 }, 
     1739        {  20, 0xeb000000, 0xff000000 }, 
     1740        {  21, 0xe1a03804, 0xfdffffff }, 
     1741        {  22, 0xe1d520b6, 0xfdffffff }, 
     1742        {  23, 0xe1a04823, 0xfdffffff }, 
     1743        {  24, 0xe1540002, 0xfdffffff }, 
     1744        {  26, 0xe1a01073, 0xfdffffff }, 
     1745        {  27, 0x9a000000, 0xff000000 }, 
     1746        {  28, 0xeb000000, 0xff000000 }, 
     1747        {  29, 0xe1a01006, 0xfdffffff }, 
     1748        {  30, 0xe1a02004, 0xfdffffff }, 
     1749        {  31, 0xe0870005, 0xfdffffff }, 
     1750        { -1, -1, -1 }, 
     1751        /* 27/32 */ 
     1752}; 
     1753 
    16241754FuncsList func_list[] = { 
    16251755        { "AllocateMemory", func_sig_AllocateMemory_1 }, 
     
    16421772        { "Fwrite_Fut", func_sig_Fwrite_Fut_1 }, 
    16431773        { "GetParameterData", func_sig_GetParameterData_1 }, 
     1774        { "GetParameterData", func_sig_GetParameterData_2 }, 
     1775        { "GetParameterData", func_sig_GetParameterData_3 }, 
    16441776        { "GetPropertyCase", func_sig_GetPropertyCase_1 }, 
    16451777        { "GetPropertyCase", func_sig_GetPropertyCase_2 }, 
     
    16711803        { "RefreshPhysicalScreen", func_sig_RefreshPhysicalScreen_2 }, 
    16721804        { "SetParameterData", func_sig_SetParameterData_1 }, 
     1805        { "SetParameterData", func_sig_SetParameterData_2 }, 
     1806        { "SetParameterData", func_sig_SetParameterData_3 }, 
    16731807        { "SetPropertyCase", func_sig_SetPropertyCase_1 }, 
    16741808        { "SetPropertyCase", func_sig_SetPropertyCase_2 },