Synthesizing heartbeat sound from pulse sensor data

Hi guys, currently my project involves:

2 x uno boards
2 x hc05 modules, one master one slave
a bunch of led lights controlled by 1 uno board with the slave hc05
a pulse sensor connected to 1 uno board with master hc05

the current idea is pretty simple, users use the pulse sensor that's connected to the master hc05, then the hc05 sends control signals (1 for saw heartbeat, lights should pulse and 0 for did not see heartbeat, do not pulse)to slave hc05 that controls the led lights to pulse with the pulse readings.

now I want to update this program so that I can use max map connected to the slave hc05 and Arduino Uno to synthesize a heartbeat sound with the pulse sensor readings as amplitude envelope. Was wondering how I can achieve this.

The problem right now is that in order for max to generate a heartbeat sound, it needs all the readings of a pulse, not a control signal (0 or 1), which is currently what the slave hc05 and board is getting. However, if the master sends all the pulse sensor readings, the slave side will need to process the readings to find a heartbeat, which was taken care of by pulsesensorplayground.h on the master Arduino Board. Any ideas how to tackle this?

Thanks

Why can't the master get the readings, analyze them AND send them? Is there some reason it needs to be OR?

Hi Paul,

The master is connected to the pulse sensor so it is getting all the available readings from the pulse sensor. However right now, it is sending only 0 and 1s to the slave that controls the led lights. The slave is also connected to a laptop that can run max msp, but this requires full readings from the pulse sensor, not just 0 and 1s. This would then require the master to send full readings to the slave but in this fashion the slave will not be able to use the pulse sensor library apis to process the readings, which makes use of interrupts.