×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Weather radio don't want connect

  • Posts: 250
  • Thank you received: 3
hello

You could look at /tmp/indiserver.log to see what it says. If it is not too large you could post it or a link to it.

I can't find the file in "tmp".

Are you using an Arduino? or a Wemos? See problems with crashes above when using a small memory device with many
sensors.


I have a Arduino

How many sensors are you running?


BME280
MLX
TSL2591
3 years 2 months ago #66300

Please Log in or Create an account to join the conversation.

  • Posts: 89
  • Thank you received: 16

Replied by Adrian on topic Weather Radio - info channel

Regarding the tmp file
=================

If the file is not in /tmp the two main possibilites are
- you did not send it there when you started indiserver
- or the box where the indiserver was running has rebooted and /tmp has been emptied

I see that from your post above you are referring to the .service file
This is usually /etc/systemd/system/indi-weatherradio.service
I suppose this is where you are running indiserver from, this file will be run
at each system boot, if the service is enabled with

$ sudo systemctl enable indi-weatherradio.service
Or the service can be manually started with
$ sudo systemctl start indi-weatherradio.service

The indiserver can also be started in other ways
- from the terminal
- by another application (eg. kstars)
[Unit]
Description=INDI server for weather radio
Wants=network-online.target
After=network-online.target
 
[Service]
Type=simple
User=root
ExecStart=/usr/bin/indiserver -v indi_weatherradio
 
[Install]
WantedBy=multi-user.target

You can stop the service and edit this file to change the start line to
ExecStart=/usr/bin/indiserver -v indi_weatherradio >> /tmp/weatherradio_output.txt

Not the >> which sends the output of indiserver to the file.

Then start the service as you usually do.
afa@NAFABox:~$ sudo systemctl start indi-weatherradio.service

You can check whats in the output by typing in a terminal
afa@NAFABox:~$ tail -f /tmp/weatherradio_output.txt

There you will see the output and later on you can copy it to wherever you wish.

Regarding the sensors and Arduino
===========================
I had no trouble with crashes with the three sensors you are using on an Arduino Uno and an Arduino Nano,
but when I added more the memory was not sufficient and I got crashes quickly. There are many different models
of Arduino.

Crashing troublshooting
==================
If your indiserver crashes and your computer is attached to the arduino with a usb cable you can use the serial
monitor for the Arduino IDE (or minicom etc) to see if you can talk to the arduino.

You can try the v and w commands and see if you get something back.
v will give the version of the firmware
w will print out the sensors with their readings

If you can't talk with the arduino then there may be a problem with the arduino or the hardware,
damp and wetness was my problem.
If you can talk to the arduino and indiserver is crashing then there is some other problem, most likely.

My Uno ran with these three sensors for a long time before I had problems with damp and wetness.

Is it a good idea to look at the arduino and the sensors to make sure they are not wet!
3 years 2 months ago #66308

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
hello
so here are my commands that I use to launch the service or to control it :
sudo service indi-weatherradio start
sudo service indi-weatherradio stop
sudo service indi-weatherradio status

so I have to do otherwise to launch the service?
what would be the commands to do in order to have a fair launch with a log in case of problem?

Best regards
Christophe
Last edit: 3 years 2 months ago by Porchet.
3 years 2 months ago #66320

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
duplicate of the previous message
Last edit: 3 years 2 months ago by Porchet.
3 years 2 months ago #66323

Please Log in or Create an account to join the conversation.

  • Posts: 89
  • Thank you received: 16

Replied by Adrian on topic Weather Radio - info channel

You launch the indi weatherradio service with the start command as you say.
You can also use a different syntax which gives the same result

e.g.
sudo systemctl stop indi-weatherradio.service
etc.

What you are typing is fine for controlling the service, you can use other methods but you only need one.

You need to get the output of the indiserver into a file to record what is happing in case of a crash.
To do this you need to edit the service script to redirect the output to a file.

First stop the service
Use a text editor to edit the service file /etc/systemd/system/indi-weatherradio.service

Change the exec start command from
ExecStart=/usr/bin/indiserver -v indi_weatherradio
to
ExecStart=/usr/bin/indiserver -v indi_weatherradio >> /tmp/weatherradio_output.txt

Now restart the service.
You can check if it is running with the status command (or ps aux | grep indiserver)

Now if the server crashes the log will be in /tmp/weatherradio_output.txt. You can look at that for any clues.

When you don't want the log anymore you can change the service file back to the original one.
3 years 2 months ago #66373

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
Hello
So how do I edit the file, because there's nothing I can do about it?
3 years 2 months ago #66440

Please Log in or Create an account to join the conversation.

  • Posts: 89
  • Thank you received: 16

Replied by Adrian on topic Weather Radio - info channel

Gain access to the box running the service, same as how you get to issue the commands to start and stop and get status for the service.

This is usually by either
- sitting at box with monitor and keyboard
- remote access over the network

At box
======
If you are using a keyboard and monitor at the computer running the service, start a terminal and edit the file with an editor, for instance
$ sudo nano /path/to/file

nano is a simple editor with prompts.

Make the changes and save the file
You can use any editor you like.

Remote access
=============
If you are remote from the computer running the service, use ssh (putty on windows) to get terminal access and proceed as before. You can also use a remote desktop instead of ssh if you have that set up.
3 years 2 months ago #66463

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
hello
then I don't have a problem to open it, but I can't modify it, because, I don't have the authorization to modify it.
3 years 2 months ago #66465

Please Log in or Create an account to join the conversation.

  • Posts: 89
  • Thank you received: 16

Replied by Adrian on topic Weather Radio - info channel

If you use sudo you should be able to edit it, sudo makes you the super user.

If you tried sudo and it did not work please post the command you tried and the output you got back.
3 years 2 months ago #66472

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
hello
so I managed to modify the command line, more than waiting for the next crash to see where the problem comes from.

Christophe
3 years 2 months ago #66479

Please Log in or Create an account to join the conversation.

  • Posts: 89
  • Thank you received: 16

Replied by Adrian on topic Weather Radio - info channel

Here are two useful commands for you to try to monitor the situation

Check that indi is working
====================
$ ps aux | grep indiserver

You should see a line saying that indiserver is working, it will include the command including indi_weatherradio

Check the output of the logfile
=======================
$ tail -f /tmp/logfilename.txt

Instead of /tmp/logfilename.txt put in the path to the log file you used in the service script

This will show the output from the indiserver being put into the log file.
-f means follow and uou need to press ^C to get your command prompt back again.

Changing verbosity of indi
====================
You can increase the amount of information that indi outputs by adding extra v to the service file.

The service file above has one v as in
indiserver -v indi_weatherradio >> /tmp/outputfile.txt

To make it more verbose use -vv or -vvv
indiserver -vv indi_weathreradio >> /tmp/outputfile.txt

Hopefully your mystery will be solved soon.
3 years 2 months ago #66481

Please Log in or Create an account to join the conversation.

  • Posts: 250
  • Thank you received: 3
hello
so here it is, it happened, my weather station crashed.
So now I'm doing how to find and read the file that will tell me what happened.
because I can't find a file

See you
Christophe
Last edit: 3 years 1 month ago by Porchet.
3 years 1 month ago #67109

Please Log in or Create an account to join the conversation.

Time to create page: 0.887 seconds