GithubHelp home page GithubHelp logo

Comments (13)

mojtaba-esk avatar mojtaba-esk commented on September 14, 2024 1

I had the same issue, I could resolve it by resetting the CE0 and RESET pin before running the forwarder. Here is how i did it:


echo "Restarting the CE0 pin..."
CSPIN=8
echo "$CSPIN" > /sys/class/gpio/export
sleep 1
echo "out" > /sys/class/gpio/gpio$CSPIN/direction
echo "0" > /sys/class/gpio/gpio$CSPIN/value
sleep 1
echo "1" > /sys/class/gpio/gpio$CSPIN/value
echo "Done\n"
sleep 1

echo "Restarting the Concentrator..."
RSTPIN=17
echo "$RSTPIN" > /sys/class/gpio/export
sleep 1
echo "out" > /sys/class/gpio/gpio$RSTPIN/direction
echo "1" > /sys/class/gpio/gpio$RSTPIN/value
sleep 1
echo "0" > /sys/class/gpio/gpio$RSTPIN/value
echo "Done\nLaunching the forwarder..."
sleep 2

cd /PATH_TO_THE_GATEWAY_CODES/packet_forwarder/ && ./lora_pkt_fwd

Save this code in a shell file, change the path according to your own settings and make sure to run it with sudo
The full article can be found here

from ic880a-gateway.

gonzalocasas avatar gonzalocasas commented on September 14, 2024

mmmm... hard to tell, maybe a silly question but, did you check if SPI is enabled?

from ic880a-gateway.

safurniss avatar safurniss commented on September 14, 2024

Hi, yes SPI is enabled....... I have just swapped the Pi2 for a different Pi2 and did a fresh install using the local file not the remote file that was used in the previous install.... all is now working correctly.....

I've submitted a new remote .json file for the new Pi2 and will look at restarting once it has been committed to the repository to see if it was anything to do with that.... also will look at testing the other Pi2 that I couldn't get it working on to see if that was the problem.

from ic880a-gateway.

gonzalocasas avatar gonzalocasas commented on September 14, 2024

from ic880a-gateway.

MartinLavicka avatar MartinLavicka commented on September 14, 2024

I connected reset (pin13) to pin11 on Raspberry pi 3 (GPIO0).
edit: The wires were badly connected.

from ic880a-gateway.

gonzalocasas avatar gonzalocasas commented on September 14, 2024

@MartinLavicka why? Unless you want to manually change the installer, the instructions indicate using pin 22 for reset (BCM 25): https://github.com/ttn-zh/ic880a-gateway/wiki

from ic880a-gateway.

Outfardine avatar Outfardine commented on September 14, 2024

hi @safurniss, please i'm dealing with the same problem. can you tell me what should i do ?!

from ic880a-gateway.

gonzalocasas avatar gonzalocasas commented on September 14, 2024

This error message only says that the Raspberry Pi cannot connect to the concentrator board, you have to provide additional details to understand what is your concrete problem. Maybe SPI is disabled, maybe your power supply is too weak for the boards, maybe you selected remote config but didn't have the remote config file pushed to the repository....

from ic880a-gateway.

Outfardine avatar Outfardine commented on September 14, 2024

from ic880a-gateway.

Taher1322 avatar Taher1322 commented on September 14, 2024

This error message only says that the Raspberry Pi cannot connect to the concentrator board, you have to provide additional details to understand what is your concrete problem. Maybe SPI is disabled, maybe your power supply is too weak for the boards, maybe you selected remote config but didn't have the remote config file pushed to the repository....

I am using 5V,1.6A adapter, my remote config file is pushed to the repository, I have edited the reset code into my start.sh file, my SPI is enabled as well.

#! /bin/bash

Reset iC880a PIN

SX1301_RESET_BOARD_PIN=22
echo "$SX1301_RESET_BOARD_PIN_22" > /sys/class/gpio/export
echo "out" > /sys/class/gpio/gpio$SX1301_RESET_BOARD_PIN_22/direction
echo "0" > /sys/class/gpio/gpio$SX1301_RESET_BOARD_PIN_22/value
sleep 0.1
echo "1" > /sys/class/gpio/gpio$SX1301_RESET_BOARD_PIN_22/value
sleep 0.1
echo "0" > /sys/class/gpio/gpio$SX1301_RESET_BOARD_PIN_22/value
sleep 0.1
echo "$SX1301_RESET_BOARD_PIN_22" > /sys/class/gpio/unexport

