Weather board for SHOW.

Moderators: mdrjr, odroid

Re: Weather board for SHOW.

Unread postby usee » Wed Jan 07, 2015 6:04 am

One get this UnsatisfiedLinkError error, if native libraries are not correctly referenced.
I have been practicing on ODROIDs in Lubuntu and in Debian and explain how I was doing library referencing with an IDE.

Are you working on an X86 machine with Linux?

So, can you check, whether there are pre installed java libraries RXTcomm-2.2pre2.jar
and RXTcomm.jar in /usr/share/java folder
and native libraries in /usr/lib/jni? If they are not there and you are working on Ubuntu or
Debian, you can issue
sudo apt-get install librxtx-java
and after that the libraries should be there. Then you can reference to those folders.
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 9:01 am

I see two versions of them.
/usr/share/java/RXTXcomm-2.2pre2.jar
/usr/share/java/RXTXcomm.jar
/usr/lib/jni/librxtxSerial.so
/usr/lib/jni/librxtxSerial-2.2pre1.so
/usr/lib/jni/librxtxParallel.so
/usr/lib/jni/librxtxParallel-2.2pre1.so
Which one should I copy to
/usr/lib/jvm/java-8-oracle/jre/lib/arm/
and
/usr/lib/jvm/java-8-oracle/jre/lib/ext/
Thank you for your help!
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 10:14 am

I copied those files to
/usr/lib/jvm/java-8-oracle/jre/lib/arm/
/usr/lib/jvm/java-8-oracle/jre/lib/ext/
This time I get no error when I run PortFinder, but it just hangs forever.
It looks like it hangs during
Enumeration ports = CommPortIdentifier.getPortIdentifiers();
I can't even press ctrl+c to stop.
Any suggestion?
Thanks,
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 1:57 pm

I tried to run the program on Windows, and I only got
"content=Welcome to the ODROID-SHOW"
How do I pull the data from the weather board?
Thanks,
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby usee » Wed Jan 07, 2015 3:30 pm

Ok, you are using Windows on an X86?
I quess, that blocking meas that somehow the program does not have privilege to
open serial port. Though, this is not logical, because a Windows Administrator has always all rights.
Maybe the serial port name is different in Windows, is it com + something?
In Linux use a port name has been dev/ttyUSB0 or /dev/ttyUSB1.
I have not practiced in WIndows (yet), so I propose that you search the Internet.
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby usee » Wed Jan 07, 2015 3:34 pm

In Ubuntu or Debian one can add user to dialout group to get rights to read port, see
sudo adduser <user> dialout
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby usee » Wed Jan 07, 2015 4:20 pm

