Forum Rule: Always post complete source code & details to reproduce any issue!

Search:

Type: Posts; User: DanieleFromItaly

Search: Search took 0.00 seconds.

  1. No words.. It is incredible the time that is lost...

    No words.. It is incredible the time that is lost for stupid mistakes :(

    Thank you !

    Daniele.
  2. Teensy 3.2 - Wrong (?) readings from mcp23017/i2c

    Hello guys, I'm trying to read pin status of a mcp23017 in one shot using the Adafruit_mcp23017 library (https://github.com/adafruit/Adafruit-MCP23017-Arduino-Library);

    The sketch:



    #include...
  3. Trying new libs

    Hello guys, after almost a year I'm still here..:cool:
    Now I'm trying this lib: https://github.com/maxgerhardt/rotary-encoder-over-mcp23017

    I've the polling example running fine with 1 encoder....
  4. This sketch:...

    This sketch: http://www.g7smy.co.uk/2014/08/rotary-encoders-on-the-i2c-bus/ with polling instead of interrupt, works.
    So something in interrupt setup is not ok in previous sketch.. :(
  5. Hi, I did all the changes you suggest me,...

    Hi, I did all the changes you suggest me, nothing.
    I added some debug ouput and if I manually short interruptPin to gnd, the sketch works !
    So the problem is on the the mcp side.
    13627

    I've:...
  6. teensy-3.2, mcp23017 with encoders & interrupt..

    HI guys, I'm trying to use this sketch: https://github.com/raspibo/I2C_rotary_encoder/blob/master/I2C_rotary_encoder.ino..
    First of all, a basic sketch like this:...
  7. What about Keypad library ? 4x4 matrix without...

    What about Keypad library ?

    4x4 matrix without additional IC:


    /* @file MultiKey.ino
    || @version 1.0
    || @author Mark Stanley
    || @contact mstanley@technologist.com
    ||
  8. Replies
    2
    Views
    905

    Great ! Test sketch: String nname[] =...

    Great !

    Test sketch:


    String nname[] = {"C", "C#", "D", "D#", "E", "F", "F#", "G", "G#", "A", "A#", "B"};
    int mname;
    int oc;

    void setup() {
  9. Replies
    2
    Views
    905

    convert midi note to note name

    Hi, how to convert mdi note to note name?

    0 ->C0
    51 -> D#3
    ..

    First thing that comes to my mind is an big array of string: string name[] ={"C0","C#0,"D0"....}

    Are there better...
  10. Ah ok, thanks ! Daniele.

    Ah ok, thanks !

    Daniele.
  11. Replies
    11
    Views
    2,801

    Sorry, my mistake. int32_t enc1_val = 0; needs to...

    Sorry, my mistake. int32_t enc1_val = 0; needs to be outside setup(), otherwise there's a scope error in loop().

    Last question, is there a way to rewrite the encoder value ? Something like...
  12. Replies
    11
    Views
    2,801

    Thanks ! Example sketch with 4 counts default...

    Thanks ! Example sketch with 4 counts default config works fine !

    But I' have some trouble make it working in a real sketch. I would call read() inside loop() but with begin() inside setup(),...
  13. Replies
    11
    Views
    2,801

    What exactly ? As I wrote, with Encoder lib, I...

    What exactly ? As I wrote, with Encoder lib, I get 4x count (as expected..). Do I need QuadDecode lib from linked thread ?
    Or is about polling vs interrupt ?

    Thanks,
    Daniele.
  14. Replies
    11
    Views
    2,801

    How to use encoders as pot

    Hi guys, I want to use few encoders as pot, it's a midi controller so at the end, I need to read 0-127.

    Encoders are cheap ALPS.
    With the encoder lib, I get 4 values for each step (1 2 3 4 - 5 6...
  15. Simplified midithru

    HI guys, for a simple midithru (serial<->usb), do I need the whole midithru() function posted in this thread or can be semplified ? A very simple "pass everything as is".

    Thanks,
    Daniele.
  16. Hi, ehm.. ERR_CONNECTION_TIMED_OUT Daniele.

    Hi, ehm.. ERR_CONNECTION_TIMED_OUT

    Daniele.
  17. Right, 5v. So you need 5v for the input part....

    Right, 5v. So you need 5v for the input part. Not sure about the output.. Do you already have that board ?
    Daniele.
  18. Why 5v ? 3.3v is ok for midi output. Daniele.

    Why 5v ? 3.3v is ok for midi output.

    Daniele.
  19. Two more questions before start soldering.. Can...

    Two more questions before start soldering..
    Can I get 3.3v from the 5v with voltage divider (47k+91k)? One wire less..
    Can I attach a led to show midi activity ? I think that should be ok to attach...
  20. Thanks Paul, works fine with 3.3v. 10259 A...

    Thanks Paul, works fine with 3.3v.

    10259

    A bit ugly but it's only for a quick test.

    Daniele.
  21. Well my 6n137 is this: 6N137.pdf...

    Well my 6n137 is this: 6N137.pdf and is 5v.

    So what to do ?

    Sorry for these silly questions but I came back to this hobby after 20 years so I need to relearning almost everything :(

    Thanks,...
  22. Output done! Used 2 62 ohm resistor 'cause I...

    Output done! Used 2 62 ohm resistor 'cause I don't have 0.5w resistor right now..
    Tomorrow I'll test the input.
    I still don't understand if the 6n137 works with 3.3v. In some datasheet is 4.5-5.5...
  23. I suspected it... asked just to be sure. ...

    I suspected it... asked just to be sure.



    The optocoupler 6n137..
    I guess the answer ;)

    Thanks guys !
    Daniele.
  24. Thanks and if may ask, what do you think about...

    Thanks and if may ask, what do you think about this: http://karg-music.blogspot.it/2016/01/midification.html. On midi out there is only 220 ohm resistor to 3.3v and the 6n137 is fed by 3.3v but the...
  25. Hi guys, I'm making a midi interface too and I...

    Hi guys, I'm making a midi interface too and I have a doubt but for the output..
    For the midi spec, with 3.3v, there should be a 10ohm 0.25w resistor from UART to pin 5 and 33 ohm 0.5w from v+ to...
  26. Which lib ?

    Hi guys, first post here so first of all, HELLO ! And sorry for my bad english.

    Now, I'm here with Teensy 3.2 and my first Lcd 16x2 with i2c adaptor based on PCF8574AT chip.

    So which lib ?...
Results 1 to 26 of 26