4 Replies Latest reply on Feb 22, 2017 5:00 AM by userc_38867

    Proximity shield + BLE - Not working

      Hi there,


      I made a project on the Psoc 4200 (non ble version) and I want to move it to Psoc4 4200BLE, so I did the following:


      -changed target device


      -updated components


      -changed the pins (I looked at the board and shield and 'matched' the pins) both for the shield and leds and proximity loop, also chenged the target for the rgb led (as I am using it in my project)


      My project runs based on a 1ms task that calls 2 sensors and interprets the movement (on one axis) as swipe or swipe & hold or reset. Based on what it detects it drives a state machine and that way I call the appropriate functions for what I want to do.


      What I want to do with the 4200ble send those commands (as a uint8) via BLE from CySmart (next step being an phone app). What I want to get is a behavior like this: I send 1 I want to execute the command X, if I send 2 command Y, etc. all while my original program still works and it reads for gesture input via Proximity shield.


      I looked at the Cypress Youtube video "How to Create a PSoC BLE App" and I just added in my project a BLE component and configured it in a similar way (my service should just read one value, and according to it register a gesture and then call the appropriate function) and also I wrote the code as showed in the video (for the Handler).


      Now, my problem is that nothing from my original project works anymore, not the Proximity Shield(LEDs don't light up when I hover my hand above and not sensors are red to register gestures); the BLE component sort of works, only that sometimes (like 4/5 tries) it will display the error message "Exchange GATT MTU Size timed out"(gpm.M0117) and also it will fail to reconnect after I disconnect.


      My reading gesture is based on task (for now I decided to call it every 1ms) and my BLE handler (via "CyBle_ProcessEvents") is called each 100ms.


      What should I do? Is there a compatibility problem with the shield working in the same time with the BLE? How do I configure the Psoc4200BLE to work with that shield?


      Where do I find some example code on how should I configure and write some code so that the BLE will just recieve one number and send it to some function that will do something?