Code: Select all
configure_clock_rate( clk, 100, 130 ); // clock, base frequency (100MHz), divisor in MHz)
Code: Select all
<Node Id="0" Type="XS1-L1A" Oscillator="13MHz" SystemFrequency="399750kHz" ReferenceFrequency="99937500Hz">
mi_cmd_var_create: unable to create variable object
The code window shows:
Code: Select all
No source available for "configure_clock_rate.coersed..f.7b0.7d.28ui.2cui.2cui.29() "
Code: Select all
"Suspended: Signal 'ET_ECALL' received. Description: Application exception.)"
The configure_clock_rate() takes an integer MHz frequency and since the SFE reference frequency was defined to be:
Code: Select all
ReferenceFrequency="99937500Hz"
I can't figure out how to configure a clocked port with the SFE board definition SFE.xn without generating a run-time exception.
Any hints for how to deal with the SFE XMOS board in particular related to the limitation that the .xn definition doesn't have a 100MHz base frequency?
The Sparkfun SFE.xn file looks like this:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<Network xmlns="http://www.xmos.com"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.xmos.com http://www.xmos.com">
<Type>Board</Type>
<Name>SparkFun XS1-L1-64 Development Board</Name>
<Declarations>
<Declaration>core stdcore[1]</Declaration>
</Declarations>
<Nodes>
<Node Id="0" Type="XS1-L1A" Oscillator="13MHz" SystemFrequency="399750kHz" ReferenceFrequency="99937500Hz">
<Boot>
<Source Location="SPI:bootFlash"/>
</Boot>
<Core Number="0" Reference="stdcore[0]">
<Port Location="XS1_PORT_1A" Name="PORT_SPI_MISO"/>
<Port Location="XS1_PORT_1B" Name="PORT_SPI_SS"/>
<Port Location="XS1_PORT_1C" Name="PORT_SPI_CLK"/>
<Port Location="XS1_PORT_1D" Name="PORT_SPI_MOSI"/>
<Port Location="XS1_PORT_1E" Name="RED_LED"/>
<Port Location="XS1_PORT_1F" Name="GREEN_LED"/>
<Port Location="XS1_PORT_1H" Name="PORT_UART_TX"/>
<Port Location="XS1_PORT_1I" Name="PORT_UART_RX"/>
</Core>
</Node>
</Nodes>
<Packages>
<Package id="0" Type="XS1-L1A-LQ64">
<Component NodeId="0" InPackage="0"/>
</Package>
</Packages>
<ExternalDevices>
<Device NodeId="0" Core="0" Class="SPIFlash" Name="bootFlash" Type="AT25DF041A">
<Attribute Name="PORT_SPI_MISO" Value="PORT_SPI_MISO"/>
<Attribute Name="PORT_SPI_SS" Value="PORT_SPI_SS"/>
<Attribute Name="PORT_SPI_CLK" Value="PORT_SPI_CLK"/>
<Attribute Name="PORT_SPI_MOSI" Value="PORT_SPI_MOSI"/>
</Device>
</ExternalDevices>
<JTAGChain>
<JTAGDevice NodeId="0"/>
</JTAGChain>
</Network>