I have an automation:bit which works well for turning things on and off but now I want to add a simple touch control. in the past I have used a routine which averages analog reads to set an untouched threshold for a pin and then a similar process to get a touched value which is hope fully different. However as part of the averaging process I reset the pin to high after each read. In makecode I can do this by doing a digital write following the analogue read on the same pin but it looks as though this is not possible with the automation:bit as digital and analogue seem to be separated. can anyone suggest a way I can do this? ideally in makecode?
I was thinking those exact thoughts when I posted it.
I have a couple of Micro Bits, I don’t have an automation bit though. Just some breakouts that plug into a solderless bread board.
Another option is to use the cricket for the Micro bit.
Capacitive touch support built in and almost everything the automation bit has. I think all its missing is the relay.
thanks again for the reply, i have looked at the crikit before and will probably get one whether or not i use it for this project. I actually got the touch function working without any extra hardware although i have no idea how or why!
I have the Pi version of the Crickit. Haven’t done much with it so far. Trying to remeber why I bought lol.
Now that it is working I’d make a backup image of that card. ;)