bogsnork / catears Goto Github PK
View Code? Open in Web Editor NEWanimatronic cat ears
License: GNU General Public License v3.0
animatronic cat ears
License: GNU General Public License v3.0
from: @nogirvine :
I think what you are doing here is fine, I would be tempted here to us
else if
for putting servos relating tobutton1state
to some other positionif == LOW
. Eg. your return positions when the pin goes low could be put in the else if rather than the whole sequence running on one button push perhaps.
Then use a newif
statement to determine state forbutton2state
.
I would be tempted, rather than write each action here for each button push, to build separte functions for the control of the servos TL, BL,TR, BR, which were passed variables from the button pushing code. Should half the amount of overall code and allow you to write more complex scenarios for multiple button pushes more easily. Build these below wherevoid loop();
finishes and then call them form in thevoid loop()
; part.
some stuff on the internet about it such as this http://forum.arduino.cc/index.php?topic=1881.0
Line 80 in c20e6b4
button 1 press works but button 2 doesn't do anything. Can't work out whether it's code or wiring.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.