MSX FUSION-C, Talking about bugs, errors, mistakes

Страница 10/12
3 | 4 | 5 | 6 | 7 | 8 | 9 | | 11 | 12

By sergarbes

Supporter (14)

Аватар пользователя sergarbes

21-06-2019, 20:23

Great work Eric!

By zPasi

Champion (471)

Аватар пользователя zPasi

26-06-2019, 11:32

Found a bug.

When compiling the sample rlewbToRam.c:

$ make

?ASlink-Warning-Undefined Global '_RleWBToRam' referenced by module 'rlewbToRam'
make: *** [rlewbToRam.ihx] Error 1
rm rlewbToRam.ihx

Found out the function is RleToRam in the LIB, not RleWBToRam. The same error is with RleWBToVram.

When changed in max_fusion.h like this:

void 				RleToVram(unsigned int *RamAddress, unsigned int VramAddress); // RLE Decompression data to VRAM
void 				RleToRam (unsigned int *RamSource, unsigned int *RamDest); 	// RLE Decompression data to RAM

and accordingly in the sample code, it compiles.

By ericb59

Paladin (863)

Аватар пользователя ericb59

26-06-2019, 19:38

Oh ! Thank you for pointing this. I will recompile the library.

To bypass this error and fix it, you can add this at the begining of your program, or inside the msx_fusion.h :

#define RleWBToRam RleToRam
#define RleWBToVram RleToVram

By sergarbes

Supporter (14)

Аватар пользователя sergarbes

04-07-2019, 17:46

Hi ericb59,

I have recently bough the book from Amazon and followed all the steps of the book with an HB-F700P on a macOS Mojave.

Everything compiles correctly. But when executing test.com it prints oooooooo with the same length of the text you want to print.

I have tried another funtion of the msx_fusion.h library, PrintNumber and the same thing is happening.

I have also tried with stdio.h and printf and printed correctly.

What am I doing wrong with the msx_fusion.h library?

st1ckman67, fregarni and I are having the same issue.

This is the code:

//
// Fusion-C
// My First Program in C
//
//#include 
#include "fusion-c/header/msx_fusion.h"

void main(void) 
{
  //printf("Hello world!");
  Print("Hello world!");

And this is a screeshot of the result:

MSX screenshot

Thanks for your help and happy msx coding!

Sergio

By ducasp

Master (151)

Аватар пользователя ducasp

04-07-2019, 20:29

Have you done the step to remove print and the other functions from the sdcc libraries so the ones in fusion-c are used?

By sergarbes

Supporter (14)

Аватар пользователя sergarbes

04-07-2019, 23:23

ducasp wrote:

Have you done the step to remove print and the other functions from the sdcc libraries so the ones in fusion-c are used?

Yes, I did this:

545 sudo cp -r * /usr/local/
546 cd /usr/local/share/sdcc/lib/z80/
547 ls -l
548 cp z80.lib z80.save
549 sudo cp z80.lib z80.lib.save
550 sudo sdar -d z80.lib printf.rel
551 sudo sdar -d z80.lib sprintf.rel
552 sudo sdar -d z80.lib vprintf.rel
553 sudo sdar -d z80.lib putchar.rel
554 sudo sdar -d z80.lib getchar.rel

By ericb59

Paladin (863)

Аватар пользователя ericb59

05-07-2019, 13:38

Hello,
You did well.

It seems I've introduced a bug in FUSION-C 1.1, inside the Print command.

Normally I've already patched the library since June 17. But if you downloaded Fusion-C 1.1 before this date, you have a bug inside the print version.

You can download again the full library and copy/paste the new " Workng Dir / fusion-c / " over your old installation.

Or you can just download the ptached library file : fusion.lib from here :
https://drive.google.com/open?id=1Vh25wpKj_2ly-S71Q1HzlF4QyE...

and copy the file to your Working Folder "/fusion-c /lib/" to replace the old one.

Very Sorry for that Bug !!

By sergarbes

Supporter (14)

Аватар пользователя sergarbes

05-07-2019, 23:27

ericb59 wrote:

Hello,
You did well.

It seems I've introduced a bug in FUSION-C 1.1, inside the Print command.

Normally I've already patched the library since June 17. But if you downloaded Fusion-C 1.1 before this date, you have a bug inside the print version.

You can download again the full library and copy/paste the new " Workng Dir / fusion-c / " over your old installation.

Or you can just download the ptached library file : fusion.lib from here :
https://drive.google.com/open?id=1Vh25wpKj_2ly-S71Q1HzlF4QyE...

and copy the file to your Working Folder "/fusion-c /lib/" to replace the old one.

Very Sorry for that Bug !!

Thank you Eric!

I have done what you told me and it is working now ;-)

Screenshot

By ericb59

Paladin (863)

Аватар пользователя ericb59

06-07-2019, 10:42

Nice Wink

Do not hesitate to request help if you need it.

By sinus

Expert (79)

Аватар пользователя sinus

09-08-2019, 16:29

Hi there,
I'm using graphic instructions in screen 7, drawing a line, say, from (0,0) to (511,211)

screen(7);
Line(0,0,511,211, 4,0);

it seems it only goes half screen, like (255,211)... same result as:

Line(0,0,255,211, 4,0);

Am I doing something wrong? Or is it that screen 7 graphic libs are not fully developped? Is it that only MSX2's low res sc5 and sc8 are supported yet for these functions?

If anyone knows more, please...

(btw: billions of thanx for Fusion-C, great job!)

Страница 10/12
3 | 4 | 5 | 6 | 7 | 8 | 9 | | 11 | 12