Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Follow the link posted here, when available (expected by Saturday, 9/14 latest):

(not yet avail)

main.c - the application main code, with task/thread definitions and functional logic.

ble.h/.c - this is for some Bluetooth (In this case, BLE, or Bluetooth Low Energy) setup. I filled all of this in because its complicated and out of scope, you do not need to edit this at all. With that being said, feel free to look at it and try to make sense of it. Feel free to ask my if you have any questions.

api.h/.c - These are the function calls you may need to use. While you should be able to complete the task using just this and other simple calls, you do not necessarily need to if you do not want. The purpose of this was to hide some of the messy , ESP32, Bluetooth, and FreeRTOS syntax from you, and instead provide more clear APIs. Again, you do not need to edit this, but I encourage you to see what these do, since you' have to make calls to these functions. On top of the APIs defined there, I’ve included a comment in api.h with some more function signatures that you have access to that I found helpful to complete the task. Note: I did not create APis to hide FreeRTOS stuff, since you should become familiar with them !

Note

When testing with the magnet, do not let the magnet touch the board. It is a big piece of metal, and can short components together. It doesn't need to be too close to work!

...

  1. continuously read magnetic field data

  2. blink an LED based on the strength of that field (stronger field == faster blinking)

  3. Utilize an interrupt (ISR) to trigger the LED blink

  4. Broadcast the raw data over Bluetooth

  5. Broadcast this data over serial monitor

To complete this, find the comments labeled

...

This indicates some functionality that you must implement - and usually follows up with an explanation of what needs to be done. This should be doable with only the API functions in api.h/.c, the other function signatures shown in a comment within api.h, and some simple C logical code. You do not need to edit anything that isn't given a “TODO” comment

That's all! You are not expected to necessarily know anything about freeRTOS, interrupts, or any of these skills; Just because I haven’t in detail explained these things in this doc does not mean you are expected to understand it. I literally am keeping these instructions somewhat vague intentionally to ensure I don't sway you towards doing this a certain way, because there are multiple ways to do it. Ask questions, do some individual investigation, or use whatever tools you want to help. freeRTOS and interrupts are used extensively in our vehicle apps, so getting some experience with them here will help out.

...