⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme.dev

📁 smallbasic for linux
💻 DEV
字号:
-----------------------------------------------------------------------Source code convertion for DOS to Unix and backward-----------------------------------------------------------------------a) Unix users	cd utils	make	make install	rehash 			# for tcsh, ??? bash ???	cd ..	./ForUnixb) Win32 users (you'll find bugs)	cd utils	nmake -f Makefile.nmk	copy d2u.exe c:\windows\command	copy u2d.exe c:\windows\command	copy mksmall.exe c:\windows\command	cd ..-----------------------------------------------------------------------HOWTO: Add a new procedure into BASIC's system library-----------------------------------------------------------------------### Step 1. create the codeblib.c:	...	void new_basic_proc()	{		pcprintf("Hello, world!");	}### Step 2. declare your procedure blib.h:	...	void	new_basic_proc() SEC(BLIB);	...### Step 3: take an ID for your procedurekw.h:	...	enum keyword	{	...	kwNEWBASICPROC,	...### Step 4: update the compilerscan.c:...static struct keyword_s keyword_table[] = {{ "MYPROC", kwNEWBASICPROC },...Step 5:	update the "executor"brun.c:	...	void	brun(char* file)	...	/**	*	DO NOT CREATE FUNCTION-PTR-TABLE	*	function tables does not works with multiseg	*/	...	switch ( code )	{	case	kwNEWBASICPROC:		new_basic_proc();		break;	...### Step 6: test it% cat myproc-test.bas:myproc% make unix% ./sbrun myproc-test.basHello, world!* DONE *%### Step 7: update the "help" of SmallBASIC IDEsbref.txt:...MYPROC	- displays the text "hello, world!"...### Step 8: send your changes to SB HQs :)Send me email at wired_gr@yahoo.com-----------------------------------------------------------------------HOWTO: Port SmallBASIC to any OS-----------------------------------------------------------------------//// English:From version 0.5.6, SB supports OS drivers.                       Generic drivers  OS/device specific drivers[SmallBASIC code] ---> [device.c] ----+--> [dev_palm.c]                                      +--> or [dev_x.c]                                      +--> or [dev_uvga.c]                                      +--> or [dev_uvga.c]+[oss_dsp.c]                                      +--> or [dev_sdl.c]                                      +--> ...[SmallBASIC code] ---> [file.c]The basic OS API described in osd.h (console, graphics & sound)The FILE I/O API described in file.c    This is the file I/O code based on standard C, but can be updated   (with preprocessor's macros) to support OS specific calls.In future will be more APIs for serial, parallel and IRDA I/O//// Greek:

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -