adafruit / seesaw

I2C friend to expand capabilities of other chips.
Other
76 stars 34 forks source link

Digital Write for All Pins #22

Open wallarug opened 5 years ago

wallarug commented 5 years ago

GDay,

I already mentioned it over at the Adafruit_CircuitPython_Seesaw GitHub. However, it is probably more important to talk about it here as this is where it will need to be implemented the most.

At the moment, it appears that each pin only responds to what function is set in board_config.h.

>>> from rm_robohat import robohat
>>> ss = robohat.seesaw
>>> ss.pin_mode(21, ss.OUTPUT)
>>> ss.digital_write(21, True)

For example: If you have PA16 configured as a PWM pin, this pin can now only do PWM and will not respond to any other commands sent to it for GPIO. I have tested by attempting to write to the GPIO register a output value for PA21 (my LED pin) but nothing happens. Arduino and CircuitPython do not share this behaviour and are able to adapt (as far as my testing has shown).

The CircuitPython SeeSaw software library appears to support this functionality already - writing to the correct registers for pins - but no output appears.

From a functionality point of view, the expected behaviour should allow digital IO on all pins regardless of how they are configured.

Would be great if you could provide your thoughts on this @deanm1278 as you have a lot of experience with SeeSaw.

ladyada commented 5 years ago

hiya, there's nobody currently maintaining on or working on seesaw, if you want some more capabilities in seesaw you will have to implement them on your own - we have lots of code you can use, but we wont be able to dedicate any time soon to assisting you.