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.


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: