Ah, non, c'est la faute à mon bench... Toutes les routines marchent parfaitement, mais j'avais fait une énormité...
Voici le bench (ma version, car je n'avais pas eu le source complet...), qui marche aussi on-calc. Je n'ai pas implémenté le nombre de caractères par seconde...
J'ai modifié quelques trucs (static inline pour les prototypes, et l'utilisation d'un for traduit en dbf; ça réduit le temps passé à faire autre chose que l'affichage de caractères).
// C Source File
// Created 21/08/2002; 11:04:16
#define USE_TI89 // Compile for TI-89
#define USE_TI92PLUS // Compile for TI-92 Plus
#define USE_V200 // Compile for V200
#define OPTIMIZE_ROM_CALLS // Use ROM Call Optimization
#define NO_EXIT_SUPPORT
#define SAVE_SCREEN // Save/Restore LCD Contents
#include <tigcclib.h> // Include All Header Files
#define USE_F_6x8
#include "faststr.h"
#include "Quickfont.h"
#include "TinyX.h"
#undef FiftyMsecTick
INT_HANDLER OldInt5 = NULL;
volatile unsigned long FiftyMsecTick = 0;
DEFINE_INT_HANDLER(MyInt5)
{
FiftyMsecTick++;
ExecuteHandler (OldInt5);
}
static inline void LaunchXFont(void)
{
tX_DrawFastStr_Middle(0,60,"Hello world !",LCD_MEM);
tX_DrawFastStr_Middle(2,60,"Hello world !",LCD_MEM);
tX_DrawFastStr_Middle(4,60,"Hello world !",LCD_MEM);
}
static inline void LaunchQFont(void)
{
DrawStr1_OR("Hello world !",0,70,LCD_MEM);
DrawStr1_OR("Hello world !",2,70,LCD_MEM);
DrawStr1_OR("Hello world !",4,70,LCD_MEM);
}
static inline void LaunchTFont(void)
{
FS_DrawNormalString(0,80,"Hello world !",LCD_MEM);
FS_DrawNormalString(2,80,"Hello world !",LCD_MEM);
FS_DrawNormalString(4,80,"Hello world !",LCD_MEM);
}
#define Iterations 10000
// Main Function
void _main(void)
{
unsigned short i=0;
unsigned long t1,t2,t3;
MakeFont(Font_6x8);
tX_LoadFont_Middle();
// tX_SetFont(F_6x8);
SetupCharSet();
OldInt5 = GetIntVec (AUTO_INT_5);
SetIntVec (AUTO_INT_5, MyInt5);
ClrScr();
OSFreeTimer(USER_TIMER);
OSRegisterTimer(USER_TIMER,200000);
for(i= Iterations + 1; (i--) ; ) LaunchXFont();
t1 = OSTimerCurVal(USER_TIMER);
OSFreeTimer(USER_TIMER);
OSRegisterTimer(USER_TIMER,200000);
for(i= Iterations + 1; (i--) ; ) LaunchQFont();
t2 = OSTimerCurVal(USER_TIMER);
OSFreeTimer(USER_TIMER);
OSRegisterTimer(USER_TIMER,200000);
for(i= Iterations + 1; (i--) ; ) LaunchTFont();
t3 = OSTimerCurVal(USER_TIMER);
printf_xy(0,0,"%lu",t1);
printf_xy(0,10,"%lu",t2);
printf_xy(0,20,"%lu",t3);
FreeFont();
tX_FreeFont();
OSFreeTimer(USER_TIMER);
GKeyIn(NULL,0);
SetIntVec (AUTO_INT_5, OldInt5);
GKeyFlush();
}
EDIT: rah, évidemment, le ; ) a été transformé en smiley...
