Monday Aug 04, 2014

James Gosling's slate.com article about using Java SE Embedded 7 on ARM

Here's a cool Slate Magazine article I saw Yael W. like on Facebook about how James Gosling uses Java SE Embedded 7 on ARM for his wave riding Liquid Robotics robots.

See:

James Gosling's slate.com Article

James Gosling
August 2 at 10:10am

Java sailing in the arctic!! These are some of 
our new bots whose control system is running on 
top of the embedded ARM JVM (we're still on JDK 
7). We've got two other groups of them in the 
arctic this summer, including three very close 
to the north magnetic pole - had to write some 
very special navigation code. Crazy stuff

Now, that is cool stuff and an awesome use of the Java SE Embedded technology. Internet of Wave Riding Things (IoWRT).

Friday Aug 01, 2014

New Raspberry Pi Model B+ Runs Java SE Embedded Apps Just Like Model B

What's the difference between the new Raspberry Pi Model B+ and the old Model B? Well, it's more than just the plus sign (+) in the name. There are more USB ports, better sound, and lots and lots more GPIO Pins.

Now that's what I'm talking about! I like having more GPIO pins when connecting my Java SE Embedded apps to all types of tasty devices like sensors and actuators!

See Raspberry Pi video blogger, Carrie Anne Philbin's run-down of the list of new features of the new RPi Model B+ on YouTube:

Geek Gurl Reviews RPi Model B+

And to add to the Geek Gurl's video (above), you should know that of course, all your old Java SE apps will run on the new RPi Model B+ without any problem, because... duh... "Write Once, Run Anywhere" Ya know? Java? Hello? Good stuff!

Just remember to update your version of the Java SE Embedded platform to the latest release on your Raspbian operating system:

sudo apt-get install oracle-java8-jdk

That's it! You will now have the most recent Java SE Embedded platform, the most awesome embedded platform for your Raspberry Pi Model B, B+, and any other letter and arithmetic symbol you can think of. Port your Model B Java apps to the Model B+ by just copying over the JAR files. What's easier than that? :-)

Wednesday Jul 23, 2014

How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 8)

Now, your Parallax Single Relay Board from your Raspberry Pi is connected to your furnace, fan, and A/C control wires. Let's just stop right there and soak that in.

Your Raspberry Pi is now the hardware equivalent to a Nest Thermostat. Nice work so far! You just need intelligent software to run the Raspberry Pi to control your home heating and A/C. And, of course, you don't want to use just any programming language to do that. You want your Raspberry Pi to be a smart Internet of Things (IoT) device, not a dumb device. So, you're going to need Java SE Embedded Technology.

