I didn't find anything linear enough for me to understand though, so I post here in hopes that someone is able to hit me with the "got it!" revelation.
Prologue: I've programmed an alarm system using PHP, I love how you can access anything GPIO under /sys/class/gpio/ and really use that adagio that goes "in linux everything is a file".
I can just fopen() fread()/fwrite() and rewind() to access GPIO in an extremely fast manner.
Now tho I ended using all the proper GPIO pins, and either I use as input/output the other alternate function pins as well (I don't want to because I plan to use those for their own function in the future) or I finally put to use the CJMCU-2317 board that I have lying around.
I understand that I should connect (from expansion board to Pi3):
Reset-(what here? optional?)
But after that my brain simply gets lost.
I mean, I get what is the serial interface, why RX goes to TX and vice-versa, what is the baudrate and all... but I don't know what SCL and SDA are, what INTA and INTB are and if/how they should be connected, how do I set A0-A1-A2 if I need multiple expansions and I do even connect multiple expansions (all in parallel to SCL and SDA?) and most importantly, what is this
nonsense that I keep reading everywhere?
Code: Select all
sudo i2cset -y 1 0x20 0x00 0x80
When those additional pins are functional, shouldn't I be able to access them under /sys/class/gpio/ as well, or something similar, in a nicely numbered fashion, in other words won't I be able to treat them as files to write and read from within PHP?
I really need some guide that makes sense to me.