Welcome to Radarspotting. Please login or sign up.

April 18, 2024, 08:04:29 PM

Login with username, password and session length

New Members

New Members

You should get an activation email when you join.  If not, please use the Contact option.

ModeSDeco2 and ModeSMixer2 - console programs for RTLSDR and transcoding

Started by sergsero, August 09, 2013, 03:08:08 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

abcd567

Hi andrewt

Great. The output you posted shows everything is ok.
What you see in your browser at following address?
IP-of-PI:8787

Analysis of output of command sudo systemctl status mm2:
(1) This shows your config is OK

   CGroup: /system.slice/mm2.service
           ├─447 /bin/bash /usr/share/mm2/mm2.sh
           └─450 /usr/share/mm2/modesmixer2 --inConnectId 127.0.0.1:30005:ADSB --inConnectId 127.0.0.1:30105:MLAT --web 8787 --location 13.xxxx:-59.xxxx


(2) The last 3 lines show that modesmixer2 is working OK and after several failed attempts, finally got connected to piaware mlat feed back at port 30105

INFO     inConnectId(127.0.0.1:30105:MLAT) connecting 127.0.0.1:30105
INFO     inConnectId(127.0.0.1:30105:MLAT) connected
INFO     inConnectId(127.0.0.1:30105:MLAT) BEAST data stream detected

abcd567

Posted a new script at Github for automated installation of ModeSDeco2 on RPI 2/3/4 Raspbian Stretch/Buster


sudo bash -c "$(wget -O - https://raw.githubusercontent.com/abcd567a/md2/master/install-md2.sh)"


The script does following:
(1) Creates a  folder /usr/share/md2 to hold ModeSDeco2 files.
(2) Downloads ModeSDeco2's .tgz file from Google Drive, and un-compresses it inside folder /usr/share/md2.
(3) Creates a service file for start up, control, and monitoring of ModeSDeco2 by systemd service.
(4) Creates a config file /usr/share/md2/md2.conf shown below.
This file can be edited by user to add, delete or modify the configuration.
New arguments can be added, one per line, in format --argument value

--beast 30005
--msg 30003
--web 8787
--location xx.xxxx:yy.yyyy


(5) Announces completion and displays brief guide.

.

FOR DETAILS:
https://github.com/abcd567a/md2/blob/master/README.md



.
STATUS

pi@raspberrypi:~ $ sudo systemctl status md2

● md2.service - ModeSDeco2
   Loaded: loaded (/lib/systemd/system/md2.service; enabled; vendor preset: enabled)
   Active: active (running) since Sun 2019-08-18 17:59:05 BST; 32min ago
Main PID: 697 (bash)
    Tasks: 7 (limit: 2200)
   Memory: 28.7M
   CGroup: /system.slice/md2.service
           ├─697 /bin/bash /usr/share/md2/md2-start.sh
           └─699 /usr/share/md2/modesdeco2 --beast 30005 --msg 30003 --web 8787 --location 43.xxx:-79.xxx

Aug 18 17:59:06 raspberrypi modesdeco2[697]: 2019-08-18 17:59:06.351  INFO     ModeSDeco2 v.20180729
Aug 18 17:59:06 raspberrypi modesdeco2[697]: 2019-08-18 17:59:06.352  INFO     The magnetic declination value is calculated
Aug 18 17:59:06 raspberrypi modesdeco2[697]: 2019-08-18 17:59:06.382  INFO     Device: 0 mnf: Realtek prod: RTL2832UFA serial: 00000101
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.027  INFO     Supported Gains (dB):  0.0 0.9 1.4 2.7 3.7 7.7 8.7 12.5 14.
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.027  INFO     Freq Correction: 0 ppm
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.045  INFO     Gain: Auto
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.050  INFO     AGC: Off
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.050  INFO     Start Beast Server on port 30005
Aug 18 17:59:07 raspberrypi modesdeco2[697]: 2019-08-18 17:59:07.050  INFO     Start MSG Server on port 30003
Aug 18 17:59:07 raspberrypi modesdeco2[697]: Used 4 zero-copy with pre-allocated memory

.

doctorvenables

@abcd567 re: your last post of Aug 17.

That's exactly what's happening to me (still).
I get silhouettes now that I've changed the full path back to a subdirectory of my home directory.
I get flightroutes data back now after the same change to mm2.conf

Still no data persistance however.

andrewt

Hi All
I have a question, where can I get my hands on a working flightroute.sqb file for mm2? I've been searching the internet for the past three days and didn't come across a working one.
Can anyone help

Thanks

MASHtm

I recently noticed that Firefox (at least 69.x) does not fetch the airplane pictures. The json request to mm2 is successful and the answer contains the correct URI to the picture, but it is never fetched (according to network debug). Chrome and Seamonkey still work.

Anybody else seeing this?

abcd567

Quote from: MASHtm on September 18, 2019, 10:40:10 AM
I recently noticed that Firefox (at least 69.x) does not fetch the airplane pictures.
.......
Chrome and Seamonkey still work.

Anybody else seeing this?

Same here.

evangel

Quote from: andrewt on September 07, 2019, 08:49:59 PM
Hi All
I have a question, where can I get my hands on a working flightroute.sqb file for mm2? I've been searching the internet for the past three days and didn't come across a working one.
Can anyone help

Thanks

hi
that file and companion basestation.sqb can be found at
https://groups.io/g/planeplotter/topic/latest_flightroute_sqb_file/26719164?p=,,,20,0,0,0::recentpostdate%2Fsticky,,,20,2,0,26719164


brgds

abcd567

@sergsero
Comments of @prog (Youssef Touil, developer of AirSpy software)
https://discussions.flightaware.com/t/airspy-ads-b-decoder/55825/58

Quote from: prog

