{"action":"created","issue":{"url":"https://api.github.com/repos/tttapa/Control-Surface/issues/6","repository_url":"https://api.github.com/repos/tttapa/Control-Surface","labels_url":"https://api.github.com/repos/tttapa/Control-Surface/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/tttapa/Control-Surface/issues/6/comments","events_url":"https://api.github.com/repos/tttapa/Control-Surface/issues/6/events","html_url":"https://github.com/tttapa/Control-Surface/issues/6","id":323121641,"number":6,"title":"Motorised Faders ","user":{"login":"masydoblig","id":39230113,"avatar_url":"https://avatars0.githubusercontent.com/u/39230113?v=4","gravatar_id":"","url":"https://api.github.com/users/masydoblig","html_url":"https://github.com/masydoblig","followers_url":"https://api.github.com/users/masydoblig/followers","following_url":"https://api.github.com/users/masydoblig/following{/other_user}","gists_url":"https://api.github.com/users/masydoblig/gists{/gist_id}","starred_url":"https://api.github.com/users/masydoblig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masydoblig/subscriptions","organizations_url":"https://api.github.com/users/masydoblig/orgs","repos_url":"https://api.github.com/users/masydoblig/repos","events_url":"https://api.github.com/users/masydoblig/events{/privacy}","received_events_url":"https://api.github.com/users/masydoblig/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-05-15T08:46:52Z","updated_at":"2018-05-19T06:04:56Z","closed_at":null,"author_association":"NONE","body":"Looking through the files i can see that there are several ways to receive the incoming midi messages from Cubase 8.5 but i am using it a a generic remote. that way io can programm my own functions.\r\nand it works great.\r\nI have managed to get everything working except the shift registers :(  any help there with your schematics would be great. i think its my wiring that's wrong\r\n\r\nBut....\r\n\r\nHow can i modify this to give me the data from the MIDIcc message to control the motor fader controlled on a Hbridge for instance. https://github.com/codyhazelwood/motorized-fader-arduino such as this.\r\n\r\nOther than that this code is awesom and works great on my 2560 with HIDUINO. NICE WORK\r\n\r\nsorry im not very good a coding. i have been looking through all the LIB source code and i think i can do it in a similar way to your VU input for instance.\r\n\r\nIn cubase i have turned the transmit and receive button on and can see on the RX LED on the Board that every time i switch banks in cubase it is sending the data for the Fader position.\r\n\r\nI just cannot work out how to use it  :(\r\n![cubase](https://user-images.githubusercontent.com/39230113/40046311-00e87df0-5870-11e8-8e2c-119af155084e.png)\r\n\r\n```cpp\r\n#include <Control_Surface.h> // Include the library\r\n\r\nconst uint8_t velocity = 0b1111111; // Maximum velocity (0b1111111 = 0x7F = 127)\r\nconst uint8_t addresses[4][4] = {   // the note numbers corresponding to the buttons in the matrix\r\n  {  1,  2,  3, 13 },\r\n  {  4,  5,  6, 14 },\r\n  {  7,  8,  9, 15 },\r\n  { 10, 11, 12, 16 },\r\n};\r\n\r\n// Create a new instance of the class 'ButtonMatrix', called 'buttonmatrix', with dimensions 4 rows and 3 columns, with the rows connected to pins 2, 3, 4 and 5\r\n// and the columns connected to pins 6, 7 and 8, that sends MIDI messages with the notes specified in 'addresses' on MIDI channel 1, with velocity 127\r\nButtonMatrix<4, 4> buttonmatrix( {14, 15, 16, 17}, {18, 19, 20, 21}, addresses, 1, velocity);\r\n\r\nconst uint8_t BANK_LEFT = 0x2E;\r\nconst uint8_t BANK_RIGHT = 0x2F;\r\nconst uint8_t LED1 = 61;// Note number 60 is defined as middle C in the MIDI specification\r\nconst uint8_t LED2 = 62;\r\nconst uint8_t LED3 = 63;\r\nconst uint8_t LED4 = 64;\r\nconst uint8_t LED5 = 65;\r\nconst uint8_t LED6 = 66;\r\nconst uint8_t LED7 = 67;\r\nconst uint8_t LED8 = 68;\r\nconst uint8_t LED9 = 69;\r\nconst uint8_t LED10 = 70;\r\nconst uint8_t LED11 = 71;\r\nconst uint8_t LED12 = 72;\r\nconst uint8_t LED13 = 73;\r\nconst uint8_t LED14 = 74;\r\nconst uint8_t LED15 = 75;\r\nconst uint8_t LED16 = 76;\r\nconst uint8_t test = 60;\r\n\r\n//_____________________________________________________________________________________________________________________________________________________________________________________________\r\n\r\nMIDI_LED leds[] = {\r\n    {22, LED1, 1},\r\n    {23, LED2, 1},\r\n    {24, LED3, 1},\r\n    {25, LED4, 1},\r\n    {26, LED5, 1},\r\n    {27, LED6, 1},\r\n    {28, LED7, 1},\r\n    {29, LED8, 1},\r\n    {30, LED9, 1},\r\n    {31, LED10, 1},\r\n    {32, LED11, 1},\r\n    {33, LED12, 1},\r\n    {34, LED13, 1},\r\n    {35, LED14, 1},\r\n    {36, LED15, 1},\r\n    {37, LED16, 1},\r\n};\r\n\r\nDigital switches[] = {\r\n    {2, 0x10, 1, velocity}, \r\n    {3, 0x11, 1, velocity},\r\n    {4, 0x12, 1, velocity},\r\n    {5, 0x13, 1, velocity},\r\n    {6, 0x14, 1, velocity},\r\n    {7, 0x15, 1, velocity},\r\n    {8, 0x16, 1, velocity},\r\n};\r\n\r\nAnalog faders[] = {\r\n    {A0, MIDI_CC::Channel_Volume, 1},\r\n    {A1, MIDI_CC::Channel_Volume, 2},\r\n    {A2, MIDI_CC::Channel_Volume, 3},\r\n    {A3, MIDI_CC::Channel_Volume, 4},\r\n};\r\n\r\nDigital bankswitch[] = {\r\n     {9, BANK_LEFT, 1},\r\n     {10, BANK_RIGHT, 1},\r\n};\r\n\r\n//_____________________________________________________________________________________________________________________________________________________________________________________________\r\n\r\nvoid setup() {}\r\n\r\n\r\nvoid loop() {\r\n  // Refresh the MIDI controller (check whether the potentiometer's input has changed since last time, if so, send the new value over MIDI)\r\n  Control_Surface.refresh();\r\n}\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/tttapa/Control-Surface/issues/comments/390382500","html_url":"https://github.com/tttapa/Control-Surface/issues/6#issuecomment-390382500","issue_url":"https://api.github.com/repos/tttapa/Control-Surface/issues/6","id":390382500,"user":{"login":"masydoblig","id":39230113,"avatar_url":"https://avatars0.githubusercontent.com/u/39230113?v=4","gravatar_id":"","url":"https://api.github.com/users/masydoblig","html_url":"https://github.com/masydoblig","followers_url":"https://api.github.com/users/masydoblig/followers","following_url":"https://api.github.com/users/masydoblig/following{/other_user}","gists_url":"https://api.github.com/users/masydoblig/gists{/gist_id}","starred_url":"https://api.github.com/users/masydoblig/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masydoblig/subscriptions","organizations_url":"https://api.github.com/users/masydoblig/orgs","repos_url":"https://api.github.com/users/masydoblig/repos","events_url":"https://api.github.com/users/masydoblig/events{/privacy}","received_events_url":"https://api.github.com/users/masydoblig/received_events","type":"User","site_admin":false},"created_at":"2018-05-19T06:04:56Z","updated_at":"2018-05-19T06:04:56Z","author_association":"NONE","body":"so everything seems to be working,,,now all we need is some amazing tttapa code for the fader motors.\r\n\r\nso if i have this correct we will need to block the signal coming from the fader while the fader is getting moved by the daw. and make the code so the fader only sends a signal when the cap sense is active, ie the daw has priority over the fader movement,,,,and only when cap sense is active we need to give the fader send signal priority over the DAW fader control signal.\r\n\r\nps this code is still awesome\r\n"}}
{"actor":{"display_login":"masydoblig"}}