Posted on
  • Although JavaScript might be considered the language of the Web it is in no way the language of laptops, Tv's, severs, or other equipment. The authors seem to have, as many others, confused the programming language JavaScript with Java. Java indeed seems to be the language of 'things'. JavaScript is primarily used as Web browser front end programming language. The two couldn't be more disparate. For one thing Java is a class based language and JavaScript a prototype based, to just mention one dramatic difference . Please correct the main page:

  • Espruino runs Javascript. Not java.

    Js is much more than a front-end language today. Have you ever heard of node.js, for example?

  • I think you might be at least 5 years out of date with your information.

    Java was used in a variety of things but I think you'll find that difficulties in licensing, security issues, a spam-laden installer and a slightly hostile attitude by Oracle, the new owners has really started to crush its usage in new projects.

    For instance you used to be able to include Java on a webpage - you really can't even do that now because it's disabled by default.

    You might not like it, but JavaScript is on your laptop, phone, TV and any web server with an OS from the last 5 years. In contrast, Java does not come pre-installed on many webservers, phones or laptops.

    Basically you might not like JavaScript - that's fine. But I'm not removing a true statement from the website because you have some irrational problem with it.

  • @user70843
    Are you serious about that? My first thought was: It's a joke. But why on Dec 3rd? May be April Fools' Day in another country? :-)


    Java was used in a variety of things ...

    My two cents to the importance of Java - unrelated to Espruino.
    Java is really dead - running as applet in the browser!
    On the server side it is very popular. The biggest shopping systems, ERP, telecommunication, banking, energy sector applications, .. a majority of the "enterprise" things run on Java.
    By the way the most popular mobile platform is largely built with Java.

    Java and JavaScript are both not common in embedded programming. But latter is changing with Espruino. ;-)

  • ...please... the world is a hybrid place... as much I love JavaScript, Java has its space... as time has seasons, languages have their domain.

    Indeed, Java is not as 'free' anymore as it was... and interestingly, JavaScript caught up in a way not even its creator had expected it.

    Something is for sure: neither will go away soon. When languages of the past needed decades to become Legacy, both Java and JavaScript are already Legacy and are still moving on - not so other languages.

  • Yeah, I was guilty of being deliberately provocative given the original post :)

    I actually love Java, and have done a huge amount of work with it. I've found it amazingly nice to write, and surprisingly fast. I'd argue that with the profiling tools available it's often easier to make something faster in Java than it is with C++.

    It's a much nicer language than JavaScript, and would have been much more pleasant for me to write an interpreter for :)

    So it's a bit depressing for me to see it not taking off. I guess you could argue that it has had a massive effect as part of Dalvik in Android though.

    It's still used in a lot of things, and as you say still very heavily in industry. I feel like JavaScript is probably overtaking Java in new projects though, and the language popularity graphs I can find seem to show the Java usage is very high, but has 'plateaued'.

  • I have heard of node.js and have made a couple of services on that. But I'm constrained to stress that node.js is just a small ripple on the server programming environments, currently.

  • I'm not favourizing either technology and I like, or dislike both JavaScript and Java. My point is, that your BD has a Java component. The Bd-j development layer encompasses Java not JavaScript. My Blueray player sports an Oracle Java logo, not a JavaScript logo.
    I'm seem to be quite as irrational as you are.

  • My additional two cents, if I may, both JavaScript and Java seem to be a good idea at the time. Now for the risk of being treated as a Microsoft fan-girl, I believe that a C# device would be prosperous for the way the IoT will commence. Both Js and Java have their flaws, C#,. NET, mono, seem to be the way to move forward.
    But I'm distracted. I don't believe my 10 year-old television understands JavaScript where it does do Java whether I like it or not.

  • Thanks, Gordon.
    As I pointed out I try to be 'colour blind' on the aspect which one is better or worse. My point is that the original aim of Oracle's Java platform independence, which has lured so many developers in the 80-ies and 90-ties, has been successful on the device development, and has even moved itself successfully to, for instance, the BD specifications. If that is a good thing or not is open for debate.
    Yet, I don't think my car understands JavaScript, apart from the build in Webbrowser. But Java might've found it's way to more system critical system, where I seriously shudder in awe at the thought of that.

  • @user70843, what is the thing that makes you shudder?

    All languages - if deemed economically viable - have now a days an extremely elaborate runtime environment... for example: object oriented support, memory management, garbage collection, communication subsystems, etc...

    Success or failure of a language (and all the related things) - simply put 'a tool' - is based on the adoption of the runtime environments, development environments, management environments, and most importantly the acceptance of the related requirements / prerequisites by users and industries.

    Many decades ago users would swear by card punching, batch processing and serial files (...oh my dear tape drive)... all this new stuff, like transaction monitors, online / dialog applications, VSAM, and hell-no SQL databases... is just the downfall of IT.

    After complacent IT humanity adopted and got well with this 'new stuff' (and batch managers retired... disgruntled or lucky not to have to learn and adopt new things), a new threat came:

    Virtual Machines for running languages... starting with - to just name a few - Simula, CSP (Cross System Product - application compiled into some 'byte-code' running on any mainframe OS and even batch unchanged), Smalltalk, xyz-Basic, Java - and many pre-dating flavors from various manufacturers - all these were now the new target of the woes, performance concerns, etc... Btw, performance includes 'time to market' time... and thus the perfectly implemented and running app may just come onto the market too late... and will die perfectly fast its death.

    Above I mentioned ...adoption by the users... when you have in your organization not enough what ever programmers, you look at the market for supply... and if not found, you reconsider what ever and you may migrate to what else.

    Same goes for this: If you have your what ever personal on board and they know your business, but too bad or too lucky, they know C# and there is no blocker (and it is not declared illegal to use it)... you get your next app done in C#... (just to tease you a bit)... After all, it is your business that counts (or pays your what ever personal's pay checks). The means are just what means means: means.

    Over time, all these things are part of decisions and have an impact on what direction IT is heading to.

    @Gordon made an extremely valuable contribution to and great enablement of IoT for all! Any one that can grasp - or knows already by trade - (some) JavaScript will get (almost) all the benefit as if coding down to the bare metal... (This is btw the first time - in my life - I use the meaningless wording 'trust me' ... but in this case, I feel pretty comfortable to do so: t... m., doing bare metal programming aeons ago when MC processors were as simple as being lord over one to a few KB of code and had 'half a timer', one serial at best, a couple interrupts... was great pain... already with only a few peripherals and appliances. Even though some Tiny Basic(s) existed - for example on the CDP1802 and Z8 - and still do, there is just no way you could do what is possible with Espruino and focus on the application part as opposed to get the MC even going...). Not talking about managing (deep) sleep or other nice things which are crucial to IoT.

    There is nothing as solid, robust, and advanced as Espruino is. Nothing comes even close... many have tried... some died already in their first (kickstarter) attempt,... T.....

    I use - with joy AND pride - the wheels @Gordon provides me... and some wheels I built myself - the ones that stood the test of the time - and just 'drive on'. Part of being a giant is being able to stand on shoulders of giants... C is for sure a giant... and C is the enabler of the Espruino JavaScript layer, a giant that makes IoT as Easy as 1, 2, 3.

    PS: Your car understands CAN (BUS), and how the data / information got there does not matter... may be it is an Espruino that controls - creates the control data for - your air conditioning system... So next time your air conditioning system helps you to stay cool, mutter a thanks and keep on cool driving... ;-)

    Btw, I like fan kids - girls or boys... If you cannot be a fan of something, how much life is in you!... A fish is fan of the water, we are a bit more fan of the air... but that makes life colorful and interesting... and we can learn from each other. Only an insider can share both - the weaknesses and strengths..., and we are proud to celebrate the strengths!

    • cheers from 'more cents to spend'.
  • @allObjects thanks!

    I don't think my car understands JavaScript, apart from the build in Webbrowser

    This is kind of the point though - pretty much any device with a Web Browser contains JavaScript and a well-tested, standardised set of APIs - that is so well sandboxed there isn't a problem letting it execute arbitrary code.

    If you're ignoring web browsers then sure, JS use isn't that high. But if you include them then JS is all over the place.

    My Blueray player sports an Oracle Java logo, not a JavaScript logo.

    If it's modern I'd be surprised if it didn't have a web browser, in which case it runs JS too. If I wanted to run my own personal code on your Bluray player or TV, chances are I could easily run JS by navigating to a website. I can't help thinking that the Java implementation may actually be a bit harder to use?

    The fact your player doesn't need a JS logo on it is probably because the licensing of JS is more permissive than Java. If you have a device with a few extra MB of storage, it's effectively free to add - whereas as far as I know Java still requires a license fee (unless you use the OSS versions?). That's one of the reasons I think JS (despite being a less nice language than Java) will probably win out in the end.

    a C# device would be prosperous for the way the IoT

    Have you come across .NET Gadgeteer? You might like that :) I should stress though that there are many kinds of embedded device - most C# and Java environments I've seen for embedded tend to use substantially more powerful controllers than are being used for Espruino... In a lot of cases they'll work great for IoT devices, but in others you might want something that is cheaper or uses a bit less battery power.

    Anyway, everyone's entitled to their own opinions, and Java is a good language that is in use in a lot of places. I just think your initial 'Please correct the main page' may have been a bit inflammatory :)

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview


Posted by Avatar for user70843 @user70843