Here's the simple Java code that will drive your relays to turn on your furnace, fan, and A/C. It's a test app that cycles your heat on for 5 minutes, then your fan on for 5 minutes, then your A/C on for 5 minutes with a rest period of 2 minutes in between.

    static String[] GpioChannels =                                
    { "0", "1", "4" };
 
 /* ... */

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        FileWriter[] commandChannels;
        
        try {
            
            /*** Init GPIO port for output ***/
            
            // Open file handles to GPIO port unexport and export controls
            FileWriter unexportFile = 
                    new FileWriter("/sys/class/gpio/unexport");
            FileWriter exportFile = 
                    new FileWriter("/sys/class/gpio/export");

            for (String gpioChannel : GpioChannels) {
                System.out.println(gpioChannel);
    
                // Reset the port
                File exportFileCheck = new File("/sys/class/gpio/gpio"+
                    gpioChannel);
                if (exportFileCheck.exists()) {
                    unexportFile.write(gpioChannel);
                    unexportFile.flush();
                }
            
                // Set the port for use
                exportFile.write(gpioChannel);   
                exportFile.flush();

                // Open file handle to port input/output control
                FileWriter directionFile =
                    new FileWriter("/sys/class/gpio/gpio" + gpioChannel + 
                        "/direction");
            
                // Set port for output
                directionFile.write(GPIO_OUT);
                directionFile.flush();
            }
/* ... */


       // Set up a GPIO ports as a command channels  
       FileWriter heatChannel = new   
                FileWriter("/sys/class/gpio/gpio" +  
             GpioChannels[0] + "/value");  
       FileWriter fanChannel = new   
                FileWriter("/sys/class/gpio/gpio" +  
             GpioChannels[1] + "/value");  
       FileWriter acChannel = new   
                FileWriter("/sys/class/gpio/gpio" +  
             GpioChannels[2] + "/value");  
         

       // TEST Cycle all 5 min. on, 2 min. off
         // HIGH: Set GPIO port ON  
         heatChannel.write(GPIO_ON);  
         heatChannel.flush();          
         java.lang.Thread.sleep(300000);  
       
         // LOW: Set GPIO port OFF  
         heatChannel.write(GPIO_OFF);  
         heatChannel.flush();  
         java.lang.Thread.sleep(120000); 

         // HIGH: Set GPIO port ON  
         fanChannel.write(GPIO_ON);  
         fanChannel.flush();          
         java.lang.Thread.sleep(300000);  
       
         // LOW: Set GPIO port OFF  
         fanChannel.write(GPIO_OFF);  
         fanChannel.flush();  
         java.lang.Thread.sleep(120000); 

         // HIGH: Set GPIO port ON  
         acChannel.write(GPIO_ON);  
         acChannel.flush();          
         java.lang.Thread.sleep(300000);  
       
         // LOW: Set GPIO port OFF  
         acChannel.write(GPIO_OFF);  
         acChannel.flush();  
         java.lang.Thread.sleep(120000); 
 
       }    
     } catch (Exception exception) {  
       exception.printStackTrace();  
     }  
   }  

Pretty straight-forward stuff. It's easy when you use Java SE Embedded technology and a Raspberry Pi. Hey, someone should trademark that... ;-)

Full series of steps:
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 1)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 2)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 3)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 4)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 5)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 6)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 7)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 8)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 9)
<<< Previous  | Next >>>

Tuesday Jul 01, 2014

Jini IoT Edition: Connecting the Emerging Internet of Things Silos

For those who were around in the days of Sun Microsystems, Inc., you might remember Jini technology which was a cool network architecture for distributed systems, devices and services.

Hmmm... where have we recently heard that before? Does it sound similar to... the Internet of Things (IoT)???

See:

Jini IoT Edition

Here's a quote:

 In fact, in the late 90s, Sun Microsystems 
 defined a Java-based standard called Jini - 
 which was a network architecture comprised 
 of distributed systems, devices and services. 
 Jini talked about connected devices, both in 
 the consumer space and the enterprise. In a 
 manner of speaking, Jini was a precursor of 
 the IOT, but none of the above mentioned 
 supporting technologies existed at that time 
 and due to this and few other reasons. Jini 
 never made it to mainstream.
Well, yes. Jini was the precursor to IoT. And, there's no reason why it can't come back now that today's available technology has finally caught up with the concept. A Jini IoT Edition could be the driver to connect all those disparate silos forming for the Internet of Things, everything from Google's Nest API's, to Apple's HomeKit, to AllJoyn, Belkin's WeMo, MQTT, Tesla cars, you name it! Jini IoT Edition has the chance to tie all those scattered silos together with Java API's.

It's nothing new. It's just been sitting in there on the back shelf in a bottle, waiting for the right time to come back out and show its inherent quality: bringing together devices, services, and distributed systems. It's time to let it back out of that bottle. This time, there's no going back...

Wednesday Jun 25, 2014

Java (SE Embedded Technology) Rises Again in IoT Developers Conference Summary

The Electronic Design site has a good summary of the Internet of Things Dev Conference where Java was reported being "at the center of many IoT and M2M platforms from the start". (Such as this Freescale i.MX6 Dual-based IoT Gateway which ships with Java SE Embedded directly on the device)

