MicrocontrollerKit`
MicrocontrollerKit`

MicrocontrollerCodeData

MicrocontrollerCodeData[]

represents data about code that was generated using MicrocontrollerEmbedCode.

Details and Options

  • A MicrocontrollerCodeData[] object mcd can be used to retrieve various properties.
  • The list of relevant properties is given by mcd["Properties"].
  • General properties include:
  • "ClockFrequency"microcontroller clock frequency
    "ExitCode"exit code of underlying processes
    "ExternalProgrammer"external programmer used
    "MachineCodeByteCount"machine code size in bytes
    "Microcontroller"microcontroller name
    "OperatingVoltage"operating voltage (VCC)
    "Programmer"programmer used
    "SourceCode"display source code
    "SourceCodeByteCount"source code size in bytes
    "StandardError"standard error of underlying processes
    "StandardOutput"standard output of underlying processes
    "SystemsModel"systems model that was embedded
    "Target"target where systems model was embedded
    "Timer"timer or counter number
  • Timer subproperties:
  • "Mode"counter operating mode
    "Prescaler"timer prescaler value
    "SamplingError"sampling error in each cycle
    "Top"counter top value
  • Serial communication subproperties:
  • "BaudRate"data transfer rate in bits per second
    "BaudRateError"baud rate error due to roundoff
    "DataBits"number of data bits to use per frame
    "DelimiterByte"delimiter used for multivariable systems
    "EndByte"last character sent and received
    "FractionalPartDigits"number of digits in the fractional part
    "Parity"setting for the parity bit
    "StartByte"first character sent and received
    "StopBits"number of stop bits to use
    "TransmissionSpeedMode"transfer rate speed mode
  • Other properties:
  • "ADC"analog to digital (ADC) conversion
    "PulseWidthWaveform"waveform for pulse width modulation (PWM)
    "I2CAddress"I2C address
  • The properties "PropertyAssociation" and "PropertyDataset" return computable forms of all properties.

Examples

open allclose all

Basic Examples  (1)

Load the package:

Embed code to a target:

Obtain a list of available properties:

The microcontroller:

Scope  (3)

Obtain a particular property value:

Obtain several property values simultaneously:

Some properties may be missing:

Wolfram Research (2019), MicrocontrollerCodeData, Wolfram Language function, https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html.

Text

Wolfram Research (2019), MicrocontrollerCodeData, Wolfram Language function, https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html.

CMS

Wolfram Language. 2019. "MicrocontrollerCodeData." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html.

APA

Wolfram Language. (2019). MicrocontrollerCodeData. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html

BibTeX

@misc{reference.wolfram_2024_microcontrollercodedata, author="Wolfram Research", title="{MicrocontrollerCodeData}", year="2019", howpublished="\url{https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html}", note=[Accessed: 22-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_microcontrollercodedata, organization={Wolfram Research}, title={MicrocontrollerCodeData}, year={2019}, url={https://reference.wolfram.com/language/MicrocontrollerKit/ref/MicrocontrollerCodeData.html}, note=[Accessed: 22-November-2024 ]}