I have two questions actually. First of all, is it illegal to use more than 1 custom circuit in the robot, is there a limit? Secondly, I need to send information from arduino to roborio (we’ll have custom circuit and custom sensors that do not connect to roborio directly) How do i do it without buying any parts, because I’m in Turkey and it’ll take 3-4 weeks for them to arrive here.
To answer the first part of your question: in the past there has not been a limit on the number of custom circuits in the robot, other than that all other rules must be followed such as what the circuit is used for and the overall cost limits.
As always in FRC, past rules are no guarantee of future rules. But on this one you are probably safe that it will not change.
For your second, you can hook up the Arduino to the roboRIO I2C bus. In this setup, the Arduino has to be a slave device. You can do this with just wires.
One option for connection is to directly hook up the arduino over usb to the roborio. This provides power, and you can use a serial connection to communicate between the roborio and the arduino. I’ve done this most often in the past because it’s a single wire and fairly easy to program.
How do you do it? By using RXTX? What are names of the ports of Roborio (for example “COM1” etc for windows). When i tried it, it broke the roborio’s comm.
I’ve had great success doing one-way communication with I2C on the cRIO, but I’ve never tried two-way or done any on the RoboRIO, but I do believe its very similar. Here is my Java code for getting data from the Arduino with a cRIO. I’ll put the arduino code on GitHub later tonight and upload it to a new repo. If you have any questions please PM me.