Quote from: abcd567
@prog
Any comments about ModeSDeco2's AirSpy config? How relevant these are to current models of AirSpy?

ModeSDeco uses the old algorithm I developed for Airspy which has different settings.
Note that these same settings disappeared from airspy_adsb command line at some point. Now they result in a warning.
For the gain options, it's better to use the linearity mode with one global gain index rather than 3 individual gain stages (LNA/Mixer/IF). This is especially true if you use the device with an external LNA, which is almost always the case in ADSB/Mode S reception.

radarvirtuel

Hi Sergsero
I looking for modesmixer2_radarcape_debian8_20150825.tgz but not available from googledrive..
Could you help me ?
Thanks

sergsero

Hi Radarvirtuel,

Unfortunately, that version is not available, but here (http://xdeco.org/?page_id=30#mm2) is the current one (modesmixer2_bbone_deb8_20190413.tgz) for beaglebone. I tested it on the radarcape' Linux radarcape 4.1.30-ti-r69 #1 SMP Sun Aug 14 11:23:09 UTC 2016 armv7l GNU/Linux.

Best regards,
sergsero

[attachment deleted reduce file load]

dlfergrd

Hi sergsero

Thanks for the great software. I have just recently started using it and everything runs great except for one thing.
If I close modesmixer2 and then restart it, all of the chart data on the charts page in the web interface is reset.
The aircraft plot data on the maps page is saved between restarts of modesmixer2.

I am on Windows 10 and running modesdeco and modesmixer as well as viewing the web interface on the same machine.
I thought it may have something to do with permissions so I tried running modesmixer as an administrator and have the same results.

My modesdeco.bat
@echo off
TITLE Decoder
cmd /c modesdeco2.exe --gain 49.6 --localtime --location xxx:-xxx --rbs --avr 31100 --beast 31011
PAUSE
exit


modesmixer.bat
@echo off
TITLE Mixer
cmd /c c:\sdr\modesmixer\modesmixer2.exe --google-key xxxxxxxx--web 8080 --db c:\sdr\database\basestation.sqb --frdb c:\sdr\database\flightroute.sqb --silhouettes c:\sdr\database\silhouettes --pictures c:\sdr\database\pictures --location xxx:-xxx --inConnectId 10.53.44.53:31011:ModeSDc --filter-expire 30 --valid-adsb 4:20 --outServer beast:33033 --outServer beastmlat:30115 --valid-modes 0:5
PAUSE
exit


The path to the database is correct, I can see the size of the file increasing.
I don't know if I have a setting wrong or missing of where the data is saved for the histograms.

Thanks for any help with this.

sergsero

Hi dlfergrd,
Quote from: dlfergrd on November 23, 2019, 06:29:01 PM
If I close modesmixer2 and then restart it, all of the chart data on the charts page in the web interface is reset.
The aircraft plot data on the maps page is saved between restarts of modesmixer2.
Indeed, this is a feature of the current versions of the programs and there are no errors in your settings.
The explanation for this is in the original purpose of modesmixer2 as a console (without any GUI or Web) program for operational data transcoding.

These programs usually store and use all data in the computer's RAM only while they are running. Only for the aircraft plot data on the maps page its values are saved in a separate file.
There are plans to add the same capability for the chart data on the charts page in the web interface.

Best regards,
sergsero

dlfergrd

Thanks very much for the quick response. I look forward to the next release.

g0wfv

HTTP/1.1 response "Transfer-Encoding: chunked" breaks HTTP/1.0 mod_proxy on lighttpd.

I'm trying to use lighttpd's mod_proxy to make the ModesMixer2 web server appear under a directory on my main lighttpd webserver, however I always get a "502 Bad Gateway" error.

Looking at the error.log for the lighttpd webserver I get the following ...

2020-01-03 11:18:41: (http-header-glue.c.999) proxy backend sent invalid response header (Transfer-Encoding) to HTTP/1.0 request
2020-01-03 11:18:41: (gw_backend.c.2149) response not received, request sent: 733 on socket: tcp:127.0.0.1:81 for /msd?, closing connection


Some further searching turns up the same error  ... https://redmine.lighttpd.net/issues/2913

Some cursory testing with curl confirms that ModesMixer2 replies to a HTTP/1.0 request with a "Transfer-Encoding: chunked" reply, apparently breaking the RFC. (lighttpd's mod_proxy is HTTP/1.0 only)

pi@raspberrypi:~$ curl -0 localhost:81 -v

> GET / HTTP/1.0
> Host: localhost:81
> User-Agent: curl/7.64.0
> Accept: */*
>
< HTTP/1.1 200 OK
< Content-Type: text/html
< Content-Length: 55544
< Date: Fri, 03 Jan 2020 11:41:52 GMT
< Last-Modified: Wed, 01 Jan 2020 18:58:22 GMT
< Etag: 5e0cebce.55544
< Connection: close
< Transfer-Encoding: chunked


Any chance of a fix?

Carlos

Hi all,

I am hoping someone on here can help me out again. :-)

I use Modesdeco with an RTL dongle and has been working great for a long time now.

However i have damaged the casing of the dongle (It still works for now) so i have bought a new one.

Unfortunately i cannot get his new one to work. I get the following issue:

2020-04-25 15:08:27.389  INFO     ModeSDeco2 v.20151226
2020-04-25 15:08:27.452  INFO     Device: 0 mnf: Realtek prod: RTL2838UHIDIR serial: 00000001
2020-04-25 15:08:27.889  ERROR    Can't open device: sdr_set_freq(): Bad file descriptor
Press any key to continue . . .

I have searched the web but cant work out the problem.

If someone is able to point me in the right direction on how to fix this that would be great please.

Many thanks

Carl

[attachment deleted reduce file load]