Last post by Delta_G - Today at 04:08 am
Well the error obviously lies somewhere in the part of the code you didn't post. Why don't you post something complete that compiles and exhibits this issue so someone can test for themselves.
Last post by yorgle - Today at 04:07 am
You're probably seeing that behavior with Ctrl-A-A because you get most of those key-down messages (at least for whatever the first two keys that are pressed, and then the keyboard controller resets itself and toggles the RESET line. You never actually get the key up messages. maybe. I haven't fully figured out the capabilities of the code provided here...
I'm working on new firmware which has slightly different wiring, to improve compatibility with A1000's speed and the A2000/3000 keyboard behaviors. -- Clock and data connect to pins D0 and D1 instead of D8 and D9. I am not yet ready to share this, but i will post on this thread when i am.
A2000/3000 have a different reset (ctrl-a-a) behavior than the A500.. You can simulate this by disconnecting Q1 from the circuit on your keyboard's controller. It won't be necessary for mine...
Last post by xrc11 - Today at 04:04 am
Well, I got some more clarification today at school. Someone had the idea to instead of trying to "change" the sampling time of the Uno, write the code for the Arduino so that it is made to sense voltage at a specified frequency. I was planning on using the AnalogRead function. Should I create a loop with say an if statement or while statement that calls on the AnalogRead function every .00125 seconds? Doing it this way I would have my time intervals already. Any help is appreciated
I have the following bit of code in my program. I'm using a char variable to hold the state of some input buttons. Using the PC serial port to debug.
char newbuttons; // holds button state if it changed
int newbuttons2; // integer version of buttons
// TEST CODE!
PC.print("New Buttons = ");
PC.print("New Buttons (int) =");
// END TEST CODE
This code is part of a larger loop that repeats.
When I run this it continually prints 'New Buttons = 0 & New Buttons (int) = 0'
How is this even possible, when this code is only supposed to execute when newbuttons2 is > zero?
BTW, I also tried newbuttons != 0, newbuttons>0 and newbuttons2!=0 with same result.
Also tried it with HEX instead of DEC, same result
This is just one bit of a much larger program, but I can't get this little section to function correctly.
Any thoughts? Compiles and executes without any other obvious errors except this bit...
Last post by mauried - Today at 03:58 am
To read data from a USB device, the host port has to know what class of device it is , in order to know how to read the data.
You cant read an unknown data format at an unknown data rate.
Try plugging the Behringer device into a PC and see if the PC recognises it , as that will at least give you an idea of what class of device it is.
But you will still need to know something about the data format that the Behringer device uses, as for example how to start it sending anything.
I can do the something else on other pins
That sounds like a really good idea.
Last post by J-M-L - Today at 03:52 am
You need some sort of a state machine with the "doing multiple thing at the same time" approach using millis() you should read the post pinned at the top of the forum
The loop reads the distance from time to time, like x times per second (use the millis technic and no delay for this) and not block code for long
Based on the last read value decide what the PWM does. Same thing here - this should be based on its own timing using similar milli. remember previous animation stage and adapt to the cycle you want to see, do one step (increasing) at the right time
Same goes for the piezo or relays
Last post by 45gfg9 - Today at 03:51 am
There is an internal function named init() which is used to set up the timers for (among other things) the timing functions. It is called immediately before setup().
Rename your init() function to something else and that should fix the problem.
I renamed init() to S7init()
Get rid of the window store app and download the proper IDE.
Many people have mentioned issues with the APP version and most seem to be OK once they go to the real IDE.
The programmer wont matter for the NANO as the IDE will use what it needs in that regard.