Tuesday, 07 July 2020
     
 
Main Menu
Home Home
Shop Shop
News News
BASCOM-AVR BASCOM-AVR
BASCOM-8051 BASCOM-8051
Products Products
Application Notes Application Notes
Publications Publications
Links Links
Support Center Support Center
Downloads Downloads
Forum Forum
Resellers Resellers
Contact Us Contact Us
Updates Updates
MCS Wiki MCS Wiki
Online Help
BASCOM-AVR Help BASCOM-AVR Help
BASCOM-8051 Help BASCOM-8051 Help
Contents in Cart
Show Cart
Your Cart is currently empty.
Search the Shop

Products Search

User Login
Username

Password

If you have problem after log in with disappeared login data, please press F5 in your browser

RSS News
Check the Shop
  Random 
Random
 

PROTO-1
PROTO-1
EUR 22.99


BASCOM-8051 & Book
BASCOM-8051 & Book
EUR 114.95


 
     
 

 
   
     
 
AVR-DOS Print
AVR-DOS is a FAT16 File system for BASCOM-AVR

AVR-DOS is a FAT16 File system for BASCOM-AVR written by Vögel Franz Josef. MCS Electronics is the authorised reseller for this add-on library.

The library is completely written in AVR-assembler.
The AVR-DOS File system is completely integrated into the compiler

The syntax is completely the same as from QB/VB.
A small example:

Print #1 , "Init File System ... ";

Dim Gbtemp1 As Byte ' scratch byte
Gbtemp1
= Initfilesystem(1) ' we must init the filesystem once
If Gbtemp1 > 0 Then
 
Print #1 , "Error " ; Gbtemp1
Else
 
Print #1 , " OK"
 
Print "Disksize : " ; Disksize() ' show disk size in bytes
 
Print "Disk free: " ; Diskfree() ' show free space too
End If


'dim some test variables
Dim S As String * 60 , Fl As String * 12 , Ff As Byte
Dim Sdatetime As String * 18
Fl
= "test.txt"
S
= "test this"

'Now we are getting to it
'We can specify a file handle with #1 or #2 etc. or we can ask for a free
' file handle with the FreeFile function. It will return a free handle if there is one.

Ff
= Freefile() ' get a file handle

'With this file handle we refer to a file
Open Fl For Output As #ff ' open fikle for output
' we need to open a file before we can use the file commands
' we open it for OUTPUT, INPUT , APPEND or BINARY
' In this case we open it for OUTPUT because we want to write to the file.
' If the file existed, the file would be overwritten.
Print #ff , S ' print some data
Print #ff , S
Print #ff , S
Print #ff , "A constant" ; S
Testsb Ff
Close #ff 

 

It is simple to create data loggers, MP3 players etc.
MCS developed a MIDI player using MMC/SD cards. 

The LBX comes for free with BASCOM-AVR. When you want the ASM source, you can order the  USER library for AVR-DOS. The price is 19.95 euro.

When you want to develop a commercial product with the library(either LBX or LIB), you need to purchase a Commercial license for 99 euro.