Danish.Chopra

Microsoft has been passionate in creating a user friendly computer environment through OS's and side by side, a developing platform for the same making it to the top of computer arena..

But, imagine a programming language, basically, an integration of Visual Basic,C++ and Assembly language(specifically for Robots and Machines) that could give the programmers the power to bring their visrtual infancies and imaginations to realities..That could be platform independent and could write code for Windows, Linux,(Not MAC yet), Symbian environments. That could be used to develop Application softwares and Web Apps as well. That will be fully compatible with the databases as well. Most significantly, it could be used to program Robots(Artificial Intelligence) and directly put the code into its microprocessors via a port.

A programming language that is all in all with a lot of tools to just select and draw on the form. So, it must have a runtime environment as well as design time(as all programming languages have Smile )..

So, what are the big brains sitting here waiting for. Just put in your ideas and suggestions here to accomplish this task. Maybe we all come out with something, we have had never imagined...




Re: Visual Basic Express Edition Making a programming language like VB


Re: Visual Basic Express Edition Making a programming language like VB

Carsten Kanstrup

Danish.Chopra

It is a nice thought with a general language, which combines everything and is platform independent, but unfortunately it cannot be done the way you describe it. Assembler code is pure machine code and can never be platform independent or managed. It is highly efficient, but will only run on one microprocessor family or even on one microprocessor.

On the other hand, modern languages like VB and C# generate rather inefficient code, which requires enormous hardware resources so I can understand why you want a more efficient alternative. I have actually worked a little on such an alternative called B#.

B# Visual Basic .NET

Integer A, I, N = 3, B.15       Dim A, I As Integer
                                Dim N As Integer = 3
For I = 1 to 10                 Dim B(15) As Integer
    If I = N
       A = B.(I)                For I = 1 to 10
--                                  If I = N Then
                                        A = B(I)
                                    End If
                                Next




Re: Visual Basic Express Edition Making a programming language like VB

JohnWein

A lot of robotics programming is done using a visual programming language like Microsoft's Robotic Studio or National Instruments' LabView. NI's LabView generated $700,000,000 in revenue for the company in 2006.





Re: Visual Basic Express Edition Making a programming language like VB

ReneeC

B.15

You language is a little too terse for me.

I would opt for no squiggles and no case sensitivity. Also my favorite development language, Bliss32 used the following Logical operators.

Neql

Leql

Geql and

eql if I remember correctly. Also it was a potinter based language

On the right hand side of the equals

A was the address of A

.A was the contents of A

..A was the contents of A used as a pointer

A = .B ! place the contents of B in A

A = B ! place the address of B in A

.A = .B ! place the contents of B in what the contents of A is pointing to

Also if love the IF statement

IF (A = Expression) then

Begin

Else

Endif ! I am trying to remember if used a semi-colon. I think it did at the end of an expression or code block.

In the IF ststement above the if tested the express as it set A to the value of the expression.

Bliss32 was a very power system implementation langauage






Re: Visual Basic Express Edition Making a programming language like VB

Carsten Kanstrup

ReneeC

In VB, can you tell whether A = B(I) is a function call or index I of array B VB is not strictly consistent, but B# is! B.15 is just the way an array object (or string) is declared in B#. B.I is element I of object B, B.(I) is element number I (expression) of object B (array or string), and B(I) is a call of the function B with I as input data.

Have you tried to photocopy some code with both A and .A Then you will find out that small dots with big significance are not a good idea!

The basic idea of B# is completely different from traditional languages like VB and C#. It is based on a queue system for methods, which shall run (triggered by an event). Because no methods are allowed to run for more than 1 mill. cycles (corresponding to approximately 1 mS on a modern computer = the interrupt latency) there is no need for any threads or thread switching and no need for endless data copying (ByVal). All this is replaced with two or three priority levels (one queue for each level). It is not even necessary with special interrupt processing, DCP and APC routines etc. An interrupt routine is just a standard high priority method with kernel mode rights (protected mode), which is not allowed to run for more than approximately 65.000 cycles. This makes it much easier to write drivers. We have used a similar system for electronic process control since 1978 and it works extremely efficient and is very easy to program.