"Java at the center of IoT & M2M." So true. So, very true.

See:

Java Rises Again

Here's a quote:

 Actually Java has been at the center 
 of many IoT and M2M platforms from 
 the start. The movement to 32-bit 
 microcontrollers for clients make 
 it an interesting choice because 
 it provides portability...
And, the portability that Java SE Embedded technology gives is the key to IoT. That is, if you want your Apple HomeKit to talk to your Google Nest API's to talk to your Fitbit to talk to your AllJoyn network to talk to your Tesla car... It's going to be Java (once again) Embedded technology that ties it all together with standard and secure API's and protocols. Don't trust anyone else to remain neutral in tying all IoT devices and networks together.

Friday Jun 20, 2014

How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 7)

So, you've got your Parallax Single Relay Board. Next you need to connect this to your furnace, fan, and A/C control wires... and, not burn down your house in the process. Got that? Good.

Refer back to your thermostat wires. We need to connect a Relay Board to each of the control wires for the Fan, Heat call, and Cool call. Here's a reminder which wire is which.

    Red - R - 24VAC
         or
    Red - Rh - 24VAC (dedicated to heat call)
    Red - Rc - 24VAC (dedicated to cooling call)

    Green - G - Fan on
    White - W - Heat call
    Yellow - Y - Cool call
    Blue or Black - C - Common

You will need 3 Relay Boards connecting to the Raspberry Pi to control the 3 house thermostat control wires (Green for Fan, White for Heat, and Yellow for Cool). First, make sure on your Adafruit PiTFT has the 2x13 male header properly soldered on to it to daisy chain your RPi header pins (to allow your Relay Boards to connect down to the RPi). This way your Adafruit PiTFT can use the SPI pins (SCK, MOSI, MISO, CE0, CE1) plus GPIO #24 and #25 for its use, while we use GPIO #00, #01, and #04 for the Relay Boards. It's nice to share.

On each Relay Board, connect the + to the +5 VDC pin on your Adafruit PiTFT (male header pin #2). Make use of continuous jumper wires to share the one +5 VDC pin with all 3 of the Relay Boards. Then, connect the - to the GND pin (male header pin #6) using a continuous jumper wire to share this pin also. And, finally connect the S pin of one of your Relay Boards to GPIO #00 (pin #3), one S pin to GPIO #01 (pin #5), and the final S pin to GPIO #04 (pin #7).

Then connect all 3 Relay Boards Common screw down connector to the C - Common wire of your thermostat. Connect one Relay Board Normal Open (NO) screw down connector to the Green Fan wire, one NO screw down connector to the White Heat wire, and the final NO screw down connector to the Yellow Cool wire. Cool? Cool!

You are good to go for the next step!

See, not so bad still, right? ;-)

Full series of steps:
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 1)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 2)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 3)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 4)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 5)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 6)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 7)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 8)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 9)
<<< Previous  | Next >>>

Wednesday Jun 04, 2014

OpenJDK DIO Project Now Live! Java SE Embedded API Accessing Peripherals

The DIO project on OpenJDK is now live! For those who grew up in the 1970's and 1980's, you might remember Ronnie James Dio, lead singer of Black Sabbath after Ozzy was fired, and lead singer of his own band, Dio. Well, this DIO is not that Dio.

This DIO is the OpenJDK Device I/O project which provides a Java-level API for accessing generic device peripherals on embedded devices, like your Raspberry Pi running Java SE Embedded software.

See:

OpenJDK DIO Project

Here's a quote:

  + General Purpose Input/Output 
    (GPIO)
  + Inter-Integrated Circuit Bus 
    (I2C)
  + Universal Asynchronous 
    Receiver/Transmitter (UART)
  + Serial Peripheral Interface
If you're familiar with Pi4J, then you're going to like DIO. And, if you liked Ozzy, you probably liked Ronnie James Dio.

