SDSIO Interface
The SDSIO components offer flexible SDS communication interfaces. You may choose between these interface components that are stored in the folders: ./sds/sdsio/client, ./sds/sdsio/fs or ./sds/sdsio/vsi. These interfaces can be accessed as CMSIS software components for integration into the target system:
- component: SDS:IO:Socket # IoT Socket Interface (Ethernet or WiFi)
- component: SDS:IO:USB&MDK USB # USB Interface
- component: SDS:IO:Serial&CMSIS USART # USART Interface
- component: SDS:IO:File System&MDK FS # Memory card
- component: SDS:IO:File System&Semihosting # Simulation or Debugger via Semihosting interface
- component: SDS:IO:VSI # VSI Simulation interface of an AVH FVP
- component: SDS:IO:Custom # Source code template for custom implementation
To simplify usage further, the following pre-configured SDS interface layers in csolution project format are available. These connect via various interfaces to the SDSIO-Server, which provides read/write access to SDS data files.
- Ethernet Interface using the MDK-Middleware Network component.
- USB Bulk Interface using the MDK-Middleware USB component.
- Memory Card Interface using the MDK-Middleware File System component.
Layer: sdsio_network
The layer/sdsio/network/sdsio_network.clayer.yml is configured for recording and playback via the Ethernet interface. It uses the MDK-Middleware Network component.
For SDS data file access the SDSIO-Server is started on the Host computer as shown below. This output an IP address as shown below:
>python sdsio-server.py socket
Press Ctrl+C to exit.
Socket server listening on 172.20.10.2:5050
This is the IP address that the target hardware needs to connect to and it is required to configure this IP address in the file ./layer/sdsio/network/RTE/SDS/sdsio_client_socket_config.h with the define SDSIO_SOCKET_SERVER_IP.
Layer: sdsio_usb
The layer/sdsio/usb/sdsio_usb.clayer.yml is configured for recording and playback via the USB Device interface. It uses the MDK-Middleware USB Device component and connects via a USB interface to a Host computer.
For SDS data file access start the SDSIO-Server on the Host computer with:
>sdsio-server.py usb
Press Ctrl+C to exit.
Starting USB Server...
Waiting for SDSIO Client USB device...
Once the SDSIO-Server is running start the application. The SDSIO-Server outputs:
SDSIO Client USB device connected.
For recording, the SDSIO-Server outputs:
Record: ML_In (.\ML_In.0.sds).
Record: ML_Out (.\ML_Out.0.sds).
..
Closed: ML_In (.\ML_In.0.sds).
Closed: ML_Out (.\ML_Out.0.sds).
For playback, the SDSIO-Server outputs:
Playback: ML_In (.\ML_In.0.sds).
Record: ML_Out (.\ML_Out.0.p.sds).
Closed: ML_In (.\ML_In.0.sds).
Closed: ML_Out (.\ML_Out.0.p.sds).
Layer: sdsio_rtt
The layer/sdsio/rtt/sdsio_rtt.clayer.yml is configured for recording and playback using the SEGGER RTT component for I/O via a debug adapter.
Layer: sdsio_fs
The layer/sdsio/filesystem/sdsio_fs.clayer.yml is configured for recording to a Memory Card. It uses the MDK-Middleware File System component.
Layer: sdsio_fvp
The template/sdsio/fvp/sdsio_fvp.clayer.yml targets AVH FVP simulation and is configured for recording and playback to/from the Host computer. It uses the SDSIO VSI interface implemented by the file vsi/python/arm_vsi3.py, which is loaded by the FVP simulation model. Since the SDSIO-Server functionality is implemented in arm_vsi3.py, no separate SDSIO-Server is required.
Configuration File: sdsio.yml
The SDSIO VSI interface can be configured using a *.sdsio.yml control file located in the simulator working directory.
The VSI3 Python script (arm_vsi3.py) searches for a control file using the following order (first match wins):
sdsio.ymlsdsio.yaml- the first file (alphabetical order) matching
*.sdsio.yml - the first file (alphabetical order) matching
*.sdsio.yaml
If a control file is found, the script reads the sdsio: root node. If workdir: is a relative path, it is interpreted relative to the simulator working directory.
Log File: sdsio.log
During the FVP simulation a log file is generated that lists the SDS data file access.
Example:
Created by ...\Board\Corstone-300\vsi\python\arm_vsi3.py
Playback: ML_In (.\algorithm\SDS Recordings\ML_In.0.sds).
Record: ML_Out (.\algorithm\SDS Recordings\ML_Out.0.p.sds).
Closed: ML_In.
Closed: ML_Out.
Playback: ML_In (.\algorithm\SDS Recordings\ML_In.1.sds).
Record: ML_Out (.\algorithm\SDS Recordings\ML_Out.1.p.sds).
Closed: ML_In.
Closed: ML_Out.
:
:
Playback: ML_In (.\algorithm\SDS Recordings\ML_In.11.sds).
Record: ML_Out (.\algorithm\SDS Recordings\ML_Out.11.p.sds).
Closed: ML_In.
Closed: ML_Out.