What I2C driver solution to use? Thermal imaging
#1
Hi All, 

The main question is if you can provide direction on selecting a generic driver that can be later used with applications. 

I am working on a project to add an AMG8833 thermal sensor to the PinePhone, the flex board to expose the pogo pins works, the PCB that holds the AMG8833 is also working fine and it is already being detected. Now on the software side I am not that good so I hope I can get your help on this. 

[Image: IMG-0224.jpg]

Code:
[root@manjaro-arm Raspberry-Pi-Installer-Scripts]# 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: -- -- -- -- -- -- -- -- 68 -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --                

Address has been set with a pulldown resistor on the sensor so it is 0x68.

I can read from the sensor and get temperature values: 
Code:
[root@manjaro-arm Raspberry-Pi-Installer-Scripts]# i2cget 3 0x68 0x80
WARNING! This program can confuse your I2C bus, cause data loss and worse!
I will read from device file /dev/i2c-3, chip address 0x68, data address
0x80, using read byte data.
Continue? [Y/n] Y
0x4a

I have tried with Adafruit circuit python with no success to use its examples as I get stuck in needing to install libgpiod which needs a higher version of linux headers than the ones I have installed and are available in Manjaro Beta 2. 
Code:
configure: error: "libgpiod needs linux headers version >= v5.10.0"
Code:
[root@manjaro-arm Raspberry-Pi-Installer-Scripts]# uname -r
5.9.1-9-MANJARO-ARM
[root@manjaro-arm Raspberry-Pi-Installer-Scripts]# pacman -S linux-pinephone-headers
resolving dependencies...
looking for conflicting packages...

Packages (1) linux-pinephone-headers-5.9.9-1

Total Installed Size:  44.91 MiB
Net Upgrade Size:       0.00 MiB

:: Proceed with installation? [Y/n]
Maybe I need to try a different PinePhone distribution? Any recommendations?  

I would like to hear from other users experiences and what they use for I2C drivers.  Do you use a generic driver or write your own from scratch? 

The end purpose is to create a portable infrared camera on your pocket.  

Cheers!.
  Reply


Messages In This Thread
What I2C driver solution to use? Thermal imaging - by jnpine - 11-30-2020, 04:18 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Article: NuttX RTOS for PinePhone: Display Driver in Zig lupyuen 0 1,193 10-17-2022, 07:02 PM
Last Post: lupyuen
  Article: NuttX RTOS for PinePhone: UART Driver lupyuen 0 882 09-09-2022, 10:35 PM
Last Post: lupyuen
  PSA: WiFi driver is broken - Unload kernel module to save lots of power Trbl 3 4,081 06-23-2021, 02:28 AM
Last Post: Merc
  Pinephone as daily driver lcayer1 15 20,106 10-13-2020, 07:18 PM
Last Post: hiimtye

Forum Jump:


Users browsing this thread: 1 Guest(s)