Author Topic: Pi/Base Moteino problem  (Read 4884 times)

griiker

  • NewMember
  • *
  • Posts: 15
Pi/Base Moteino problem
« on: December 10, 2018, 10:39:42 PM »
Hi:

Im having trouble with my Pi and gateway Moteino.  I am new at this, and have had trouble understanding the instruction with programing the Moteino and raspberry Pi.  I have them programmed, however, I can't seem to get them to work, and I have no Idea what to do next.

I am able to get the Pi Gateway to open through the IP adress in my web browser (Mozilla Firefox), however,  there aren't any nodes.  The LED next to the A2 will light for a couple of seconds, then blink off, and the TX/RX LED will blink a bit then go dark.  I am certain the correct sketches are properly loaded, and the gateway to  Moteino serial is set to /dev/ttyUSB0.  (The instructions were not clear on what number I should use after the "USB" so i put 0.

any ideas?

HeneryH

  • Full Member
  • ***
  • Posts: 229
Re: Pi/Base Moteino problem
« Reply #1 on: December 11, 2018, 07:40:20 AM »
I've built a few systems and there is always a little bit of voodoo magic that need to happen to get the gateway to register new nodes.

It all comes down to whether the gateway Mote is communicating with the device Motes and whether the gateway Mote is successfully sending its messages to the gateway.js server via the serial port. [edit - oops, I see that you are using USB rather than serial]

Some of the voodoo magic for me is just getting the serial port set up correctly than making sure the web configuration has the right baud rates.
« Last Edit: December 11, 2018, 08:09:16 AM by HeneryH »

sparky

  • Sr. Member
  • ****
  • Posts: 296
  • Country: us
Re: Pi/Base Moteino problem
« Reply #2 on: December 11, 2018, 07:52:41 AM »
@griiker,

Run the following command to see what port the USB is on;

Code: [Select]
Dmesg | grep ttyUSB

Are you using the PiGateway sketch?   What type of node(s) do you have installed?

griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #3 on: December 11, 2018, 08:15:27 PM »
Code: [Select]
Dmesg | grep ttyUSB

got me this:

bash: Dmesg: command not found.

I'm trying to connect a garagemote.


TomWS

  • Hero Member
  • *****
  • Posts: 1930
Re: Pi/Base Moteino problem
« Reply #4 on: December 11, 2018, 08:22:15 PM »
Lower case 'dmesg'...

griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #5 on: December 11, 2018, 08:46:03 PM »
did lower case

got bash: dmesg: command not found

griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #6 on: December 11, 2018, 08:48:09 PM »
BTW I've got the PiGateway sketch running

sparky

  • Sr. Member
  • ****
  • Posts: 296
  • Country: us
Re: Pi/Base Moteino problem
« Reply #7 on: December 11, 2018, 09:04:07 PM »
Sorry I didn't catch that typo.. 

So with the GarageMote you will probably have to go out and cycle the door garage door open or closed or go to terminal and send a OPN or CLS message to that node before you see it in the Dashboard.

sparky

  • Sr. Member
  • ****
  • Posts: 296
  • Country: us
Re: Pi/Base Moteino problem
« Reply #8 on: December 11, 2018, 09:05:32 PM »
did lower case

got bash: dmesg: command not found

Did you use caps  for USB?

« Last Edit: December 11, 2018, 09:16:35 PM by sparky »

griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #9 on: December 11, 2018, 09:12:45 PM »
I tried using caps for USB, didnt work the first time, but now I got:

[   3.192780} usb 1-1.5: FTDI USB Serial Device converter now attached to ttyUSB0.

However, I also have a mouse plugged into a USB port

I'm asssuming the "FTDI" indicates it is refering to the Moteino, is this correct?



griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #10 on: December 11, 2018, 09:17:38 PM »
I haven't installed the hard ware yet, just simulating by moving magnets close to the Hall Effect Devices.  They are showing a response in the Arduino  serial monitor, so I know that the sketch is properly installed in the garage mote.  but I do not see anything in the web site.

Jason

  • Jr. Member
  • **
  • Posts: 57
Re: Pi/Base Moteino problem
« Reply #11 on: December 11, 2018, 09:30:34 PM »
1. Is the network ID on the moteino and the garage mote?
2. Is the device ID for the moteino connected to the gateway: 1?
3. Is the device ID for the garage mote not one, like 2?
4. Same encryption key for both?

Jason

  • Jr. Member
  • **
  • Posts: 57
Re: Pi/Base Moteino problem
« Reply #12 on: December 11, 2018, 09:34:17 PM »
Hi again, Do you mean to say that the moteino connected to the pi is receiving data from the garage mote, visible on an arduino also viewing the moteino serial port?

Jason

  • Jr. Member
  • **
  • Posts: 57
Re: Pi/Base Moteino problem
« Reply #13 on: December 11, 2018, 09:39:20 PM »
Also: How is the moteino connected to the raspberry pi? What pins?

griiker

  • NewMember
  • *
  • Posts: 15
Re: Pi/Base Moteino problem
« Reply #14 on: December 11, 2018, 11:15:22 PM »
Hi again, Do you mean to say that the moteino connected to the pi is receiving data from the garage mote, visible on an arduino also viewing the moteino serial port?

I do not know if the moteino connected to the raspberry pi is receiving
 any data from the garage mote. how can I check for that?  there must be a way I can do that through the raspberry pi itself.

When I connect the garagemote with moteino, I test the relay, and it works.  when I hold the magnet close to the Hall effect device,  I get door open/closed depending on which HED I hold it to. 


in other words, I am checking the performance of the garage moteino by connecting it to a computer runing the arduino IDE/ serial monitor, not through Raspberry Pi.

Right now, I am getting the IoT Dashboard screen, but now it shows this message:

 " Waiting for socket connection.. "