diff options
author | MitchBradley <wmb@firmworks.com> | 2019-03-20 13:56:58 -1000 |
---|---|---|
committer | MitchBradley <wmb@firmworks.com> | 2019-03-20 13:56:58 -1000 |
commit | e7b034611baf93d769b8fe7787714fb5b07843bf (patch) | |
tree | bfc96769c6107e754158908ce3d1c36a741c9cb6 | |
parent | b0c32e89a2c8098a7a81c66da3dc2f7f6bb0fcc8 (diff) | |
download | cforth-e7b034611baf93d769b8fe7787714fb5b07843bf.tar.gz |
Added GPIO notes for ESP32
-rw-r--r-- | src/app/esp32/gpio-notes.txt | 100 |
1 files changed, 100 insertions, 0 deletions
diff --git a/src/app/esp32/gpio-notes.txt b/src/app/esp32/gpio-notes.txt new file mode 100644 index 0000000..877d17b --- /dev/null +++ b/src/app/esp32/gpio-notes.txt @@ -0,0 +1,100 @@ + +$3ff44000 constant gpio-base + +output register 0..31 3ff44004 00030000 bits 16,17 +output register 32..39 3ff44010 0000 +output enable reg 0..31 3ff44020 00030000 bits 16,17 +output enable reg 32..39 3ff4402c 0000 +bootstrap values 38 13 bits 4,1,0 +input register 0..31 3ff4403c 0002cae9 bits 17 15 14 11 9 7 6 5 3 0 +input1 register 32..39 3ff44040 00000000 +intr status 0..31 3ff44050 00000000 +intr status1 32..39 3ff44054 00000000 + +Pin registers 0..39 are all 0 except for 16, 17 which are 4 +0 is wakeup disabled, interrupt disabled +4 is open-drain (set by #16 #17 i2c-open) + +function sel input register 0..39 are all 0x30 exc 20,21,22,29,30 at 38 (base 4130) +80 means bypass gpio matrix +40 means invert input value + +0x30 means force low +0x38 means force high +values between 0..39 decimal selects a matrix input pin + +function sel output register 0..39 are all 0x100 exc (base 4530) +16 5f #95 +17 60 #96 +20 101 +21 101 +22 101 +29 101 +30 101 + +100 selects bit N of GPIO_DATA_REG and GPIO_ENABLE_REG + + +iomux gpio regs 0..38 are all 800 exc +36 4 b00 in up fun1 gpio +37 8 a80 in dn fun1 gpio +38 c 2b00 in up fun3 gpio +39 10 2b00 in up fun3 gpio +34 14 1b00 in up fun2 ???? +35 18 1b00 in up fun2 ???? +32 0c 1b00 in up fun2 ???? +33 20 1700 in up fun2 ???? drive 1 +25 24 1b00 in up fun2 ???? +26 28 1b00 in up fun2 ???? +27 2c b00 in up fun1 ???? +14 30 a00 in - fun1 mtms +12 34 a00 in - fun1 mtdi +13 38 a00 in - fun1 mtck +15 3c a00 in - fun1 mtdo +02 40 a00 in - fun1 gpio +00 44 b00 in up fun1 gpio +04 48 a00 in - fun1 gpio +16 4c a00 in - fun1 gpio + +0xxx is func 1 +1xxx is func 2 +2xxx is func 3 + +400 is drive strength 1 +800 is drive strength 2 +c00 is drive strength 3 + +200 is input enable + +100 is pullup enabled + 80 is pulldown enabled + +7f is sleep mode configuration + + +Rtc out 3ff48400 0 +rtc OE 3ff4840c 0 +rtc IS 3ff48418 0 +rtc in 3ff48424 4a000000 30-14=16 27-14=13 26-14=12 +rtc pin reg .+28 0..17 all 0 +hall 3ff38078 0 +sensor pads 3ff3807c 0 +adc pad 80 0 +pad dac1 84 80000000 +pad dac2 88 80000000 +xtal 8c 84100000 +touch cfg 90 66000000 +touch 0..9 +.94 +0 52000000 +1 4a000000 +2 52000000 +3 4a000000 +4 52000000 +5 52000000 +6 4a000000 +7 4a000000 +8 02000000 +9 02000000 + +ext wakeup bc 0 +rtc i2c pad sel c4 0 |