Re: Visual Basic Express Edition Making a programming language like VB

ReneeC

Carsten I've never been crazy about the 1 ms timeslicing. You see, this "event driven queue" is only "event driven" within your compute quanta.

Your cycle counting even will be costly unless that's done in hardware. Actually as I think about it the queue idea not only appeals to me, but VMS used to do it BUT with huge provisos. VMS had IPL. They could be either hardware or software generated. Time sharing was done at IPL 0 (which had 32 software priority levels.). There was no timesharing about IPL 0.

The rules were, you could process at a give IPL until you completed or you were interrupted by a higher IPL. All execution at IPL > 0 were done either in Executive Mode or Kernel mode. But this unix like

But ii does sound interesting. I've never had any trouble with the dots. Back when I learned bliss, they used to Microfiche build listings including compiler listings. Bliss compiler listings included source code. There was one routine I really needed so I hand type the compiler generated assemler in.

You have methods in queue How is context maintained. How is a method mapped to a process or owning entity






Re: Visual Basic Express Edition Making a programming language like VB

Carsten Kanstrup

ReneeC

Of course the cycle counting shall be done in hardware, but it is extremely simple as you only need a counter connected to the CPU clock. You just need to restart (reload) this watch dog timer each time a new method starts working. As long as no methods exceed the maximum time (bad programming), the timer never runs out. It is not a time sliced system, but 100% event driven. For example, if an input, which is used in object A, changes state, object A is pushed on the queue (shall be calculated) if it is not already there. Because no method/object are put on the queue if it is already there, you know for sure that all other methods/objects, which use data from this object (A), gets a chance of running before the data can change again, so nothing needs to be transferred by value. There is no context to maintain in the traditional sense.

There is an old description of these thoughts on our homepage: http://www.innovatic.dk/programm.htm . Note however, that it is only a first draft and some loose thoughts! B# is not implemented yet and many things will probably change. For example, it is probably not possible or appropriate to replace all subroutines with classes. The process control example is very close to the way we have programmed process control systems and the part of B#, which is best worked through. The job is to combine this with the methods of traditional object oriented programming, but without the very low efficiency of the endless method calls and enormous memory usage.





Re: Visual Basic Express Edition Making a programming language like VB

Amrykid

i all so wanted to make one but should u think about this....Wouldn't Microsoft think ur copying them...., u would have to make a app and 1000 (estimate) of dlls to reconize the language (Micrsoft.NET example).

But ReneeC makes a good point.





Re: Visual Basic Express Edition Making a programming language like VB

Carsten Kanstrup

Microsoft didn't invent neither Basic nor Fortran 95 and don't worry - we are not going to copy the Microsoft DLL-hell!





Re: Visual Basic Express Edition Making a programming language like VB

Amrykid

u will need a IDE, a MSL compiler, and a native code compiler.





Re: Visual Basic Express Edition Making a programming language like VB

Danish.Chopra

DOCUMENTATION FOR OPEN SOURCED PL V1.0(beta)

1. use LIBRARYNAME

LIBRARIES-

basic, math, string, script, adodc, filehandle, media, graphics, security, time, ole, ports, registry, custom, internet, shell

Each lib will be a dll and shall be exported with the exe as standard deployement.

Libraries and their functions:

1. basic- messages, print on screen, input from user(onscreen input,textbox,inputbox)

2. math- all arithmatic n logical functions

3. string- all string functions

4. script- scripting n runtime functions

5. adodc- databases related

6. filehandle- richtextbox, simple file handle functions

7. media- play sound, animation, play audio, play video(it shall use bass.dll bass audio library for audio and standard windows video playback for videos)

8. graphics- image n picture operations, animations, drawing

