Difference between revisions of "Component: Pulse Oximeter (Max30100) (Environmental)"
From Flowcode Help
Jump to navigationJump to search(4 intermediate revisions by the same user not shown) | |||
Line 64: | Line 64: | ||
''<span style="color:red;">No additional examples</span>'' | ''<span style="color:red;">No additional examples</span>'' | ||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
+ | |||
Line 69: | Line 79: | ||
==Macro reference== | ==Macro reference== | ||
+ | ===Initialise=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Initialise''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Sets up the I2C bus ready for communications with the sensor IC. Must be called once before calling any of the other component macros. Applies the defauilt settings from the component properties. |
|- | |- | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
+ | ===ReadIR=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
Line 95: | Line 107: | ||
+ | ===ReadRed=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
+ | |- | ||
+ | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''ReadRed''' | ||
+ | |- | ||
+ | | colspan="2" | Returns one of the FIFO Red readings from the last update | ||
+ | |- | ||
+ | |- | ||
+ | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT | ||
+ | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
+ | |} | ||
+ | |||
+ | |||
+ | ===SetHighResModeEnabled=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
Line 113: | Line 140: | ||
+ | ===SetLEDsCurrent=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetLEDsCurrent''' |
|- | |- | ||
| colspan="2" | | | colspan="2" | | ||
Line 122: | Line 150: | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IR |
+ | |- | ||
+ | | colspan="2" | Range: 0-15 / 0=0mA, 1=4mA, .., 14=46mA, 15=50mA | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Red | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Range: 0-15 / 0=0mA, 1=4mA, .., 14=46mA, 15=50mA |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 131: | Line 164: | ||
+ | ===SetLEDsPulseWidth=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetLEDsPulseWidth''' |
|- | |- | ||
| colspan="2" | | | colspan="2" | | ||
Line 140: | Line 174: | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | PulseWidth |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 149: | Line 183: | ||
+ | ===SetSamplingRate=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetSamplingRate''' |
|- | |- | ||
| colspan="2" | | | colspan="2" | | ||
Line 158: | Line 193: | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | SampleRate |
|- | |- | ||
− | | colspan="2" | Range: 0- | + | | colspan="2" | Range: 0-7 / 0=50Hz, 1=100Hz, .., 6=800Hz, 7=1000Hz |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 172: | Line 202: | ||
+ | ===Update=== | ||
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
Line 183: | Line 214: | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
Latest revision as of 11:57, 3 November 2023
Author | Matrix TSL |
Version | 1.0 |
Category | Environmental |
Contents
Pulse Oximeter (Max30100) component
Sensor designed to monitor heart rate and pulse omimetry. Connected using an I2C bus.
Component Source Code
Please click here to download the component source project: FC_Comp_Source_Max30100_Pulse_Oximeter.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_Max30100_Pulse_Oximeter.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
Initialise
ReadIR
ReadIR | |
Returns one of the FIFO IR readings from the last update | |
- UINT | Return |
ReadRed
ReadRed | |
Returns one of the FIFO Red readings from the last update | |
- UINT | Return |
SetHighResModeEnabled
SetHighResModeEnabled | |
- BYTE | Enabled |
- VOID | Return |
SetLEDsCurrent
SetLEDsCurrent | |
- BYTE | IR |
Range: 0-15 / 0=0mA, 1=4mA, .., 14=46mA, 15=50mA | |
- BYTE | Red |
Range: 0-15 / 0=0mA, 1=4mA, .., 14=46mA, 15=50mA | |
- VOID | Return |
SetLEDsPulseWidth
SetLEDsPulseWidth | |
- BYTE | PulseWidth |
- VOID | Return |
SetSamplingRate
SetSamplingRate | |
- BYTE | SampleRate |
Range: 0-7 / 0=50Hz, 1=100Hz, .., 6=800Hz, 7=1000Hz | |
- VOID | Return |
Update
Update | |
Reads the sensor FIFO buffer and stores the readings into local RAM. Returns the number of samples read. | |
- BYTE | Return |