Search found 77 matches

by max.tisc
Sun Jun 16, 2024 11:56 am
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

ok but do the registers have to be created in the slave? and if so how is it done? you write the statement .value = GetValue(.reply, 4, 4) but does the getvalue function need to be defined? because it is not recognized
Sorry if I ask you questions that may seem silly to you
by max.tisc
Sat Jun 15, 2024 6:48 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

ok I changed the terminal and I read as you read, and from what I see the code already does a conversion of these 2 bytes and probably by increasing the count the third and fourth will join (if I interpreted correctly), but I have to give you a another question, if I send for example 20 bytes to the...
by max.tisc
Sat Jun 15, 2024 3:30 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

in ascii it reads this
by max.tisc
Sat Jun 15, 2024 3:01 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

now I have modified as you wrote but I find the master uart output populated by many numbers that do not correspond with those read by the I2C bus
by max.tisc
Sat Jun 15, 2024 11:28 am
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

the code is the last one you published, I haven't changed anything
Couldn't you save the data arriving at the master in a circular buffer and then take only the ones you need?
by max.tisc
Sat Jun 15, 2024 11:26 am
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

the code is the last one you posted.
by max.tisc
Sat Jun 15, 2024 10:45 am
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

Hi Martin, the sensor that sends data to the slave has an output pin that indicates when the raw data is available for reading so it should be easily manageable, what I see in the master's uart output are only 0 and not the entire sequence of bytes received
by max.tisc
Fri Jun 14, 2024 10:46 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

I'm sorry I wasn't clear enough. the data that will be transmitted from the slave to the master will be of the byte type and will be 20, (in the meantime, to do tests and understand how it works, even 4 is fine) then the master will have to take some of these bytes for example byte1 and 2 for the sp...
by max.tisc
Fri Jun 14, 2024 5:31 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

the sensor is SPI only in the examples you proposed, the second one seems to me to be the most suitable one, I did some tests but I don't get the desired results, even in simulation it doesn't seem to work correctly, returning single digits and not the complete number and when reading uarts, bad num...
by max.tisc
Wed Jun 12, 2024 4:57 pm
Forum: User Components
Topic: 2 Arduino I2C communication
Replies: 47
Views: 11602

Re: 2 Arduino I2C communication

Hi Martin, I was playing with the master software and I added the UART output but I don't read what I expected 1,2,3,4, I definitely did something wrong, but I wanted to ask you on the oscilloscope I see the transmission of writing A, B,C,D and then the reading request, the question is: is what I se...