[OpenBIOS] PATCH: Implement Forth source debugger for OpenBIOS

Laurent Vivier Laurent at Vivier.EU
Wed Nov 4 17:43:33 CET 2009


>Laurent Vivier wrote:
>
>(lots cut)
>
>> 4- forth/admin/iocontrol.fs:install-console
>> 
>>     ...
>>     ['] io-emit to emit
>>     ...
>> 
>> where io-emit is:
>> 
>> : io-emit ( char -- )
>>   io-out-char c!
>>   io-out-char 1 " write" stdout @ $call-method drop
>> ;
>> 
>> And stdout is defined in arch/ppc/qemu/init.c:arch_of_init() (see 2- )
>
>Thank you - now I see that the defer word "emit" is not set to execute 
>the C function emit, which is what was confusing me.

In fact the C function "emit()" is linked to the forth function "(emit)" which is set to the defer forth word "emit", and the forth word "emit" is redefined later to use the good package method.

Regards,
Laurent
-- 
--------------------- Laurent at vivier.eu  ---------------------
"Tout ce qui est impossible reste à accomplir"    Jules Verne
"Things are only impossible until they're not" Jean-Luc Picard



More information about the OpenBIOS mailing list