Documentation update

Post Reply
User avatar
Dutchman
Posts: 151
Joined: Tue Aug 06, 2019 4:47 pm
Location: Netherlands

Documentation update

Post by Dutchman » Tue Nov 19, 2019 10:26 pm

I have now split the documentation into two files:
"About BestBASIC Extensions.pdf" contains the introduction and global description of the published extensions.
"BB's Extensions Reference manual.pdf" contains the detailed explanation of the functions.
About BestBASIC Extensions.pdf
(390.96 KiB) Downloaded 23 times
BB's Extensions Reference manual.pdf
(160.71 KiB) Downloaded 24 times
In the '/Extensions/" main folder I have added three files
! Template which contains the proposed structure of library extensions.
# All !&#.bb is a program which generates a list of all include files "! …" such that it can be used to include all
and it generates a list fo all test and demo programs "# …". The output is written to console and to file "! All !&#"

Code: Select all

'"# All !&#.bb"
' make All inclusive library
' and list test and demo programs
' by Ton Nillesen, November 2019
{/Extensions/Files/! Folder utils} ' include
'
'==== User settings
Out$="! All !&#"
Store$=Dir$+Out$
Dir$="/Extensions/"
File$=".temp" ' for function content
Indent$=" … " ' adds to each folder-level, e.g. " … " or "   "
'==== Constants ====
DIM Lead$()=("!","#")
Dim Header$()=("–––––– Libraries –––––––")
Header$+" Test and Demo programs "
Leader$="[–––––––––––––––––"
Trailer$="–––––––––––––––––"

'
'--- check settings
IF NOT DIR EXISTS Dir$ THEN 
  PRINT "Folder """+Dir$+""" not found"
  STOP
ENDIF
'
'--- Preset Output file
IF FILE EXISTS(Store$) THEN FILE DELETE Store$
'--- Write title
Line$="' {"+Store$+"} ' includes all"
GOSUB Write
Line$="[ All libraries included and demo's listed ]"
GOSUB Write
Line$="'"+CR$+Leader$+Header$(0)+Trailer$+"]"
'--- Run for "!" and "#"
n=0
DO
GOSUB Write
 ContentInfo.Lead$=Lead$(n)
 GOSUB GetContent
 n+=1
 Line$="'"+CR$+Leader$+Header$(1)+Trailer$+CR$
REDO IF n<2
Line$="]"
GOSUB Write
END

'============ User defined functions ==========
DEF ContentInfo(Dir$,File$)
'To be adapted by the user
'This function will be called by function 'Content(…)'
'File$ will contain the name of the file which
'just has been written to the tree.
'--- Write files starting with Lead$
OK=(File$<>"! Template") AND (File$<>.Out$)
IF Lead$=STRLEFT File$,1 AND OK
  Line$=Dir$+File$
  IF Lead$="!" THEN Line$="{"+Line$+"}"
  PRINT Line$
  FILEWRITE .Store$ Line$+CR$
ENDIF
END DEF
'
GetContent:
IF FILE EXISTS(File$) THEN FILE DELETE  File$
CALL Content(File$,Dir$,Indent$)
IF FILE EXISTS(File$) THEN FILE DELETE  File$
RETURN
'
Write:
PRINT Line$
FILEWRITE Store$ Line$+CR$
RETURN
! All !&# has now the following content:

Code: Select all

' {! All !&#} ' includes all
[ All libraries included and demo's listed ]
'
[––––––––––––––––––––––– Libraries ––––––––––––––––––––––––]
{/Extensions/Arrays/! Array utils}
{/Extensions/Console/! Con utils}
{/Extensions/Files/! Folder utils}
{/Extensions/Graphics/! Col_ utils}
{/Extensions/Interface/! Buttons}
{/Extensions/Interface/! Int_}
{/Extensions/Math/! DSP utils}
{/Extensions/Math/! Math utils}
{/Extensions/Misc/! Time utils}
{/Extensions/Strings/! String utils}
{/Extensions/System/! Sys utils}
{/Extensions/System/! Sys_Spec}
{/Extensions/System/! Sys_calibrate}
{/Extensions/System/! pt&mm}
'
[––––––––––––––––– Test and Demo programs –––––––––––––––––

/Extensions/# All !&#.bb
/Extensions/Arrays/# Load test.bb
/Extensions/Console/# Error test.bb
/Extensions/Files/# Content test.bb
/Extensions/Graphics/# Col_plot test.bb
/Extensions/Interface/# Int_ Defaults.bb
/Extensions/Math/# DSP_FIRgain test.bb
/Extensions/Math/# Odd Even Crop Integer.bb
/Extensions/Misc/# Time functions.bb
/Extensions/System/# Calibrate zoom.bb
/Extensions/System/# pt&mm test.bb
]
Last edited by Dutchman on Fri Nov 22, 2019 4:07 pm, edited 13 times in total.
It is still a long way to go

User avatar
Dutchman
Posts: 151
Joined: Tue Aug 06, 2019 4:47 pm
Location: Netherlands

Re: Documentation and Reference manual

Post by Dutchman » Wed Nov 20, 2019 7:12 pm

I have updated "About BestBASIC Extensions.pdf" with info on "FIRgain" in chapter 6. Math
It is still a long way to go

Post Reply