![Pizza tower snick mod](https://cdn1.cdnme.se/5447227/9-3/2_64e61dfa9606ee7f98e9879b.png)
![modify arduino wire library modify arduino wire library](https://i.stack.imgur.com/wXNYn.png)
i have assessed that problem is in requestEvent function of slave as that either doesnt send anything. Problem only appears when master requests data from another arduino slave (master sends data successfully to slave arduino but vice versa is not true). Definitely there is something wrong with my approach. Unable to do what i was upto i resorted to example sketches of Wire library to assess what i was doing wrong and to my surprise even example sketches were not working. I am not able to receive bytes from slave arduino. then i wanted to establish i2c communication between 2 arduinos such that both exchange each other's sensors data.
![modify arduino wire library modify arduino wire library](https://spiceman.jp/wp-content/uploads/2021/10/arduino-wire-library-768x512.jpeg)
You can simply navigate up a couple of folder levels to get to the Wire folder.I tried i2c EPROM and that worked pretty fine with arduino master. That will open the folder of the example sketch, which is under the Wire library installation folder.
![modify arduino wire library modify arduino wire library](http://ardiri.com/blog/entries/20151117/onewire-fritzing.png)
Hardware packages installed via Boards Manager are installed to a different location. To make things more confusing, the version of the Arduino AVR Boards hardware package bundled with the Arduino IDE is only used if you haven't installed a different version via Boards Manager (Tools > Board > Boards Manager). If you have one of the Arduino SAMD Boards (Zero, MKR, etc.) selected, a different version of the Wire library will be used. The path above is the Wire library used by the Arduino AVR Boards (Uno, Leonardo, Mega, etc.).
![modify arduino wire library modify arduino wire library](https://hackster.imgix.net/uploads/attachments/308523/normal_bb_ZpQHcGZ8Zl.jpg)
The reason for this is that the Wire library is architecture-specific so each architecture needs to write the library differently. You should be aware that each hardware package comes with its own version of the Wire library, which is used when a board of that hardware package is selected from the Arduino IDE's Tools > Board menu. I think you've been given some good advice already, but since you are showing a desire to look/play around in the libraries, it may be useful for you to understand the way the Arduino IDE handles this type of library: C:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\Wire\src
![Pizza tower snick mod](https://cdn1.cdnme.se/5447227/9-3/2_64e61dfa9606ee7f98e9879b.png)