cu-ecen-aeld / final-project-assignment-MohitRane8

final-project-assignment-MohitRane8 created by GitHub Classroom
0 stars 0 forks source link

Implement shared memory on BBB #21

Closed MohitRane8 closed 4 years ago

MohitRane8 commented 4 years ago

DoD: Create shared memory that can be accessed by 2 writer tasks and 1 reader tasks (writer tasks would be the sensor tasks (lux and capacitive sensors) and reader tasks would be UART Tx task). There should be no data corruption. Lux sensor task writes in shared memory every 2 seconds. Capacitive sensor task writes in shared memory every 500 ms. UART Tx task reads that data from shared memory and transmits it to TIVA. The syslog/print statements should show the values loaded/read by each task. The values received at UART Tx should match with the ones loaded by sensor tasks.

Verify another shared memory implementation in same way where the writer task will be UART Rx (receiving data from TIVA) and 2 reader tasks (actuation task and logger task). There should be no data corruption.

Status: DoD verified

steveantony5 commented 4 years ago

@MohitRane8 Don't forget that you need to use locks. You can use reader/writer lock to reduce contention (as you have 2 readers) .

steveantony5 commented 4 years ago

@MohitRane8 Are you planning to have a shared circular buffer?

MohitRane8 commented 4 years ago

I am not having a circular buffer implementation. I am populating a struct in the writer tasks with the values of interest and placing it in shared memory which can be read by reader tasks.

Updated DoD and status.