Test the connection, wait if needed.

After restating it, and checking the gateway status by running
sudo service ttn-gateway status

I get
● ttn-gateway.service - The Things Network Gateway
Loaded: loaded (/lib/systemd/system/ttn-gateway.service; enabled; vendor pres
Active: active (running) since Tue 2019-01-08 09:40:48 GMT; 1s ago
Main PID: 1610 (start.sh)
CGroup: /system.slice/ttn-gateway.service
├─1610 /bin/bash /opt/ttn-gateway/bin/start.sh
├─1614 git pull
├─1615 git fetch --update-head-ok
└─1616 git-remote-https origin https://github.com/ttn-zh/gateway-remo

Jan 08 09:40:48 ttn-gateway systemd[1]: Started The Things Network Gateway.
Jan 08 09:40:48 ttn-gateway ttn-gateway[1610]: /opt/ttn-gateway/gateway-remote-c
lines 1-12/12 (END)

When i run sudo tail -f /var/log/syslog

I get failed to connect to concentrator.

the status on ttn i still non connected.

Please help me with this issue..

from ic880a-gateway.

waynemcl avatar waynemcl commented on September 14, 2024

Is the line "Feb 14 22:12:29 ttn-gateway ttn-gateway[5333]: INFO: local_conf.json does not contain a JSON object named SX1301_conf" an issue for you?

from ic880a-gateway.

alexxtasi avatar alexxtasi commented on September 14, 2024

Hi all
same problem with my gateway...

  • having followed the instructions
  • having SPI enabled
  • running sudo ./install.sh spi
  • I don't use a remote setting file so I provide hostname etc, answering script's questions
    the script perform RPi restart and after that, the ttn-gateway.service results in :
● ttn-gateway.service - The Things Network Gateway
   Loaded: loaded (/lib/systemd/system/ttn-gateway.service; enabled; vendor preset: enabled)
   Active: activating (auto-restart) (Result: exit-code) since Thu 2019-05-23 23:26:05 EEST; 3s ago
  Process: 5393 ExecStart=/opt/ttn-gateway/bin/start.sh (code=exited, status=1/FAILURE)
 Main PID: 5393 (code=exited, status=1/FAILURE)

May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: Beacon is disabled
May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: Monitor is disabled
May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: Contact email configured to "my@email"
May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: Description configured to "customHostname"
May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: Successfully contacted server router.eu.thethings.network
May 23 23:26:05 customHostname ttn-gateway[5393]: INFO: [main] Starting the concentrator
May 23 23:26:05 customHostname ttn-gateway[5393]: ERROR: [main] failed to start the concentrator
May 23 23:26:05 customHostname systemd[1]: ttn-gateway.service: Main process exited, code=exited, status=1/FAILURE
May 23 23:26:05 customHostname systemd[1]: ttn-gateway.service: Unit entered failed state.
May 23 23:26:05 customHostname systemd[1]: ttn-gateway.service: Failed with result 'exit-code'.

this comes again and again after restarting the service or even RPi !!!

/var/log/syslog shows :

May 23 23:18:01 customHostname systemd[1]: ttn-gateway.service: Service hold-off time over, scheduling restart.
May 23 23:18:01 customHostname systemd[1]: Stopped The Things Network Gateway.
May 23 23:18:01 customHostname systemd[1]: Started The Things Network Gateway.
May 23 23:18:01 customHostname ttn-gateway[3505]: *** Poly Packet Forwarder for Lora Gateway ***
May 23 23:18:01 customHostname ttn-gateway[3505]: Version: 2.1.0
May 23 23:18:01 customHostname ttn-gateway[3505]: *** Lora concentrator HAL library version info ***
May 23 23:18:01 customHostname ttn-gateway[3505]: Version: 3.1.0; Options: native;
May 23 23:18:01 customHostname ttn-gateway[3505]: ***
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Little endian host
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: found global configuration file global_conf.json, parsing it
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: global_conf.json does contain a JSON object named SX1301_conf, parsing SX1301 parameters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: lorawan_public 1, clksrc 1
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Configuring TX LUT with 16 indexes
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: radio 0 enabled (type SX1257), center frequency 867500000, RSSI offset -166.000000, tx enabled 1
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: radio 1 enabled (type SX1257), center frequency 868500000, RSSI offset -166.000000, tx enabled 0
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 0>  radio 1, IF -400000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 1>  radio 1, IF -200000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 2>  radio 1, IF 0 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 3>  radio 0, IF -400000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 4>  radio 0, IF -200000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 5>  radio 0, IF 0 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 6>  radio 0, IF 200000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora multi-SF channel 7>  radio 0, IF 400000 Hz, 125 kHz bw, SF 7 to 12
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Lora std channel> radio 1, IF -200000 Hz, 250000 Hz bw, SF 7
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: FSK channel> radio 1, IF 300000 Hz, 125000 Hz bw, 50000 bps datarate
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: global_conf.json does contain a JSON object named gateway_conf, parsing gateway parameters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: gateway MAC address is configured to AA555A0000000000
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Found 2 servers in array.
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Server 0 configured to "127.0.0.1", with port up "1680" and port down "1681"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Server 1 configured to "iot.semtech.com", with port up "1680" and port down "1680"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Found 5 system calls in array.
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: System command 0: "df -m"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: System command 1: "free -h"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: System command 2: "uptime"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: System command 3: "who -a"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: System command 4: "uname -a"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: monitor hostname or IP address is configured to "127.0.0.1"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: monitor port is configured to "2008"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: ghost hostname or IP address is configured to "127.0.0.1"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: ghost port is configured to "1918"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: downstream keep-alive interval is configured to 10 seconds
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: statistics display interval is configured to 30 seconds
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: upstream PUSH_DATA time-out is configured to 100 ms
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with a valid CRC will be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with a CRC error will NOT be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with no CRC will NOT be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: GPS serial port path is configured to "/dev/ttyAMA0"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: SSH path is configured to "/usr/bin/ssh"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: SSH port is configured to 22
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: HTTP port is configured to 80
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: NGROK path is configured to "/usr/bin/ngrok"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference latitude is configured to 10.000000 deg
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference longitude is configured to 20.000000 deg
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference altitude is configured to -1 meters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: GPS is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Using fake GPS coordinates instead of real.
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: antenna_gain 0 dBi
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Upstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Downstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Ghoststream data is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Radiostream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Statusstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Beacon is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Monitor is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Platform configured to "IMST + Rpi"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Contact email configured to "[email protected]"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Description configured to "Update me"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: found local configuration file local_conf.json, parsing it
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: redefined parameters will overwrite global parameters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: local_conf.json does not contain a JSON object named SX1301_conf
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: local_conf.json does contain a JSON object named gateway_conf, parsing gateway parameters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: gateway MAC address is configured to B827EBFFFEEE814F
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Found 1 servers in array.
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Server 0 configured to "router.eu.thethings.network", with port up "1700" and port down "1700"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with a valid CRC will be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with a CRC error will NOT be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: packets received with no CRC will NOT be forwarded
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference latitude is configured to 0.000000 deg
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference longitude is configured to 0.000000 deg
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Reference altitude is configured to 0 meters
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: GPS is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: antenna_gain 0 dBi
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Upstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Downstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Ghoststream data is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Radiostream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Statusstream data is enabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Beacon is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Monitor is disabled
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Contact email configured to "my@email"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Description configured to "customHostname"
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: Successfully contacted server router.eu.thethings.network
May 23 23:18:01 customHostname ttn-gateway[3505]: INFO: [main] Starting the concentrator
May 23 23:18:01 customHostname ttn-gateway[3505]: ERROR: [main] failed to start the concentrator
May 23 23:18:01 customHostname systemd[1]: ttn-gateway.service: Main process exited, code=exited, status=1/FAILURE
May 23 23:18:01 customHostname systemd[1]: ttn-gateway.service: Unit entered failed state.
May 23 23:18:01 customHostname systemd[1]: ttn-gateway.service: Failed with result 'exit-code'.

any suggestions on what the problem is ??

regards

from ic880a-gateway.

gonzalocasas avatar gonzalocasas commented on September 14, 2024

The message means the RPi cannot communicate with the iC880a. The root cause can be a lot of things: 1) the wiring might be wrong (if you are using jumper wires, this is very often the case, even if you double checked), 2) the power supply is not sufficient (make sure you have a 2A unit at least, and of a good manufacturer), 3) the hardware might have a defect...

from ic880a-gateway.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.