This will probably make Robert Savage happy too. The part about DIO being live now, not the part about Dio replacing Ozzy, because everyone likes Ozzy.

Friday May 30, 2014

Maker Faire Report - Teaching Kids Java SE Embedded for Internet of Things (IoT)

I had a great time at this year's Maker Faire 2014 in San Mateo, Calif. where Jake Kuramoto and the AppsLab crew including Noel Portugal, Anthony Lai, Raymond, and Tony set up a super demo at the DiY table. It was a simple way to learn how Java SE Embedded technology could be used to code the Internet of Things (IoT) devices on the table.

The best part of our set-up was seeing the kids sit down and do some coding without all the complexity of a Computer Science course. It was very encouraging to see how interested the kids were when walking them through the programming steps, then seeing their eyes light up when telling them, "You just coded a Java enabled Internet of Things device!" as the Raspberry Pi-connected devices turned on or started to move from their Java Embedded program.

See:

The AppsLab at Maker Faire

It will be interesting to see how this next generation of kids grow up with all these Internet of Things devices around them and watch how they will program them. Hopefully, they will be using Java SE Embedded technology to do so. From the looks of it at this year's Maker Faire, we might have a bunch of motivated young Java SE Embedded coders coming up the ranks soon. Well, they have to get through middle school first, but they're on their way! ;-)

Wednesday May 14, 2014

Maker Faire 2014 - Java Technology and IoT come together

Make sure to come out to the Maker Faire 2014 this year at the San Mateo Event Center on May 17 & 18. It will be a weekend full of fun and high tech toys. Plus, come see our Java SE Embedded technology demos on the Raspberry Pi!

Jake, Noel Portugal, and the Oracle AppsLab did a great job on the DiY table, and Vinicius will show cool stuff on the IoT Panel wall. Plus, come meet other Java Embedded technology makers who will be staffing our Oracle Java Embedded Technology area.

See:

Maker Faire 2014

Here's a quote:

 Meet the Makers
 ---
 Explore makers and projects 
 coming to Bay Area Maker 
 Faire.
It'll be a good time for the whole family! So, come out and enjoy the (cooler) weather and a nice day playing with technology, crafts and talk with the people who make them.

Sunday May 11, 2014

How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 6)

After showing how to connect the LCD Touchscreen from adafruit in Part 5 for this Java SE Embedded thermostat project, I figured out a simpler solution for the relays needed to turn on and off the furnace, fan, and A/C of a home heating and cooling system (just like the Nest thermostat).

So, it's time to show how to do a time-honored tradition in high tech start-up prototyping: Refactoring.

I found this cool Single Relay Board from Parallax. It can control up to 120VAC at 10 amps, but we only need to control 24VAC 1 amp relays for the home furnace, fan, and A/C. And most importantly, this Single Relay Board can take a 3.3 VDC signal from a microcontroller or Raspberry Pi running the Java SE Embedded platform (like we are doing in the project). No need for SPI or i2c, just a straight GPIO high value (3.3VDC) from the Raspberry Pi header pins from a Java SE Embedded app will control the relays. Cool!

So, I've got a bit of refactoring to do of my previous blog posts to swap in 3 of these Single Relay Boards (go ahead and order 3 if you are playing along at home). But, it's all good. Refactoring is part of the process of high tech start-up prototyping, right? :-)

Full series of steps:
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 1)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 2)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 3)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 4)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 5)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 6)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 7)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 8)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 9)
<<< Previous  | Next >>>

Tuesday Apr 29, 2014

Oracle Java SE Embedded India job openings, hot-hot-hot opportunities!

If you live in India and you're looking for an opportunity to work on the latest Java Embedded technology, we have some hot job openings on our team. We are currently planning some pretty cool projects that you would work on!

See Java Technology Jobs at Oracle:

Req IRC2495741

Req IRC2495743

Req IRC2495744

