This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrf8001 setup format

I'm using Maple and custom nrf8001 board... I have the following problems...

I'm usign the library from this topic: forums.leaflabs.com/topic.php

But as you can guest it doesn't work... First after reset my device is in Setup mode, so I don't need RadioReset command.

After that when i'm sending setup data, I get 0x89 (ACI_STATUS_ERROR_UNSUPPORTED_SETUP_FOR MAT)

Any idea where I can be wrong???

  • Full debug log:

    E4 :4, 81, 2, 0, 2, Do setup QUEUE SIZE: 4 MSGS: 21 4 0 C7 :7, 6, 0, 0, 3, 2, 41, D7, Setup msg0 C31 :1F, 6, 10, 0, 0, 0, 0, 0, 0, 0, 4, 0, 4, 1, 1, 0, 0, 6, 0, 0, 90, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, Setup msg1 C31 :1F, 6, 10, 1C, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 14, 3, 90, 1, 64, Setup msg2 E3 :3, 84, 6, 89, 4 3 C31 :1F, 6, 10, 38, 2, FF, 2, 58, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, Setup msg0 C5 :5, 6, 10, 54, 0, 0, Setup msg1 C31 :1F, 6, 20, 0, 4, 4, 2, 2, 0, 1, 28, 0, 1, 0, 18, 4, 4, 5, 5, 0, 2, 28, 3, 1, E, 3, 0, 0, 2A, 4, 14, 7, Setup msg2 E3 :3, 84, 6, 1, E3 :3, 84, 6, 84, 4 6 C31 :1F, 6, 20, 1C, 4, 0, 3, 2A, 0, 1, 55, 41, 52, 54, 69, 63, 73, 4, 4, 5, 5, 0, 4, 28, 3, 1, 2, 5, 0, 1, 2A, 6, Setup msg0 C31 :1F, 6, 20, 38, 4, 3, 2, 0, 5, 2A, 1, 1, 0, 0, 4, 4, 5, 5, 0, 6, 28, 3, 1, 2, 7, 0, 4, 2A, 6, 4, 9, 8, Setup msg1 Cmd Queue Full 4 9 Cmd Queue Full 4 12 Cmd Queue Full 4 15 Cmd Queue Full 4 18 Cmd Queue Full Error in ACI Setup E3 :3, 84, 6, 84, E3 :3, 84, 6, 84, ACI Command 6 Evt Cmd respone: Error. Arduino is in an while(1); loop

  • Full debug log:

    E4 :4, 81, 2, 0, 2, Do setup QUEUE SIZE: 4 MSGS: 21 4 0 C7 :7, 6, 0, 0, 3, 2, 41, D7, Setup msg0 C31 :1F, 6, 10, 0, 0, 0, 0, 0, 0, 0, 4, 0, 4, 1, 1, 0, 0, 6, 0, 0, 90, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, Setup msg1 C31 :1F, 6, 10, 1C, 1, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 14, 3, 90, 1, 64, Setup msg2 E3 :3, 84, 6, 89, 4 3 C31 :1F, 6, 10, 38, 2, FF, 2, 58, 0, 5, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, Setup msg0 C5 :5, 6, 10, 54, 0, 0, Setup msg1 C31 :1F, 6, 20, 0, 4, 4, 2, 2, 0, 1, 28, 0, 1, 0, 18, 4, 4, 5, 5, 0, 2, 28, 3, 1, E, 3, 0, 0, 2A, 4, 14, 7, Setup msg2 E3 :3, 84, 6, 1, E3 :3, 84, 6, 84, 4 6 C31 :1F, 6, 20, 1C, 4, 0, 3, 2A, 0, 1, 55, 41, 52, 54, 69, 63, 73, 4, 4, 5, 5, 0, 4, 28, 3, 1, 2, 5, 0, 1, 2A, 6, Setup msg0 C31 :1F, 6, 20, 38, 4, 3, 2, 0, 5, 2A, 1, 1, 0, 0, 4, 4, 5, 5, 0, 6, 28, 3, 1, 2, 7, 0, 4, 2A, 6, 4, 9, 8, Setup msg1 Cmd Queue Full 4 9 Cmd Queue Full 4 12 Cmd Queue Full 4 15 Cmd Queue Full 4 18 Cmd Queue Full Error in ACI Setup E3 :3, 84, 6, 84, E3 :3, 84, 6, 84, ACI Command 6 Evt Cmd respone: Error. Arduino is in an while(1); loop

  • Hi, Could you try to monitor what is actually sent on the SPI using a logic analyzer? Could you also upload your nRF8001 configuration / xml file?

  • Here is my xml file:

    
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE AttributeServer>
    <Profile Version="1.3">
        <SetupId>0</SetupId>
        <Device>nRF8001_Dx</Device>
        <Service Type="local" PrimaryService="true">
            <Name>UART over BTLE</Name>
            <Uuid BaseUUID="6e400000b5a3f393e0a9e50e24dcca9e" BaseUUIDName="Custom UART">0001</Uuid>
            <Characteristic>
                <Name>UART RX</Name>
                <Uuid BaseUUID="6e400000b5a3f393e0a9e50e24dcca9e" BaseUUIDName="Custom UART">0002</Uuid>
                <DefaultValue></DefaultValue>
                <UsePresentationFormat>0</UsePresentationFormat>
                <UserDescription></UserDescription>
                <MaxDataLength>20</MaxDataLength>
                <AttributeLenType>2</AttributeLenType>
                <ForceOpen>false</ForceOpen>
                <Properties>
                    <WriteWithoutResponse>true</WriteWithoutResponse>
                    <Write>false</Write>
                    <Notify>false</Notify>
                    <Indicate>false</Indicate>
                    <Broadcast>false</Broadcast>
                </Properties>
                <SetPipe>false</SetPipe>
                <AckIsAuto>false</AckIsAuto>
                <PresentationFormatDescriptor Value="0000" Exponent="0" Format="1" NameSpace="01" Unit="0000"/>
                <PeriodForReadingThisCharacteristic>0</PeriodForReadingThisCharacteristic>
                <PeriodForProperties/>
            </Characteristic>
            <Characteristic>
                <Name>UART TX</Name>
                <Uuid BaseUUID="6e400000b5a3f393e0a9e50e24dcca9e" BaseUUIDName="Custom UART">0003</Uuid>
                <DefaultValue></DefaultValue>
                <UsePresentationFormat>0</UsePresentationFormat>
                <UserDescription></UserDescription>
                <MaxDataLength>20</MaxDataLength>
                <AttributeLenType>2</AttributeLenType>
                <ForceOpen>false</ForceOpen>
                <Properties>
                    <WriteWithoutResponse>false</WriteWithoutResponse>
                    <Write>false</Write>
                    <Notify>true</Notify>
                    <Indicate>false</Indicate>
                    <Broadcast>false</Broadcast>
                </Properties>
                <SetPipe>false</SetPipe>
                <AckIsAuto>false</AckIsAuto>
                <PresentationFormatDescriptor Value="0000" Exponent="0" Format="1" NameSpace="01" Unit="0000"/>
                <PeriodForReadingThisCharacteristic>0</PeriodForReadingThisCharacteristic>
                <PeriodForProperties/>
            </Characteristic>
        </Service>
        <Service Type="local" PrimaryService="true">
            <Name>Device Information</Name>
            <Uuid>180a</Uuid>
            <Characteristic>
                <Name>Hardware Revision String</Name>
                <Uuid>2a27</Uuid>
                <DefaultValue>0A</DefaultValue>
                <UsePresentationFormat>0</UsePresentationFormat>
                <UserDescription></UserDescription>
                <MaxDataLength>9</MaxDataLength>
                <AttributeLenType>2</AttributeLenType>
                <ForceOpen>false</ForceOpen>
                <Properties>
                    <WriteWithoutResponse>false</WriteWithoutResponse>
                    <Write>false</Write>
                    <Notify>false</Notify>
                    <Indicate>false</Indicate>
                    <Broadcast>false</Broadcast>
                </Properties>
                <SetPipe>true</SetPipe>
                <AckIsAuto>false</AckIsAuto>
                <PresentationFormatDescriptor Value="0000" Exponent="0" Format="25" NameSpace="01" Unit="0000"/>
                <PeriodForReadingThisCharacteristic>0</PeriodForReadingThisCharacteristic>
                <PeriodForProperties/>
            </Characteristic>
        </Service>
        <Gapsettings>
            <Name>UART</Name>
            <DeviceNameWriteLength>7</DeviceNameWriteLength>
            <LocalPipeOnDeviceName>true</LocalPipeOnDeviceName>
            <DeviceNameShortLength>0</DeviceNameShortLength>
            <Apperance>0000</Apperance>
            <SecurityLevel>0</SecurityLevel>
            <AuthenticationReq>0</AuthenticationReq>
            <IoCapabilities>0</IoCapabilities>
            <BondTimeout>600</BondTimeout>
            <SecurityRequestDelay>0</SecurityRequestDelay>
            <MinimumKeySize>7</MinimumKeySize>
            <MaximumKeySize>16</MaximumKeySize>
            <AdvertisingDataBondedBitmap>1a</AdvertisingDataBondedBitmap>
            <AdvertisingDataGeneralBitmap>1a</AdvertisingDataGeneralBitmap>
            <AdvertisingDataBrodcastBitmap>10</AdvertisingDataBrodcastBitmap>
            <AdvertisingDataBondedScanResponseBitmap>0</AdvertisingDataBondedScanResponseBitmap>
            <AdvertisingDataGeneralScanResponseBitmap>0</AdvertisingDataGeneralScanResponseBitmap>
            <AdvertisingDataBrodcastScanResponseBitmap>0</AdvertisingDataBrodcastScanResponseBitmap>
            <AdvertisingDataBondedBitmapCustom>0</AdvertisingDataBondedBitmapCustom>
            <AdvertisingDataGeneralBitmapCustom>0</AdvertisingDataGeneralBitmapCustom>
            <AdvertisingDataBrodcastBitmapCustom>0</AdvertisingDataBrodcastBitmapCustom>
            <AdvertisingDataBondedScanResponseBitmapCustom>0</AdvertisingDataBondedScanResponseBitmapCustom>
            <AdvertisingDataGeneralScanResponseBitmapCustom>0</AdvertisingDataGeneralScanResponseBitmapCustom>
            <AdvertisingDataBrodcastScanResponseBitmapCustom>0</AdvertisingDataBrodcastScanResponseBitmapCustom>
            <TxPowerLevelOffset>0</TxPowerLevelOffset>
            <MinimumConnectionInterval>6</MinimumConnectionInterval>
            <MaximumConnectionInterval>18</MaximumConnectionInterval>
            <SlaveLatency>0</SlaveLatency>
            <TimeoutMultipler>10</TimeoutMultipler>
            <ServiceToAdvertise>
                <Uuid BaseUUID="6e400000b5a3f393e0a9e50e24dcca9e" BaseUUIDName="Custom UART">0001</Uuid>
            </ServiceToAdvertise>
            <CustomAdTypes>
                <AdType index="1">
                    <Type>19</Type>
                    <Value>0000</Value>
                </AdType>
                <AdType index="2">
                    <Type>18</Type>
                    <Value></Value>
                </AdType>
            </CustomAdTypes>
        </Gapsettings>
        <Hardwaresettings>
            <Clocksource>1</Clocksource>
            <ClockAccuracy>1</ClockAccuracy>
            <InitialTxPower>3</InitialTxPower>
            <HfClkSource>0</HfClkSource>
            <DcDcConverter>0</DcDcConverter>
            <ActiveSignalModeIndex>0</ActiveSignalModeIndex>
            <ActiveSignalToTickDistance>0</ActiveSignalToTickDistance>
            <DynamicWindowLimitingEnabled>false</DynamicWindowLimitingEnabled>
        </Hardwaresettings>
        <CurrentInput>
            <BatteryCharge>220</BatteryCharge>
            <Master32KhzClockAccuracy>10</Master32KhzClockAccuracy>
            <ConnectionInterval>1000</ConnectionInterval>
            <PercentOfTimeSleeping>10</PercentOfTimeSleeping>
            <PercentOfTimeAdvertising>10</PercentOfTimeAdvertising>
            <AdvertisingInterval>1280</AdvertisingInterval>
        </CurrentInput>
    </Profile>
    
    

    I don't see how this is SPI issue... After power-up and hardware reset the device is in setup mode... So I try Test mode.... and everything work perfect...

  • Hi,

    It looks like you are using a setup format that works on the D version of the chip, by looking at the xml file "nRF8001_Dx"

    The error that you have seems to be because that you are putting a setup for the D version of the chip into the C version of the chip. This seems to be the error. What version of the chip do you have ?

Related