9. security- encryption n decryption of text using predefined algorithms viz .. encrypt(text as string, algo as algoname), staganography, passwords

10. time- all time n date related functions

11. ole- microsoft ole

12. ports- winsock and other tools to directly communicate with devices via LPT1(Printer port), USB or standard ports. Here is where we need to do the trick to directly control the robot.

13. registry- create, edit or delete registry values

14. custom- to use already made dlls;(like in vb)

15. internet- update my software, mailto: , open website and others

16. shell- all shell functions

2. Variables n constants declarations

declare var var_name as datatype

global declare var var_name as datatype '(global declarations)

init declare var var_name as datatype= initvalue

array declare var var_name as datatype (index)

datatypes:

a. number '( Number will include integer,double as well as float values)
b. string

3. Other information

main

it will be the main function to be called first during runtime

tools

ready to use tools in the toolbox. When a tool is used, its LIBRARYNAME should automatically be declared

functions

syntax- function FX_NAME(paramter1 , parameter 2....)

selection and iteration

selection- if, if else, select case

iteration- do , dowhile, for

Operators

=, +,-,<,>,mod(math),*,/

operator precedence -{}, [],bodmas

______________________________________________________

I think this is just quite enough to start the thing. Please put in your every possible suggestion(s) to make the project a success...






Re: Visual Basic Express Edition Making a programming language like VB

ReneeC

well then you are aking the same mistake again.

Have you asked yourself WHY there are DLLs in the first and what the problem was that they attempted to solve

They were a way to deal with interoperability between languages. What's the problem

Let's say you have a method with two arguments

Kyra( A,B) . A and B are two arguments and the problem is that there is no calling standard between lanaguages. One language may create a packet for the arguments and call kyra with a single argument which is a pointer to the packet. The Callee being in the same language looks on the stack and retrieves the pointer to the packet, then retriving the two arguments.

Another language might do this

PushAB Arg1

PushAB Arg2

Push #2

The first thing the callee does is Pop #2 off the stack and now it knows that there are 2 arguments following so it pops A and pops b. The stack is now clean.

So here the problem with interoperability. Some langauges expecting a packet will look at address 2 for the arguments and touching that address is fatal exception.

VMS began with a calling standard, the same one for ALL languages. Our object code, in many languages can be combined and executed and because of the calling standard all languages did this in exactly the same way. We never had dll hell because of this. We had an RTL (runtime library) that were called by everyone and it was very stable.

So instead of the old definition of DLL forget it. The CRL is the way to go with ONE consisten calling standard.






Re: Visual Basic Express Edition Making a programming language like VB

Carsten Kanstrup

And perhaps it is time to get rid of COM and OLE too, and maybe most parts of the registry

Danish.Chopra

Why do you want to copy all the Microsoft mistakes For example, RichTextBox is an absolutely terrible way to add some colors and fonts. Use HTML instaed if you really want to do your own.

Sorry to say it, but where is the new and revolutionary You even mention the parallel port, which is not used anymore.

.NET, VB and Visual Fortran 95 does a very good job - except for the rather low efficiency, which is the reason why I have looked at an alternative. In my visions, a new microprocessor architecture combined with a much more efficient programming method would make it possible for most people to have enough computer power in a mobile phone. No need to carry heavy laptops around. When you reach your distination, school, home, office or even in the train or aeroplane, you just plug your mobile phone into a screen/keyboard/power-supply assembly and of course the internet connection is wireless. This would also make it possible for all school children to use computers - even in the first grades and even in the third world where people are left behind because they cannot afford the present computer technology. In India, they have actually started a project to make a $10 computer for their children. Now that is visions and a good reason to look at something new! You would even save the world for millions of tons of CO2. Do you know that the total CO2 emission coursed by the power consumption in the IT world today is as big as the one from the total aviation

Microsoft has by far the biggest development resources in the World. If you just copy them, you will have absolutely no chance of success!