Results 1 to 35 of 35

Thread: Github For M2000 Interpreter

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Github For M2000 Interpreter

    I have recently update M2000 Interpreter to version 9. Code is open source, written in VB6.
    Also there are some Wiki pages on github about M2000
    https://github.com/M2000Interpreter/...ction-to-M2000

  2. #2

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    I am writing the Wiki. (help because my English are very bad..)
    https://github.com/M2000Interpreter/Version9/wiki

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    A BlackJack for 4 players (we can alter player number for 1 to any number) and a dealer (played by computer).
    With Split and Doubling Down functions


    https://github.com/M2000Interpreter/...-in-M2000-code

    or with colored code

    http://georgekarras.blogspot.gr/2017...2000-code.html

  4. #4

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    An notepad created in M2000 (an Interpreter written in VB6)
    Has a lot of comments and Images.

    http://georgekarras.blogspot.gr/2018...3-version.html

  5. #5

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter


  6. #6

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    265 tasks in rosettacode.org

    100 doors
    2048
    A+B
    ABC Problem
    Abstract type
    Accumulator factory
    Ackermann function
    Add a variable to a class instance at runtime
    Animate a pendulum
    Animation
    Anonymous recursion
    Apply a callback to an array
    Arithmetic evaluation
    Arithmetic-geometric mean
    Arithmetic/Integer
    Arithmetic/Rational
    Array concatenation
    Array length
    Arrays
    Aspect Oriented Programming
    Assertions
    Associative array/Creation
    Associative array/Iteration
    Averages/Mode
    Averages/Pythagorean means
    Babbage problem
    Banker's algorithm
    Binary digits
    Bitmap
    Bitmap/Read a PPM file
    Bitmap/Write a PPM file
    Boolean values
    Box the compass
    Break OO privacy
    Caesar cipher
    Calculating the value of e
    Calendar
    Calendar - for "REAL" programmers
    Call a foreign-language function
    Call a function
    Call an object method
    Case-sensitivity of identifiers
    Catalan numbers/Pascal's triangle
    Catamorphism
    Character codes
    Check that file exists
    Classes
    Closures/Value capture
    Collections
    Color of a screen pixel
    Colour bars/Display
    Combinations
    Combinations and permutations
    Comma quibbling
    Comments
    Compare a list of strings
    Concurrent computing
    Conditional structures
    Count the coins
    CRC-32
    Create a file
    Create a two-dimensional array at runtime
    Create an object at a given address
    Create an object/Native demonstration
    CSV data manipulation
    Currency
    Currying
    Date format
    Day of the week
    Define a primitive data type
    Delegates
    Determine if a string is numeric
    Dot product
    Doubly-linked list/Definition
    Draw a pixel
    Dynamic variable names
    Empty program
    Empty string
    Enumerations
    Environment variables
    Even or odd
    Exceptions
    Extend your language
    Extensible prime generator
    Factorial
    FASTA format
    Fibonacci sequence
    File input/output
    Filter
    Find limit of recursion
    First-class functions
    First-class functions/Use numbers analogously
    FizzBuzz
    Formatted numeric output
    Forward difference
    Function composition
    Function definition
    Function prototype
    Gamma function
    Gaussian elimination
    Generate lower case ASCII alphabet
    Generator/Exponential
    Generic swap
    Get system command output
    Gray code
    Greatest common divisor
    Greatest element of a list
    Guess the number
    GUI component interaction
    GUI enabling/disabling of controls
    GUI/Maximum window dimensions
    Hailstone sequence
    Happy numbers
    Hash from two arrays
    Hash join
    Hello world/Graphical
    Hello world/Line printer
    Hello world/Newbie
    Hello world/Text
    Here document
    Higher-order functions
    History variables
    Hostname
    HTTP
    Huffman coding
    Hunt The Wumpus
    IBAN
    Include a file
    Increment a numerical string
    Inheritance/Multiple
    Inheritance/Single
    Input loop
    Integer overflow
    Interactive programming
    Inverted syntax
    Jensen's Device
    JSON
    Jump anywhere
    Keyboard input/Flush the keyboard buffer
    Keyboard input/Obtain a Y or N response
    Keyboard macros
    Knapsack problem/Continuous
    Knuth shuffle
    Literals/Floating point
    Literals/Integer
    Literals/String
    Logical operations
    Loops/Break
    Loops/Continue
    Loops/Do-while
    Loops/Downward for
    Loops/For
    Loops/For with a specified step
    Loops/Foreach
    Loops/Increment loop index within loop body
    Loops/Infinite
    Loops/N plus one half
    Loops/Nested
    Loops/While
    LZW compression
    M2000 Interpreter Json Class
    M2000 Interpreter rational numbers
    Machine code
    Magic 8-Ball
    Mandelbrot set
    Memory allocation
    Metaprogramming
    Monty Hall problem
    Move-to-front algorithm
    Multiple distinct objects
    Multiplication tables
    Multisplit
    Munchausen numbers
    Musical scale
    Mutex
    Mutual recursion
    N-queens problem
    Named parameters
    Naming conventions
    Nested function
    Nonoblock
    Nth root
    Null object
    Number reversal game
    Odd word problem
    OLE Automation
    Perfect numbers
    Permutation test
    Permutations
    Permutations with repetitions
    Pi
    Pig the dice game
    Pig the dice game/Player
    Playing cards
    Pointers and references
    Polymorphism
    Primality by trial division
    Prime decomposition
    Priority queue
    Quaternion type
    Queue/Definition
    Random numbers
    Read a file character by character/UTF8
    Read a file line by line
    Read entire file
    Real constants and functions
    Reduced row echelon form
    Regular expressions
    Rename a file
    Reverse a string
    Rosetta Code/Rank languages by popularity
    Runtime evaluation
    Scope modifiers
    Search a list
    Secure temporary file
    Sieve of Eratosthenes
    Simple windowed application
    Sleep
    Smith numbers
    Solve the no connection puzzle
    Sort a list of object identifiers
    Sort an array of composite structures
    Sort numbers lexicographically
    Sort stability
    Sort three variables
    Sort using a custom comparator
    Sorting algorithms/Bubble sort
    Sorting algorithms/Quicksort
    Sorting algorithms/Shell sort
    Speech synthesis
    Spinning rod animation/Text
    Split a character string based on change of character
    Stack
    String append
    String concatenation
    String interpolation (included)
    String length
    String matching
    String prepend
    Substring
    Sum of squares
    System time
    Table creation
    Terminal control/Preserve screen
    Terminal control/Ringing the terminal bell
    Terminal control/Unicode output
    Text processing/Max licenses in use
    The Name Game
    Tic-tac-toe
    Time a function
    Top rank per group
    Towers of Hanoi
    Trabb Pardo–Knuth algorithm
    User input/Graphical
    User input/Text
    Using a Speech engine to highlight words
    UTF-8 encode and decode
    Variables
    Variadic function
    Vector products
    Walk a directory/Non-recursively
    Window creation
    Word wrap
    Y combinator
    Zero to the zero power
     

  7. #7

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    The M2000 Interpreter and Environment has finished as a VB 6 open source project.
    Here is a paper for the language M2000.
    https://github.com/M2000Interpreter/...M2000paper.pdf
    Aim of M2000 is the educational branch, as a tool for pupils and for teacher to make some applications to support their course.

  8. #8
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    The M2000 Interpreter and Environment has finished as a VB 6 open source project.
    Here is a paper for the language M2000.
    https://github.com/M2000Interpreter/...M2000paper.pdf
    Aim of M2000 is the educational branch, as a tool for pupils and for teacher to make some applications to support their course.
    vb6 projects belong in the Visual Basic 6 and Earlier Forum.

    EDIT:
    After looking at the code samples at Rosetta and in the manual I tried to create and load file but there appears to be no obvious way to load code saved in a file. Can your program load code from external files? And if so, how?
    Last edited by Peter Swinkels; Jul 5th, 2020 at 06:37 AM.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  9. #9
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,045

    Re: Github For M2000 Interpreter

    Peter, the reason the thread is here is because the "M2000 Interpreter" is an "other BASIC" language, which just happens to be written in VB6.
    "Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930

  10. #10
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,045

    Re: Github For M2000 Interpreter

    Quote Originally Posted by Peter Swinkels View Post
    ... I tried to create and load file but there appears to be no obvious way to load code saved in a file. Can your program load code from external files? And if so, how?
    I think that may be answered on page 124 of the manual. https://github.com/M2000Interpreter/...M2000paper.pdf
    "Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930

  11. #11
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by passel View Post
    I think that may be answered on page 124 of the manual. https://github.com/M2000Interpreter/...M2000paper.pdf
    Okay, will look into it.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  12. #12
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by passel View Post
    I think that may be answered on page 124 of the manual. https://github.com/M2000Interpreter/...M2000paper.pdf
    Alright, when I enter "Load "Stack.gsb" or another *.gsb file the environment crashes. I am getting no errors other than just being thrown straight back into Windows.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  13. #13
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,045

    Re: Github For M2000 Interpreter

    Well, I've never looked into it myself.

    But since is it open source, you could try running the program in the IDE and see where it is crashing.
    Or, if you really don't have the time and/or interest, I guess wait to see if George will respond. Since he was on earlier today with the update to this thread, perhaps he'll be back soon.

    I've see the topic various times over the last several years, but haven't tried any version of it myself. From what I've seen of it on the forum, I'm not sure that I agree with the proposition that this interpreter is better suited for teaching students a programming language compared to VB6.
    "... Then he found that Visual Basic is a fantastic environment but not for pupils."
    The M2000 interpreter, just from what I've see of it, didn't seem to be easier to comprehend compared to VB6, or other BASICs.
    And if you have problems getting it to run, then that doesn't bode well either.

    But, since I haven't actually tried it, my minimal observations shouldn't be given much merit.
    "Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930

  14. #14
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by passel View Post
    Well, I've never looked into it myself.

    But since is it open source, you could try running the program in the IDE and see where it is crashing.
    Or, if you really don't have the time and/or interest, I guess wait to see if George will respond. Since he was on earlier today with the update to this thread, perhaps he'll be back soon.

    I've see the topic various times over the last several years, but haven't tried any version of it myself. From what I've seen of it on the forum, I'm not sure that I agree with the proposition that this interpreter is better suited for teaching students a programming language compared to VB6.

    The M2000 interpreter, just from what I've see of it, didn't seem to be easier to comprehend compared to VB6, or other BASICs.
    And if you have problems getting it to run, then that doesn't bode well either.

    But, since I haven't actually tried it, my minimal observations shouldn't be given much merit.
    In the ide it appears to compile and run but the interface doesn’t appear. It does appear when I run it compiled as an exe.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  15. #15
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,045

    Re: Github For M2000 Interpreter

    I guess what you do now depends on how interested you are in exploring someone's project.
    You can hit the || pause button, then click on the debug "step over" button to see where in the code you are, or what the next periodic event that occurs.
    You can step through the code to see if you understand what it is doing at that point, and why it might not be showing the M2000 console.
    I presume the M2000 console is just a VB6 Form, but have no idea.

    Sometimes, if a program is truly new to me, I may just hit the "Step Into" button at the start, rather than the "Run" button, or F5 key so that I can see what the program is doing from the very start.

    Perhaps there is some error that is hidden by an OnError statement, so you are just stuck in a loop, repeating the error without handling it, so there is no indication of a fault and you can't progress.
    "Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930

  16. #16
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by passel View Post
    I guess what you do now depends on how interested you are in exploring someone's project.
    You can hit the || pause button, then click on the debug "step over" button to see where in the code you are, or what the next periodic event that occurs.
    You can step through the code to see if you understand what it is doing at that point, and why it might not be showing the M2000 console.
    I presume the M2000 console is just a VB6 Form, but have no idea.

    Sometimes, if a program is truly new to me, I may just hit the "Step Into" button at the start, rather than the "Run" button, or F5 key so that I can see what the program is doing from the very start.

    Perhaps there is some error that is hidden by an OnError statement, so you are just stuck in a loop, repeating the error without handling it, so there is no indication of a fault and you can't progress.
    1. Well, I am interested in taking a look; I will see where it goes from there.
    2. Does not appear to be working, no code is highlighted when I pause the program.
    3. Stepping doesn't appear to be enabled for this particular project.
    4. I can't prove or disprove your presumption, there are several forms but none look like the interface displayed while the compiled program was running.
    5. Clicking "Step into" or pressing "F5" don't work. The program appears to compile and run; but visible is happening.
    6. Disabling 897 error traps worked. Now we're getting somewhere. It now says "Sub or function not defined.". Presumably an external component.

    Thank you for replying. I will get back to this thread when I have found out more.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  17. #17
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Some investigation told me the following:
    1. There is a project group file called "testme.vbg" which can't be loaded from Explorer because Microsoft Visual Basic 6.0 Enterprise will not load it properly. It gets mistaken for a module.
    2. When I load the "testme.vbg" file via the "Open Project" menu option Visual Basic throws an error about an invalid key called "StartUpProject", after that an error claiming "VBGROUP 5.0" appears.
    3. While I appear unable to reproduce the situation, a dialog stating the project ("m2000.vbg") was made in an earlier version of Visual Basic appeared once or twice.

    EDIT:
    4. There are several batch files referring to Micosoft Macro Assembler, as near as I can tell the executable needs to be modified after having been compiled with Visual Basic.

    EDIT 2:
    5. I now noticed the manual has been downloaded as well. Going to have a closer look.

    EDIT 3:
    6. The manual explains how to use the software, not how to properly compile it or how to set it up...

    EDIT 4:
    7. There is a readme file with links to a few binaries, some code and the manual. The other text files are a log (only reads: "Line 17: Cannot load control gList2."), the other mentions a *.cab file which I don't appear to have has been built. The other file appears to be a numbered list in both greek and english. BTW: The readme mentions a certificate (ca.crt) that I could install... BTW 2: These binaries turned out to be an M2000 installer and a copy of ca.crt.
    Last edited by Peter Swinkels; Jul 6th, 2020 at 01:20 PM.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  18. #18
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    It looks like I have made a breakthrough:

    I can now load and execute programs:
    https://drive.google.com/file/d/1cZ0...ew?usp=sharing

    The above url links to an animated gif of a few seconds.

    And thank you for setting me on the right track Passel!
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  19. #19
    Sinecure devotee
    Join Date
    Aug 2013
    Location
    Southern Tier NY
    Posts
    6,045

    Re: Github For M2000 Interpreter

    I'm not really sure what I did, other than the minor pointing out of a page in the manual.
    I'm pretty sure I would have stopped after step 5 in post #16 if it were me.
    "Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930

  20. #20
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by passel View Post
    I'm not really sure what I did, other than the minor pointing out of a page in the manual.
    I'm pretty sure I would have stopped after step 5 in post #16 if it were me.
    Your long list inspired me to put more effort into investigating the issue and writing a proper reply.
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  21. #21

  22. #22

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Hello Peter Swinkels

    You can run from IDE if you want but you have to do some things:
    First because M2000 has Greek and English identifiers, you have to choose a greek font from VB6. IDE.

    The M2000.vbp make the Μ2000.dll. So you have to start it from Vb6 and then you have to start the m2000.exe, which execute it. I have edit many times code when the dll running from iDE. You can use threads and windows from ide too.


    Please get the revision 46 of version 9.9
    You can unistall the language as all programs and then install new again. All binaries are signed by me. The last few also have signed the uninstall exe too.

    Load "alfa.gsb" just open a file to editor, not loaded as program.
    Load name is the proper command

  23. #23

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Peter Swinkels
    Read this (and if you know better english than me, correct it please.
    https://github.com/M2000Interpreter/Version9/wiki

    M2000 has GNU GPL 3 licence
    Maybe you can make the Dutch Version, replacing Greek Identifiers and keep the English. There are more than 500 identifiers for each vocabulary.
    Last edited by georgekar; Jul 17th, 2020 at 11:29 AM.

  24. #24
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Hello Peter Swinkels

    You can run from IDE if you want but you have to do some things:
    First because M2000 has Greek and English identifiers, you have to choose a greek font from VB6. IDE.

    The M2000.vbp make the Μ2000.dll. So you have to start it from Vb6 and then you have to start the m2000.exe, which execute it. I have edit many times code when the dll running from iDE. You can use threads and windows from ide too.


    Please get the revision 46 of version 9.9
    You can unistall the language as all programs and then install new again. All binaries are signed by me. The last few also have signed the uninstall exe too.

    Load "alfa.gsb" just open a file to editor, not loaded as program.
    Load name is the proper command
    Thank you GeorgeKar, But I got M2000 to work. Nice. Keep up the good work!

    yours,
    Peter Swinkels
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  25. #25
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Peter Swinkels
    Read this (and if you know better english than me, correct it please.
    https://github.com/M2000Interpreter/Version9/wiki

    M2000 has GNU GPL 3 licence
    Maybe you can make the Dutch Version, replacing Greek Identifiers and keep the English. There are more than 500 identifiers for each vocabulary.
    Hello GeorgeKar,

    I am not going to be able to proof-read an entire wiki for you, nor am I going to translate an entire project into another language. What I can do is help you with grammar and give advice regarding translations. I attached a corrected version of you Wiki's front page text with corrections in red. You need to pay more attention to how you use the definite article and verb tenses.

    yours,
    Peter Swinkels
    Attached Images Attached Images
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  26. #26

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Thank you very much

    Enjoy the M2000 language.
    There are plenty of programs in info.gsb file.

    if you want to export code from internal editor and you have tabs, then it is better to change automatic to spaces.
    Use Switches "-nbs" in M2000 console, to enable the automatic change
    Use Help Switches to see about command. Switches can be passed to command line when you open m2000 environment.

  27. #27
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Thank you very much

    Enjoy the M2000 language.
    There are plenty of programs in info.gsb file.

    if you want to export code from internal editor and you have tabs, then it is better to change automatic to spaces.
    Use Switches "-nbs" in M2000 console, to enable the automatic change
    Use Help Switches to see about command. Switches can be passed to command line when you open m2000 environment.
    Okay. :-)
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  28. #28

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Peter Swinkels,
    Don't miss the last revision 48. Also I change a bit the M2000paper.pdf.
    Last edited by georgekar; Jul 19th, 2020 at 11:24 AM. Reason: change a word

  29. #29
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Peter Swinkels,
    Don't miss the last revision 48. Also I change a bit the M2000paper.pdf.
    Georgekar, I was mostly just curious about your program. I am not going to be an active user. Sorry. If you have any specific questions I can help with though I will do my best to answer those.

    yours,
    Peter Swinkels
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  30. #30

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Peter,
    Do you run the programs in info.gsb? The biggest is a chess (without AI, just for two players) using FEN strings for storing previous positions. At the end you can export these strings and pick one to start from that point or in the game you can go back to some earlier point.
    Revision 49 is the best one for now.

    For any reader,
    M2000 has not the strength of a production language. From a point of view the environment of the language recreate a micro from '80s, using user GUI, OOP, Lambda functions, massive memory, graphics, sound, speech, score playing through midi, threads as part of the language, event programming, using of external com objects with events, using of external functions in dll, by C or StdCall calling convention. Also you can use/make databases and handling printers too.

    Some languages change in time, making obsolete things. M2000 ban the obsolete mechanism. You write a program, today and has to run twenty years later. For this reason and the benefits from VB6 like the compiling directive to exclude arrays bound checking (like c), M2000 use VB6. The core dll of VB6 as I know is a part of Windows 10. So if Windows 10 is the last operating system from Microsoft, then Vb6 core dll would exist decades from today.

    M2000 has two sets of identifiers, from English and Greek languages. Scope of the double set is to be later change one,say the Greek, to another language. Also the help system works for both languages so for a new language we have to provide help text for each identifier. It's important for me a pupil to programming using identifiers from his or her language.

    George Karras
    Last edited by georgekar; Jul 20th, 2020 at 02:08 AM.

  31. #31
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Peter,
    Do you run the programs in info.gsb? The biggest is a chess (without AI, just for two players) using FEN strings for storing previous positions. At the end you can export these strings and pick one to start from that point or in the game you can go back to some earlier point.
    Revision 49 is the best one for now.

    For any reader,
    M2000 has not the strength of a production language. From a point of view the environment of the language recreate a micro from '80s, using user GUI, OOP, Lambda functions, massive memory, graphics, sound, speech, score playing through midi, threads as part of the language, event programming, using of external com objects with events, using of external functions in dll, by C or StdCall calling convention. Also you can use/make databases and handling printers too.

    Some languages change in time, making obsolete things. M2000 ban the obsolete mechanism. You write a program, today and has to run twenty years later. For this reason and the benefits from VB6 like the compiling directive to exclude arrays bound checking (like c), M2000 use VB6. The core dll of VB6 as I know is a part of Windows 10. So if Windows 10 is the last operating system from Microsoft, then Vb6 core dll would exist decades from today.

    M2000 has two sets of identifiers, from English and Greek languages. Scope of the double set is to be later change one,say the Greek, to another language. Also the help system works for both languages so for a new language we have to provide help text for each identifier. It's important for me a pupil to programming using identifiers from his or her language.

    George Karras
    No, I don't but I had a look. Is your chess game text based? How does it work?
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  32. #32

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    It's graphical, and you can move the pieces or write simple e2e4 + enter to move it.
    Load Info
    Then press F12 to start chess. You can pick a FEN string and start chess with that string to open chess with the pieces according to FEN
    https://en.wikipedia.org/wiki/Forsyt...wards_Notation

  33. #33

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Peter,
    Also check the BJ (black jack) and Pong (a kind of Pong game for one player)

  34. #34
    Fanatic Member
    Join Date
    Feb 2003
    Posts
    925

    Re: Github For M2000 Interpreter

    Quote Originally Posted by georgekar View Post
    Peter,
    Also check the BJ (black jack) and Pong (a kind of Pong game for one player)
    Seen it. Impressive. GeorgeKar, I have been using computers since 1987, the computer your program is emulating isn't particularly user friendly...
    Several projects of mine that used to be posted here can now be found at: https://github.com/PeterSwinkels

  35. #35

    Thread Starter
    Fanatic Member
    Join Date
    May 2014
    Location
    Kallithea Attikis, Greece
    Posts
    958

    Re: Github For M2000 Interpreter

    Intentionally isn't user friendly. As I remember, neither a Texas TI99/4A, from a friend, was user friendly nor the Acorn Electron I owned in the year 1984 was user friendly. Always with the manual at hand, and some magazines from I had to write on it, and then if I didn't accidentally push the break button, I had to saved on a tape drive,


    So in M2000 if you press break (the pause button) you get a message to ask you if you really want to reset the environment. And that is a bit more of user friendly.


    Some tips:
    Win Dir$ (open the user directory on explorer)
    Keyboard ! (open the virtual keyboard)
    Settings (open the settings dialog)
    With a new revision the info file may change, so:
    Dir Appdir$
    Load Info
    Then press F1 to save it to user folder


    Now if info is loaded then press F8 open the mEditior, a notepad for M2000, in a window, running in M2000. From that open the info file, 25k lines, and you can mark a word and press F3 to search down or F2 to search up. Its very fast editor. This editor use the EditBox a control made in M2000 environment, with programmable syntax color.


    There are other editors:
    CS for CSharp editor, You can compile the program from that editor and execute it. Its simple, but as all those programs included in a distro, has to be simple. Has syntax color for c sharp.
    HtmlEditor Is another one for Html with syntax color too.
    I have another for VB6 but not in the Info.gsb which is a collection of programs.


    Fkey statement display the functions keys which info made for you.


    There three statements which clear a part of internal state:
    New clear programs (as modules loaded)
    Edit A
    write something press Esc to exit
    Modules ? (or ctrl + N)
    You see A as module
    New
    Modules ? (or ctrl + N)
    You see nothing


    Clear clear static variables and global made in console.
    A=10
    List ' show A=10
    Clear
    List ' show nothing


    Flush empty the stack of values
    Check this:
    Push 1,2,3 : Stack: Flush : Stack ' now is empty


    Also statement start is the software reset.
    Don't forget to use END to exit from console
    That's not all
    George

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width