[TangerineSDR] Magnetometer bring up issues

Bob Stricklin bstrick at N5BRG.COM
Fri Jul 7 17:29:27 EDT 2023


I am trying to get the TAPR supplied magnetometer working and having some problems.

After cloning Dave's GitHub and running make I see this output:

pi at Fox-in-box-v3:~/rm3100-runMag $ ls
CHANGES.txt  cmdmgr.h  device_defs.h  i2c.c  i2c.o    logs    main.h    MCP9808.h      README.md  runMag.c  runMag.o       runrun.sh
cmdmgr.c     cmdmgr.o  docs           i2c.h  LICENSE  main.c  Makefile  metadata.json  runMag     runMag.h  run-nopipe.sh
pi at Fox-in-box-v3:~/rm3100-runMag $ cat runrun.sh
./runMag -b 1 -j -M 23 -A 10 -c 400 -U 140 -Z > /home/web/wsroot/pipein.fifo
pi at Fox-in-box-v3:~/rm3100-runMag $ mkdir test/
pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -b 1 -j -M 23 -A 10 -c 400 -U 140 -Z > ./test/pipein.fifo
./runMag: invalid option -- 'U'
pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -b 1 -j -M 23 -A 10 -c 400 -Z > ./test/pipein.fifo
Error : I/O error reading temp sensor at address: [0x19].
Error : I/O error reading temp sensor at address: [0x18].
Error : I/O error reading temp sensor at address: [0x19].
Error : I/O error reading temp sensor at address: [0x18].


pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -M 23 -m
"time", "rtemp", "ltemp", "x", "y", "z", "rx", "ry", "rz", "total"
"07 Jul 2023 21:04:38", 15.1029, -19.0455, 45.8655, 134, -169, 407
"07 Jul 2023 21:04:38", 15.0998, -19.0481, 45.8631, 134, -169, 407
"07 Jul 2023 21:04:39", 15.0984, -19.0519, 45.8628, 134, -169, 407
"07 Jul 2023 21:04:40", 15.0972, -19.0479, 45.8633, 134, -169, 407
"07 Jul 2023 21:04:41", 15.0957, -19.0515, 45.8711, 134, -169, 407
^C
pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -L 1f -l
i2c_writebuf(): write(): Remote I/O error
i2c_read read value.: Remote I/O error

RM3100 REVID NOT CORRECT: RM3100 REVID: 0x0 <> EXPECTED: 0x22.

pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -L 0x1f -l
i2c_writebuf(): write(): Remote I/O error
i2c_read read value.: Remote I/O error

RM3100 REVID NOT CORRECT: RM3100 REVID: 0x0 <> EXPECTED: 0x22.

pi at Fox-in-box-v3:~/rm3100-runMag $ ./runMag -L 0x1F -l
i2c_writebuf(): write(): Remote I/O error
i2c_read read value.: Remote I/O error

RM3100 REVID NOT CORRECT: RM3100 REVID: 0x0 <> EXPECTED: 0x22.


pi at Fox-in-box-v3:~/rm3100-runMag $ sudo ./runMag -L 0x1f -l
i2c_writebuf(): write(): Remote I/O error
i2c_read read value.: Remote I/O error

RM3100 REVID NOT CORRECT: RM3100 REVID: 0x0 <> EXPECTED: 0x22.



Raspberry Pi 3B:  (Also tried a few other Raspberry Pi units.)

used sudo raspi-config to activate I2C

Then I edited /boot/config.txt to add:

dtoverlay=i2c-gpio,bus=3,i2c_gpio_delay_us=1,i2c_gpio_sda=28,i2c_gpio_scl=27



pi at Fox-in-box-v3:~ $ i2cdetect -l
i2c-3 i2c       3.i2c                           I2C adapter
i2c-1 i2c       bcm2835 (i2c at 7e804000)          I2C adapter
pi at Fox-in-box-v3:~ $ i2cdetect -y 1
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 1f
20: -- -- -- 23 -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
pi at Fox-in-box-v3:~ $ i2cdetect -y 3
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --
pi at Fox-in-box-v3:~ $ i2cdetect -y 2
Error: Could not open file `/dev/i2c-2' or `/dev/i2c/2': No such file or directory
pi at Fox-in-box-v3:~ $ i2cdetect -y 4
Error: Could not open file `/dev/i2c-4' or `/dev/i2c/4': No such file or directory
pi at Fox-in-box-v3:~ $



Results:

Looks like the magnetic sensors may be responding but the temp sensor is not responding to reads. The temp sensor does show up as a valid i2c address though.

I noticed the memory chip on local and on remote is not responding with address A0 and this device in on the same i2c bus it seems. According to the data sheet
without the jumper installed on WP it should be working in read mode. I put the jumper on and still do not see the device with i2cdetect -y 1. If this is not being used for
anything else I would prefer to put the jumper on WP and allow it to be used in the ground after being buried. With WP pulled high the chip is still pulling 1 - 2 ma anyway.

I would appreciate any comments on what else should be done to get this working so I can put the unit in the ground and get providing data.


Bob N5BRG


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.tapr.org/pipermail/tangerinesdr_lists.tapr.org/attachments/20230707/bfd292fc/attachment-0001.html>


More information about the TangerineSDR mailing list