debian i2c-dev
#4
(12-16-2016, 05:19 AM)KnReLe Wrote: The initial entry for the root password in /etc/shadow is *, meaning that there is no way to log-in as root initially, the only way to get a root login is to use sudo and set the password of root from that, as I showed.

Ahh... So basic... I forgot to so the sudo and was just typing "su" to get into it.
Still new to the linux environment, thanks for the help.

(12-16-2016, 02:49 AM)KnReLe Wrote: As you already can see your device via i2cdetect the necessary module and device is already present. Otherwise i2cdetect wouldn't have found the necessart /dev/i2c-1 file and been able to communicate with it to find your device.

In fact if you go look with something like

ls -l /dev/i2c*

it should already show something like:

crw-rw---- 1 root i2c 89, 0 Dec 10 14:44 /dev/i2c-0
crw-rw---- 1 root i2c 89, 1 Dec 10 14:44 /dev/i2c-1

Your guess at there being two i2c-busses is correct. The i2c-1 buss is the one you find on the PI-2-bus connector pins 3 and 5, which is presumably where you connected your ADS1115.  Although the pin-out is similar to the one on the Raspberry Pi, the Pine does not have in-built pull-up resistors, but if your ADS1115 is on a breakout board such as the one that Adafruit sells, there will be pull-up resistors there, so communication will work, which is what you see here.

The other i2c buss, i2c-0, is connected to the socket labeled TP on the board, and it is meant to be used for the touchpad. It is not as easy to connect to, though there are some test pads on the bottom of the card underneath the Touchpad connector that could be accessed via fine-hand soldering. There are six of them there. Looking at the card from below, holding it so that the text («Designed in Silicon Valley, California....») is the right way (not upside down or sideways), the pads are towards the top right corner, in two rows of three, staggered.

    (GND)         (PH0/TWI0_SDA)    (PH11)
(VCC_CTP) (PH1/TWI0_SCL)    (PH4)

The middle ones thus are the SDA and SCL for the i2c-0 bus.

Back to your problem. Seeing as the kernel and hardware i2c subsystem is in order, (the i2cdetect -y 1 output indicates this), the problem could be in the python libraries used. They might contain knowledge if your device is a particular model of Raspberry Pi or some specific model of Beaglebone, but they probably don't know about the PineA64, hence they could not determine the default bus for platform, even though it would be the same (/dev/i2c-1) as Raspberry Pi has.

You don't say which github example this is, though googling returns the ones referring to the Adafruit board.  You might have to delve deeper into the library being used to find out more about the Python subsystems that use i2c.

As for the root password, since you already have sudo working (for the i2cdetect and others) you can get a root shell with
sudo su -

and while in that, you can set whatever password you like for root, with

passwd root
(then enter your new password, twice)

Thanks for explaining the other bus on the TP connection.

Yes - the ls -l /dev/i2c* output was exactly as you showed.

I used the Adafruit github like you guessed.
https://github.com/adafruit/Adafruit_Python_ADS1x15

Nothing special or out of the ordinary - just going from the pine to a t-cobbler to breadboard.

Pine Ground --> ADS1115 Ground
Pine 5v --> ADS1115 VCC
Pine SCL --> ADS1115 SCL
Pine SLA --> ADS1115 SLA

Jumper from ADS1115 Ground to ADS1115 Addr (tried without jumper, too, same result)

I also tried feeding an input of 3.3v back into the A0-A3 inputs on the ADS1115 board and it never got past the bus identification error.

I greatly appreciate the help you have given.

I'm going to do a cleanup of my Pi 2 and try it with that instead. I was just hoping to used the Pine instead.

For what it is worth the application is intended to be a standalone data logger for a machine output - It is very appealing for many reasons to have a device like this completely separate from the control system, aside from reading a voltage output.
  Reply


Messages In This Thread
debian i2c-dev - by pine.adam - 12-15-2016, 09:32 AM
RE: debian i2c-dev - by KnReLe - 12-16-2016, 02:49 AM
RE: debian i2c-dev - by KnReLe - 12-16-2016, 05:19 AM
RE: debian i2c-dev - by pine.adam - 12-16-2016, 07:31 AM
RE: debian i2c-dev - by KnReLe - 12-16-2016, 08:06 AM
RE: debian i2c-dev - by pine.adam - 12-16-2016, 08:09 AM
RE: debian i2c-dev - by pine.adam - 12-16-2016, 04:21 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Debian installer on Pine A64+ but no hdmi mrwick 1 4,956 07-28-2020, 01:49 PM
Last Post: kuleszdl
  Debian Pine64 h264/5 Video under vlc ozcy 6 12,936 04-15-2020, 05:27 AM
Last Post: dmitrymyadzelets
  OMV/debian/systemd: how to start the network kittyland 0 2,987 12-10-2019, 05:29 PM
Last Post: kittyland
  Debian 10 (Buster) in deep freeze - includes support for Pine64+ amp 5 10,260 07-22-2019, 09:29 PM
Last Post: amp
  Pine64 Debian Stretch/mainline [4.14.7] CallMeFoxie 50 122,557 07-22-2019, 09:24 PM
Last Post: amp
  Installing Debian with the Debian Installer (Buster RC1) amp 1 4,823 06-28-2019, 12:35 PM
Last Post: Kaarme42
  Script to build pure Debian images for Pine64+ amp 1 4,266 05-01-2019, 09:09 PM
Last Post: tllim
  Debian (Stretch) for Pine64-LTS wgray 2 6,370 04-04-2019, 09:54 PM
Last Post: wgray
  Is there just one fuctioning Debian Desktop image? KNERD 7 13,268 03-29-2019, 02:00 AM
Last Post: desai_amogh
  (ARCHIVED) Debian Jessie Images (3.10.102 BSP Kernel) New Release lenny.raposo-pine64.pro 259 466,853 05-21-2018, 06:30 AM
Last Post: Luke

Forum Jump:


Users browsing this thread: 1 Guest(s)