Design Con 2015
Breaking News
Comments
Newest First | Oldest First | Threaded View
Page 1 / 2   >   >>
David Ashton
User Rank
Blogger
Re: Long Live BASIC
David Ashton   5/2/2014 8:54:38 PM
NO RATINGS
@Crusty, sounds like you are better qualified than I to comment on Basic (pardon the pun).

"Whilst tidying up my components box I came across a 40 pin chip marked up ZILOG Z861 BASIC/DBG, now this was sold for embedding, I shall reinstate it very soon and do a blog, Max please take note."

Can't wait.....get it done, please!

"As for Bascom as an embeded compiler it hardly looks like Basic and it is certainly structured, and produces compact assembler. "

I'd like to give it a try sometime....but you're almost putting me off..... :-)

"All code can be badly written and the worst offence is not to comment what is happening line by line"

Good advice.  A number of times I have been saved a lot of time by commenting my code well.

David Ashton
User Rank
Blogger
Re: Long Live BASIC
David Ashton   5/2/2014 8:47:59 PM
NO RATINGS
@MB - thanks for all that.  I've never used VB, sounds like I should have,   Your code above is perfectly understandable.

"You can write good structured code in any language or you can write spaghetti code in any language."   Well said.

Measurement.Blues
User Rank
CEO
Re: Long Live BASIC
Measurement.Blues   5/2/2014 10:42:15 AM
NO RATINGS
Visual Basic lives inside Excel, Word, etc. Here's a little code example.

Private Function Temperature(Resistance, _
         Optional CorF As String = "C") As Double
   ' This function takes the input value in ohms
   ' and converts it to degrees C using the Steinhart-Hart
   ' equation.
   Dim lnRes As Double
   Dim lnRes3 As Double ' the cube of lnRes
   Dim temp As Double
   Dim TempC As Double

   If Resistance <= 0 Then Exit Function

   lnRes = Log(Resistance)
   lnRes3 = lnRes * lnRes * lnRes

   'Calculate reciprical of temperature in  C
   temp = a + B * lnRes + C * lnRes3
   TempC = 1 / temp - 273.15

   If InStr(1, CorF, "F") Then ' user wants degrees F
      temp = TempC * 9 / 5 + 32
   Else                        ' user wants degrees C
      temp = TempC
   End If
   
   ' show only one digit
   Temperature = CDbl(Format$(temp, "##0.0"))
   
End Function

Measurement.Blues
User Rank
CEO
Re: Long Live BASIC
Measurement.Blues   5/2/2014 8:49:59 AM
NO RATINGS
You can write good structured code in any language or you can write spaghetti code in any language.

"It amazing how much Basic I have used and I cannot agree that it stopped me from developing a good structured style of writing code."

Measurement.Blues
User Rank
CEO
Re: Long Live BASIC
Measurement.Blues   5/2/2014 8:48:44 AM
NO RATINGS
Microsoft revived Basic in the form of Visual Basic. I liked using it because I could use a language I knew, yet add the nice GUIs that windoed provided. I wrote an article where I used VB in Test & Measurement World. (If you really want to read it, let me know because I have to scan the print version.)

In the 1990s, I published numberous articles about VB for T&M.

There were also T&M extentsion for VB. Measurement Computing had developed Softwire, which added graphical programming to VB.

Measurement.Blues
User Rank
CEO
Re: I wuz there
Measurement.Blues   5/2/2014 8:41:49 AM
NO RATINGS
BASIC still lives as a programming language for test & measurement. You can still get HTBasic, descended from HP-Basic, developed for HP computers in the 1960s and also known as Rocky Mountain Basic.

 



Crusty1
User Rank
CEO
Re: Long Live BASIC
Crusty1   5/2/2014 7:31:06 AM
NO RATINGS
@David: It amazing how much Basic I have used and I cannot agree that it stopped me from developing a good structured style of writing code.

The frist time I programmed was using a remote terminal at London Undergounds Research Laboratory to process lamp test results, it was connected by a dismally slow modem to the IBM mainframe and it took me a month of 1 hour slots of self learning to get my first Basic programme to run.

Then there was the PDP11 all assembler. That was easier as I sat next to the cabinet which in winter kept me warm and very hot in summer.

Never did much with the PC when the first desk tops came out, but when Amstrad produced their PC nock off I started to use them, They were no bad machines and of course had basic on the boot disk.  Did not like this flavour of Basic and got Borland Pascal almost immediatly, what a lovely compiler that was.

For the home use

The Ohio Scientific single board computer (UK101) Basic in rom only goto's, still have the ROMS

The Apple IIe basic built in Goto's, still cherish my one and it has Pascal on disk and a structured basic.

BBC Basic on the Acorn machines were well advanced with procedures and functions and both my children became professional software writers after using these machines at home and at school. Yes mine is still running with Basic, Pascal, and a host of other rom Languages

Whilst tidying up my components box I came across a 40 pin chip marked up ZILOG Z861 BASIC/DBG, now this was sold for embedding, I shall reinstate it very soon and do a blog, Max please take note.

