{"action":"created","issue":{"url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/10466","repository_url":"https://api.github.com/repos/RIOT-OS/RIOT","labels_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/10466/labels{/name}","comments_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/10466/comments","events_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/10466/events","html_url":"https://github.com/RIOT-OS/RIOT/pull/10466","id":384307814,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMzNTQwMDUz","number":10466,"title":"boards/common/stm32f103c8: Fixed I2C configuration","user":{"login":"maribu","id":2041729,"node_id":"MDQ6VXNlcjIwNDE3Mjk=","avatar_url":"https://avatars0.githubusercontent.com/u/2041729?v=4","gravatar_id":"","url":"https://api.github.com/users/maribu","html_url":"https://github.com/maribu","followers_url":"https://api.github.com/users/maribu/followers","following_url":"https://api.github.com/users/maribu/following{/other_user}","gists_url":"https://api.github.com/users/maribu/gists{/gist_id}","starred_url":"https://api.github.com/users/maribu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/maribu/subscriptions","organizations_url":"https://api.github.com/users/maribu/orgs","repos_url":"https://api.github.com/users/maribu/repos","events_url":"https://api.github.com/users/maribu/events{/privacy}","received_events_url":"https://api.github.com/users/maribu/received_events","type":"User","site_admin":false},"labels":[{"id":718655339,"node_id":"MDU6TGFiZWw3MTg2NTUzMzk=","url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/Area:%20boards","name":"Area: boards","color":"6600ff","default":false},{"id":135467271,"node_id":"MDU6TGFiZWwxMzU0NjcyNzE=","url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/Area:%20drivers","name":"Area: drivers","color":"6600ff","default":false},{"id":214816571,"node_id":"MDU6TGFiZWwyMTQ4MTY1NzE=","url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/CI:%20ready%20for%20build","name":"CI: ready for build","color":"66ffcc","default":false},{"id":23399098,"node_id":"MDU6TGFiZWwyMzM5OTA5OA==","url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/Type:%20bug","name":"Type: bug","color":"ffff66","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-11-26T12:26:28Z","updated_at":"2018-12-13T10:04:09Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/10466","html_url":"https://github.com/RIOT-OS/RIOT/pull/10466","diff_url":"https://github.com/RIOT-OS/RIOT/pull/10466.diff","patch_url":"https://github.com/RIOT-OS/RIOT/pull/10466.patch"},"body":"### Contribution description\r\nIn commit e90f2b439e37db7cce0bb929932aaef847830e24 the I2C config has been adapted to the new I2C API. However, the pins of I2C_DEV(0) have been changed from PB6 and PB7 to PB8 and PB9. While PB8 and PB9 also can be used for I2C1 by remapping I2C1, this is not done. As a result, I2C1 was unusable. This commit restores the default I2C1 pins for I2C_DEV(0), resulting in I2C_DEV(0) becoming usable again.\r\n\r\n### Testing procedure\r\nTesting can be done using `tests/periph_i2c` and either an I2C slave device or an logic analyzer. Either connect the I2C device or the logic analyzer to the I2C1 interface:\r\n\r\n- Before this PR: `scl = PB8`, `sda = PB9`\r\n- After this PR: `scl = PB6`, `sda = PB7`\r\n\r\nIn the shell type:\r\n - `i2c_acquire 0`\r\n - `i2c_write_byte 0 42 13 0` (or something that makes sense to the attached I2C device)\r\n\r\nBefore this PR the second command will result in RIOT getting stuck in an endless loop and the logic analyzer will detect no level change on either SCL or SDA pin. With the PR the command should complete. When using a logic analyzer the command will report a  transmission failure as no I2C device responds, but the logic analyzer will show valid I2C communication. With an I2C device and a command that makes sense to it the communication should succeed.\r\n\r\n### Issues/PRs references\r\n\r\nNone"},"comment":{"url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/comments/446911267","html_url":"https://github.com/RIOT-OS/RIOT/pull/10466#issuecomment-446911267","issue_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/10466","id":446911267,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0NjkxMTI2Nw==","user":{"login":"aabadie","id":1375137,"node_id":"MDQ6VXNlcjEzNzUxMzc=","avatar_url":"https://avatars3.githubusercontent.com/u/1375137?v=4","gravatar_id":"","url":"https://api.github.com/users/aabadie","html_url":"https://github.com/aabadie","followers_url":"https://api.github.com/users/aabadie/followers","following_url":"https://api.github.com/users/aabadie/following{/other_user}","gists_url":"https://api.github.com/users/aabadie/gists{/gist_id}","starred_url":"https://api.github.com/users/aabadie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aabadie/subscriptions","organizations_url":"https://api.github.com/users/aabadie/orgs","repos_url":"https://api.github.com/users/aabadie/repos","events_url":"https://api.github.com/users/aabadie/events{/privacy}","received_events_url":"https://api.github.com/users/aabadie/received_events","type":"User","site_admin":false},"created_at":"2018-12-13T10:04:09Z","updated_at":"2018-12-13T10:04:09Z","author_association":"CONTRIBUTOR","body":"> your change made the pin configuration more consistent with other STM32 boards\r\n\r\nI think I did that with nucleo boards in mind. Most of them are using PB8/PB9 for the I2C available on the Arduino pinout. This board is not using the same pinout (like iotlab-m3 for example) so it makes sense to keep PB6/PB7. But I agree remapping will be a nice to have feature."}}
{"actor":{"display_login":"aabadie"}}