One must reboot after adding user to dialout group.
Serial port reading starts working only after reboot. (is it really so, isn't it?)
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 7:45 pm

usee, thank you so much for helping with this.
It looks like it has access to show2 though since I get "content=Welcome to the ODROID-SHOW".
If it has no access, I would get nothing, right?
I think it can't read data from weatherboard.
Yes, I'm using "COM3" as the identifier on Windows.
I also tried to connect with putty, and I only got "Welcome to the ODROID-SHOW"

usee wrote:Ok, you are using Windows on an X86?
I quess, that blocking meas that somehow the program does not have privilege to
open serial port. Though, this is not logical, because a Windows Administrator has always all rights.
Maybe the serial port name is different in Windows, is it com + something?
In Linux use a port name has been dev/ttyUSB0 or /dev/ttyUSB1.
I have not practiced in WIndows (yet), so I propose that you search the Internet.
Last edited by jl303 on Wed Jan 07, 2015 8:34 pm, edited 1 time in total.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 8:06 pm

Does the C1 Ubuntu image comes with the driver for show2, or do I need to download?
As far as hardware goes, do I need to do anything other than plugging the weatherboard to the show2 and connectting c1 and show2 with USB cable?
It looks like I'm already part of dialout.
id -Gn |grep dialout
odroid adm dialout fax cdrom floppy tape sudo audio dip video plugdev netdev nop asswdlogin lpadmin scanner fuse
Here's ls-l /dev
crw-rw---- 1 root dialout 188, 0 Jan 7 21:30 /dev/ttyUSB0
crw-rw---- 1 root dialout 4, 66 Jan 7 21:29 /dev/ttyS2
crw-rw---- 1 root dialout 4, 65 Jan 7 21:29 /dev/ttyS1
I get nothing if I run screen.
screen /dev/ttyUSB0 500000


usee wrote:One must reboot after adding user to dialout group.
Serial port reading starts working only after reboot. (is it really so, isn't it?)
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Wed Jan 07, 2015 8:33 pm

/dev/ttyUSB0 must be the ODROID-SHOW/SHOW2.

Plug/Unplug the show and check the existance of /dev/ttyUSB0

We will try it tomorrow.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 8:36 pm

/dev/USB0 goes away if I unplug show2.
odroid wrote:/dev/ttyUSB0 must be the ODROID-SHOW/SHOW2.

Plug/Unplug the show and check the existance of /dev/ttyUSB0

We will try it tomorrow.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Wed Jan 07, 2015 8:37 pm

It means the Show driver is working.
We will chck the functionality tomorrow.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby jl303 » Wed Jan 07, 2015 9:07 pm

That's good, but I get nothing if I run
screen /dev/ttyUSB0 500000
If I connect it to the Windows and use putty, I get the welcome message.
After that nothing from weatherboard.
I guess we'll troubleshoot one at a time.
Thanks,
odroid wrote:It means the Show driver is working.
We will chck the functionality tomorrow.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Thu Jan 08, 2015 12:11 am

Does weather board need its own power, or can it draw power from show2 through micro usb?
Trying to see if there's any simple stupid thing I'm missing.
Here are the steps I took.
flashed the emmc with the latest c1 image.
Attached the emmc and rtc battery to c1.
Connected weatherboard to shows2 with 6-pin.
Connected show2 and wifi4 module to c1 through usb, and connected a monitor with mini hdmi.
Boot and connect to my Wifi.
Run odroid utility to resize the partition and upgrade the firmware.
Reboot and when to terminal.
Try to connect to show2 using
sudo screen /dev/ttyUSB0 500000
Put the password for root.
Nothing happens.
Am I missing any simple step here?
Thanks,
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Thu Jan 08, 2015 12:52 am

The weather board doens't need extra power source.
It takes the power from SHOW/SHOW2.
Your procedure looks okay.

We will try it and get back to you tomorrow.
It is already 1:00 AM in Korea.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby usee » Thu Jan 08, 2015 1:24 am

In the second place, after first putting sofware into to the microcontroller,
it is reasonable to verify the USB functionality with the Qt based application, see
http://odroid.com/dokuwiki/doku.php?id= ... rboard_app
If that works, one can also assume that Java based reading should work.
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Thu Jan 08, 2015 4:51 am

Thanks,
If I connect the show2 windows device, and connect to it using putty,
I get "Welcome to the ODROID-SHOW".
Then if I type things on putty, it comes up on the show2 display.
Also if I press reset button on show2, I get "Welcome to the ODROID-SHOW" on the putty again.
However, still no weatherboard messages.
Do I need to put some command in order to pull weatherboard data?
What about those three switches on show2 that says pd7, pc0, pc1? It doesn't seem to do anything if I press them.
Also, there's a jumper covering two pins next to the usb connecter. Do I need to do anything with that?
Thanks again for all your help.
Getting closer...

odroid wrote:The weather board doens't need extra power source.
It takes the power from SHOW/SHOW2.
Your procedure looks okay.

We will try it and get back to you tomorrow.
It is already 1:00 AM in Korea.
Last edited by jl303 on Thu Jan 08, 2015 5:08 am, edited 1 time in total.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Thu Jan 08, 2015 5:01 am

Thanks usee for the suggestion.
I tried the qt app, but unfortunately everything shows as 0, and nothing changes.

usee wrote:In the second place, after first putting sofware into to the microcontroller,
it is reasonable to verify the USB functionality with the Qt based application, see
http://odroid.com/dokuwiki/doku.php?id= ... rboard_app
If that works, one can also assume that Java based reading should work.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Thu Jan 08, 2015 2:09 pm

Just run minicom on C1 and set the parameters 500000bps N81 without flow-control option.
I've just confirmed it works.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby jl303 » Thu Jan 08, 2015 8:49 pm

Thanks for confirming, but nothing happens.
I'm thinking that I received a defective unit.
However, I'm not sure what is defective. C1, show2, or weatherboard.
1. It seems like I can use show2 on Windows, but I can't pull any data from weatherboard.
2. I can't even connect to show2 on c1.

odroid wrote:Just run minicom on C1 and set the parameters 500000bps N81 without flow-control option.
I've just confirmed it works.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Thu Jan 08, 2015 9:13 pm

Try below guide and let me know the result first.
http://odroid.com/dokuwiki/doku.php?id=en:show_using

Note that you must write a proper firmware to enable the weather board function as described in WiKi.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby usee » Thu Jan 08, 2015 11:19 pm

The first thing to do [EDITED version, see the jumper]

for me was to follow the guideline of this link:
http://odroid.com/dokuwiki/doku.php?id= ... rd_setting
There one
- loads ODROID-SHOW software from git
- install ANDRUINO if it is not already installed (sudo apt-get install arduino)
- start arduino IDE and load ODROID-SHOW library
- assemble weather board to show board and connect it to host with usb cable
- put black jumper on
- compile and upload sw library into board
- put black jumper back to off
And the thing is ready to go.

My show board is REV 0.1.
Last edited by usee on Fri Jan 09, 2015 6:10 am, edited 1 time in total.
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 09, 2015 4:00 am

When I tried to upload, I keep getting not in sync error, and it go through 10 of them and finally gives up.
The guide said "Finally after connecting the jumper, click “upload” button of arduino IDE after click Verify button or “Ctrl + R”."
Usee said take off the jumper and upload and put it back.
I tried both, but I can't get it to work.
Which way is correct do you upload while the jumper is covering the two pins or not?
Thanks,
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby usee » Fri Jan 09, 2015 6:08 am

Thank you @jl303. I have understood the jumper position incorrectly!
Now I have changed my jumper to off and the board works better.
With jumper on the was such side effect that each time when a Java program opened
the /dev/ttyUSB0, the show board was reset. The rest also happened when in ADRUINO IDE
mouse was hovered over Tools->Serial Port -> /dev/ttyUSB0 selection. So, I will try to edit y previous post
and then mark it as edited. Now, when jumper is off, the port can be opened without booting the TFT.

Anyway, you have tried to download both ways, jumper on and off, and it seems not to work.
Hmm, ..., just report the symptoms, maybe the correct solution will be found ...
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 09, 2015 6:59 am

I keep getting this:
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x01

usee wrote:Thank you @jl303. I have understood the jumper position incorrectly!
Now I have changed my jumper to off and the board works better.
With jumper on the was such side effect that each time when a Java program opened
the /dev/ttyUSB0, the show board was reset. The rest also happened when in ADRUINO IDE
mouse was hovered over Tools->Serial Port -> /dev/ttyUSB0 selection. So, I will try to edit y previous post
and then mark it as edited. Now, when jumper is off, the port can be opened without booting the TFT.

Anyway, you have tried to download both ways, jumper on and off, and it seems not to work.
Hmm, ..., just report the symptoms, maybe the correct solution will be found ...
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 09, 2015 7:48 am

Which board do I need to select in tools - board?
Uno is selected as default.


jl303 wrote:I keep getting this:
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x01
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x01

usee wrote:Thank you @jl303. I have understood the jumper position incorrectly!
Now I have changed my jumper to off and the board works better.
With jumper on the was such side effect that each time when a Java program opened
the /dev/ttyUSB0, the show board was reset. The rest also happened when in ADRUINO IDE
mouse was hovered over Tools->Serial Port -> /dev/ttyUSB0 selection. So, I will try to edit y previous post
and then mark it as edited. Now, when jumper is off, the port can be opened without booting the TFT.

Anyway, you have tried to download both ways, jumper on and off, and it seems not to work.
Hmm, ..., just report the symptoms, maybe the correct solution will be found ...
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 09, 2015 8:06 am

How do I check if my show2 has bootloader?
viewtopic.php?f=88&t=6098
It seems like other people are having the same problem?
Thanks,
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby usee » Fri Jan 09, 2015 8:42 am

Can you try different baud rates in Adruino Tools->Serial Monitor?
Attachments
Adruino-dev-ttyUSB0.png
Adruino-dev-ttyUSB0.png (10.5 KiB) Viewed 2978 times
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 09, 2015 9:25 am

I already tried that. No luck.

usee wrote:Can you try different baud rates in Adruino Tools->Serial Monitor?
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby odroid » Fri Jan 09, 2015 11:28 am

The Jumper should be installed for the Arduino IDE.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 16, 2015 9:21 am

Yea! Finally I received the replacement.
I was able to upload Weatherboard to show2, and I got it to work on Windows!
Usee, do you have an idea why the java program can't stream the data continuously? It stops after the first set of data.
If I just stream the raw data with InputStreamReader, and the data keeps coming.
Maybe something has to do with how Scanner is implemented?
Thanks,


odroid wrote:The Jumper should be installed for the Arduino IDE.
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby jl303 » Fri Jan 16, 2015 2:37 pm

Since my weatherboard is working on my Windows, I'm trying to get it to work on c1 with Java.
When I first run, it hangs at
CommPortIdentifier portIdentifier = CommPortIdentifier.getPortIdentifier( portName );
However, if I open another terminal window and run the same program, I get
RXTX fhs_lock() Error: creating lock file: /var/lock/LCK..ttyS4: File exists
Welcome to the WEATHER-BOARD
w019.7011013.18297.74318.72421.1850.09637080.00019.7011013.16297.91318.72421.165
0.02637080.00019.7011013.21297.49318.71421.1750.00617080.00019.7011013.12298.243
18.74421.1850.01627080.00019.7011013.17297.82318.72421.1650.08677080.00019.70110
13.20297.57318.70421.1650.03637080.00019.7011013.21297.49318.72421.1750.06667080
.00
.....
It hangs at first run, but it kind of works with an error after the first run...
Also, when I run this on windows, I get w before each number. However, if I run the same program on c1, I get just all the numbers without any separation.
Very strange...
jl303
 
Posts: 53
Joined: Wed Dec 31, 2014 12:08 am
languages_spoken: english

Re: Weather board for SHOW.

Unread postby usee » Sat Jan 17, 2015 3:41 pm

So you got it working on Windows. If you have some other Linux box than C1, it will work?
I had various 'features', when the black jumper was on, while reading /dev/ttyUSB0 with Java.
Then the microcontroller was booted each time when serial port was opened.
The jumper need to be on only when a sketch is written into the board. After that the jumper must be off.
The data should be delimiter with 'w', like you say, the next number 1 to 7 tells, which sensor value is next.
But currently I have show 1 and U3 and XU3, but not C1.
usee
 
Posts: 113
Joined: Thu Sep 26, 2013 4:28 am
languages_spoken: english
ODROIDs: ODROID-XU, U3, XU3, C1, Weather board, show1

Re: Weather board for SHOW.

Unread postby bournej » Fri Jul 14, 2017 4:09 am

Hey has anybody had similar issues in the time response of the sensor, specifically humidity?
https://forum.odroid.com/viewtopic.php?f=142&t=27295
bournej
 
Posts: 6
Joined: Thu Aug 04, 2016 3:55 am
languages_spoken: english
ODROIDs: c2

Re: Weather board for SHOW.

Unread postby odroid » Fri Jul 14, 2017 1:16 pm

Answered on your thread.
User avatar
odroid
Site Admin
 
Posts: 23623
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English
ODROIDs: ODROID

Re: Weather board for SHOW.

Unread postby Meremortal » Mon Jul 17, 2017 4:27 pm

This really looks like an amazing little board. Just wondering has anyone got this working using NODE RED on a RPi?
Meremortal
 
Posts: 1
Joined: Mon Jul 17, 2017 4:24 pm
languages_spoken: english

Previous

Return to SHOW

Who is online

Users browsing this forum: No registered users and 1 guest