As for Bascom as an embeded compiler it hardly looks like Basic and it is certainly structured, and produces compact assembler.

All code can be badly written and the worst offence is not to comment what is happening line by line, it's one of the things I hate about so much C code that is published. No comments and the special C shorthand key strokes that for a beginner are almost unintelligable. No wonder the Arduino wrapper was used to get beginners started in C.

Long live any method that gets people started in code and hardware.

 

David Ashton
User Rank
Blogger
Re: Long Live BASIC
David Ashton   5/2/2014 5:13:56 AM
NO RATINGS
@Bert, I'd agree that Quickbasic (in which I once wrote a successful terminal emulation program) and the other BASICs that are still around should be lumped with the earlier, clunkier versions when considering if it, as a language,  is dead or not.   (Did you know you can still download GWBASIC?)  I've never used VB much so can't comment there.   But when the author says

>" It is confined to the products of several small companies that keep the tradition alive but who are unlikely to do more than ride the language until it dies out entirely."

I'd reluctantly have to agree.... apart from a few PC products and PICAXE and BASCOM in the embedded world, and some fairly fanatical adherents, you don't find it much.  I wouldn't say it's on the verge of death but I think it will fade away in time.

Bert22306
User Rank
CEO
Re: Long Live BASIC
Bert22306   5/1/2014 8:47:24 PM
NO RATINGS
Yes indeed, long live Basic. I think the article is offbase, in that it doesn't acknowledge that QuickBasic is considered by most people to be the natural evolution of Basic. When people mention "Basic" today, aside from historical contexts, it's QuickBasic they're referring to. The days of line numbers, dependency on GOTO statements, and one letter and one-numeral variable names, are multiple decades in the past. (Last time I worried about that was in the mid 1970s! With an HP 9830A, which btw, was very much a small desktop computer. Even the time-shared Basic of those days was past these constraints.)

My view is, Basic has stood the test of time, where many others have come and gone. For instance, Fortran, Cobol, Ada, Pascal, APL, PL-1, where have thay all gone?

I think most QuickBasic code should run as is, in VB, no? I don't use VB, but from the manuals I've read, that seems to be the case. And there are current variants of QuickBasic that go beyond where Microsoft left off, with their version 7.1.

Long live Basic! I've got QB64 in my PC. works great.

BrainiacVI
User Rank
CEO
Re: I wuz there
BrainiacVI   5/1/2014 4:54:17 PM
NO RATINGS
BASIC is my go to (cough) language if I need to do parsing of data in lines. Other languages can do it, but not as easily. Sometimes parsing seems like a lost art among the newer programmers.

Page 1 / 2   >   >>


Top Comments of the Week
Flash Poll
Like Us on Facebook

Datasheets.com Parts Search

185 million searchable parts
(please enter a part number or hit search to begin)
EE Life
Frankenstein's Fix, Teardowns, Sideshows, Design Contests, Reader Content & More
<b><a href=Betajet">

The Circle – The Future's Imperfect in the Present Tense
Betajet
5 comments
The Circle, a satirical, dystopian novel published in 2013 by San Francisco-based writer Dave Eggers, is about a large, very powerful technology company that combines aspects of Google, ...

Max Maxfield

Recommended Reads From the Engineer's Bookshelf
Max Maxfield
27 comments
I'm not sure if I read more than most folks or not, but I do I know that I spend quite a lot of time reading. I hate to be idle, so I always have a book or two somewhere about my person -- ...

Martin Rowe

Make This Engineering Museum a Reality
Martin Rowe
Post a comment
Vincent Valentine is a man on a mission. He wants to make the first house to ever have a telephone into a telephone museum. Without help, it may not happen.

Rich Quinnell

Making the Grade in Industrial Design
Rich Quinnell
16 comments
As every developer knows, there are the paper specifications for a product design, and then there are the real requirements. The paper specs are dry, bland, and rigidly numeric, making ...

Special Video Section
The LT8640 is a 42V, 5A synchronous step-down regulator ...
The LTC2000 high-speed DAC has low noise and excellent ...
How do you protect the load and ensure output continues to ...
General-purpose DACs have applications in instrumentation, ...
Linear Technology demonstrates its latest measurement ...
10:29
Demos from Maxim Integrated at Electronica 2014 show ...
Bosch CEO Stefan Finkbeiner shows off latest combo and ...
STMicroelectronics demoed this simple gesture control ...
Keysight shows you what signals lurk in real-time at 510MHz ...
TE Connectivity's clear-plastic, full-size model car shows ...
Why culture makes Linear Tech a winner.
Recently formed Architects of Modern Power consortium ...
Specially modified Corvette C7 Stingray responds to ex Indy ...
Avago’s ACPL-K30T is the first solid-state driver qualified ...
NXP launches its line of multi-gate, multifunction, ...
Doug Bailey, VP of marketing at Power Integrations, gives a ...
See how to ease software bring-up with DesignWare IP ...
DesignWare IP Prototyping Kits enable fast software ...
This video explores the LT3086, a new member of our LDO+ ...
In today’s modern electronic systems, the need for power ...