02-16-2019 07:48 AM
Hi everyone,
I'm having some troubles to get my PIC (18F248) to communicate with my MyRio 1900 Board through i2c.
In my case, the PIC must be the master and the MyRio the slave.
Does anyone know how to make the MyRio act as a slave on i2c bus ? (with FPGA for example)
Thank you !
Solved! Go to Solution.
02-20-2019 04:21 AM
Hi Antoine,
It would be helpful if you gave us more details on the issue you are facing. Have you done anything so far ? If you have written some code and the code does not work, feel free to post it here so we can give advice, as well as a detailed description of the issue you have.
If you do not have any code yet, then you can have a look here : https://forums.ni.com/t5/Examples-and-IP-for-Software/I2C-IP/ta-p/3491271
This code is not written from with the myRIO in mind, but the FPGA generally does not change a lot from platform to platform. You should be able to modify it to fit your needs. Here us an example that uses this code :
https://forums.ni.com/t5/Examples-and-IP-for-Software/I2C-Example-for-the-NI-PXIe-5644R/ta-p/3491762
Thomas
02-20-2019 08:52 AM
Thanks !
Actually I had found this code before but I thought it hasn't been updated for my Labview version (2017) since I wasn't able to download it in VI Package Manager, thanks to you I find it has been and it works now !
I had a bit of code but it only worked for detecting a start or stop condition, I was stuck with the adress detection part (and data detection actually), Bit out was always false, never true...
Thanks a lot, no need to reinvent the wheel !