See also the LinkedIn Job Posting

So, check it out. You'll get the opportunity to program Java devices, work on cutting edge embedded platforms, and a get an opportunity to blog about it at the Oracle blog site. Won't that be fun? :) I think so. ;-)

Thursday Apr 10, 2014

What's on my Java SE Embedded enabled desk at work?

If you ever wondered what I have on my messy Java SE Embedded technology-enabled desk in my office, here's you chance to see. Check out Vinicius Senger's video interview of me explaining the Internet of Things (IoT) devices on my desk.

See:

My Messy Desk with Java SE Embedded

Maybe I should have straightened out my desk better!

Oh, well... Nothing like having company over to see how messy your stuff is. ;-)

Tuesday Apr 01, 2014

Oracle IoT Device to Translate Cat Meows: Java SE Embedded on Raspberry Pi

Here's a new Oracle Internet of Things (IoT) Device that translates cat meows into readable text. You just need a Raspberry Pi device, a USB connected mic, and Java SE Embedded technology to program the meow-to-text recognition software using cloud-based, kitty-crowd-sourced, big data to do the translations.

The inventor here at Oracle was quoted as saying:

 "I was watching my cat the other day,
  and I thought, 'I wonder what my cat is 
  thinking...  If there were only a way to 
  use an IoT device to translate my cat's 
  thoughts and meows into human readable
  text.'". "A couple days later, I had a 
  prototype with parts from old stereo 
  equipment and a Raspberry Pi, and now, 
  nine months later, I have a $350 billion 
  startup company."
Thus was born the Oracle IoT Cat Meowerator, a next-generation automated cat translation device that taps into millions of cat meows stored over the web on an Oracle cloud database to deliver carefully translated meow-to-text conversions to your device.

The device, now available on Amazon.com for $299.99, includes a mic, a stuffed bird toy with catnip, meaty treats, and a Raspberry Pi controller board. It uses a Realtek 802.11b/g/n controller to link to the Internet over a home WiFi net like another access point and Java SE Embedded technology to let you know, "April Fools!".

Wednesday Mar 19, 2014

EclipseCon2014, slides for "Java SE Embedded 8 Compact Profiles"

Here are my slides from the recent EclipseCon 2014 conference on the topic of Java SE Embedded 8 Compact Profiles.

Download Link:

Click here to view slides in full window

It was fun to present this talk at EclipseCon 2014. If you attended the talk, thanks from coming by!

Friday Mar 14, 2014

How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 5)

We now have power to your Raspberry Pi. Next, we need to hook up the cool LCD Touchscreen from adafruit.com so that your Java SE Embedded thermostat app will have a UI. Lady Ada has some rockin' cool gear for your Raspberry Pi at her Web site!

See the cool video demo of the TFT touchscreen below:

To hook up her LCD Touchscreen to your RPi so that your Java SE Embedded app can use it, just follow these two sets of instructions from adafruit.com.

First do the assembly: TFT touchscreen assembly

Next do the software installation: TFT touchscreen software

That's it for this part. You can also check out the other steps at the adafruit.com Web site for screen calibration and other optional set-up steps. But, with the above minimal steps you now have a working touchscreen.

Next up, we will connect the PiFace for the relays needed to turn on and off your furnace and A/C via a Java SE Embedded app. That's when the stuff gets real... Or, sparks fly... One, or the other. :-)

Full series of steps:
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 1)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 2)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 3)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 4)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 5)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 6)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 7)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 8)
How to Build Your Own $3.2bln Nest Startup Using Java SE Embedded Tech (Part 9)
<<< Previous  | Next >>>

About

Hinkmond Wong's blog on making the Internet of Things (IoT) smarter with Java Technologies

Search

Archives
« March 2015
SunMonTueWedThuFriSat
1
2
3
4
5
6
7
8
10
11
12
14
15
16
17
18
19
20
21
22
25
26
27
28
29
30
31
    
       
Today