Available GPIO?

Hi,
I'm looking for information about which GPIOs are available, and which are in use on the beaglebone black.

I've been looking at the schematic, but i wasn't clear to me which one are in use on the BBB

I guess i could take a look at the PCB files, but i'd really prefer not to having to install eagle to get this information.

Is it available somewhere, or can someone help me with this information?

Specifically, i need to use I2C, but i might also need additional IO, so any information is appreciated.

Thanks

Comments

  • Alternatively, i guess i could try and bitbang I2C on the unpopulated GPIOs
  • jksjks
    Accepted Answer
    Are you talking about GPIO on KiwiSDR or BeagleBone Black/Green in general? If KiwiSDR see this thread, first page of comments. Look for my spreadsheet table with all the colors: http://valentfx.com/forums/#/discussion/590/kiwisdr-antenna-switch-extension-and-beaglebone-black-green-gpios/p1

  • That's exactly the information i was looking for, thanks!
  • Hi,

    The GPIO pins that are currently used by the KiWi ant_switch extension are as follows:-

    P8 pin 11 - GPIO_45 - Antenna 1
    P8 pin 12 - GPIO_44 - Antenna 2
    P8 pin 13 - GPIO_23 - Antenna 3
    P8 pin 14 - GPIO_26 - Antenna 4
    P8 pin 15 - GPIO_47 - Antenna 5
    P8 pin 16 - GPIO_46 - Antenna 6
    P8 pin 17 - GPIO_27 - Antenna 7
    P8 pin 18 - GPIO_65 - Antenna 8 (not available in webui yet)
    P8 pin 19 - GPIO_22 - Antenna 9 (not available in webui yet)
    P8 pin 26 - GPIO_61 - Antenna 10 (not available in webui yet)

    So if you are creating a new extension, I'd avoid those ones so that it doesn't clash.

    Regards,

    Martin - G8JNJ
  • Here's the thing:
    I'm planning to run the KiwiSDR from LiFePO4 batteries, and since they have a very flat voltage discharge curve, i need to monitor current in/out. I'm planning to do that with the INA219 current/power monitor, which is I2C.

    I might also consider turning on/off relay/mosfets - hence the additional GPIOs... 
    This comes secondary though, and shouldn't be a big problem.

    I have absolutely no experience developing for the Beaglebone black, i do however have plenty of experience with a variety of microcontrollers and a small amount of Raspberry PI

    It looks like the I2C peripherals are not available (or maybe it could be shared? with correct addressing etc. @jks ? )
    Alternatively, I've been looking at bit banging I2C, but my initial research have led me to believe i need to use the BBBs PRU for this - which also seems to be unavailable (?)

    If everything else fails, i might just separate it completely, and have a microcontroller managing/indicating the status of the batteries - this would be easy, but less than ideal though.

    I'm not sure if makes sense to publish this as a new extension, since its a rather specific use - so it might just end up being for personal use

    This might be material for a new topic, but i'm going to try my luck here

    TL;DR
    Any ideas for solving having to talk I2C, while using the KiwiSDR?
  • You might want to explore the Grove I/O

  • edited February 11
    WA2ZKD, 
    the beaglebone black does not have a grove connector.

    The grove connector on the Beaglebone green is just connected to pin 19 and 20, which are already being discussed here (I2C2 port).

    It seems to be in use (see here), but might be possible to add more devices to, with correct I2C addressing.
    As long as i don't risk screwing up the config of the FPGA or something like that.
  • Been looking around a bit in the schematics, PCB files, datasheets etc.
    (should have realized its KiCad to begin with, not Eagle as mentioned in first post - not sure how i concluded that) 

    It looks like its only the EEPROM using the I2C pins, and its configured for address 0x54,
    so i should be relatively safe to play around with it as long as i don't touch the EEPROM
  • jksjks
    edited February 11
    To summarize the I2C situation:

    I2C0: Not available externally. Connects to PMIC, BB EEPROM, HDMI framer (BBB). Do not use obviously.
    I2C1: Can be configured to appear on header pins P9-17/18. DO NOT USE. Configured by Kiwi to be SPI0-CS0/MOSI used to program and communicate with FPGA. In use all the time by the Kiwi.
    I2C2: Connects to header pins P9-19/20 and Grove J4 (BBG). BUT also used by Kiwi to access Kiwi EEPROM at address 0x54 as you mention. There is a write protect signal to this EEPROM that is generated from the FPGA. So you should not be able to accidentally write to the EEPROM. But don't use this address when adding your I2C device. The Kiwi only accesses its EEPROM once during program startup.

  • jksjks
    edited February 11
    Programming the Beagle devices and GPIO was always a pain in the early days when I was first developing. So I just accessed the hardware directly and tried to stay out of the way of the BB Debian software which was always changing. But it's probably better now.

    To get at I2C2 the Kiwi code opens /sys/bus/i2c/devices/2-0054/eeprom (Debian 8) and directly reads and writes that file. I don't know how that interface works for non-EEPROM I2C devices.

    The antenna switch extension backend manipulates GPIOs by using the /sys/class/gpio/ interface. See https://github.com/OH1KK/KiwiSDR-antenna-switch-extension/blob/master/backends/ant-switch-backend-beagle-gpio


Sign In or Register to comment.