File system on SD card using STM32MP157D-DK1 - arm

Dear Stackoverflow community,
I am working on a project using STM32MP157D-DK1 and currently trying to create a File System using SD card.
I am not getting the option for FATFS in the CubeMX configuration. (see in picture)
Please help me out!
I am following the instructions of a video on ST’s official Youtube page:
https://www.youtube.com/watch?v=I9KDN1o6924
picture: https://imgur.com/a/bN5oR3p

I think FatFs is included with the STM32Cube MCU Package for STM32MP1. On the STM32CubeMX Pinout & Configuration Page, drop down the Software Packs menu and select Manage Software Packs. In the Embedded Software Packages Manager dialog box, on the STM32Cube MCU Packages tab, expand the STM32MP1 row and ensure that the latest STM32Cube MCU Package for STM32MP1 is checked and installed.

Related

Keil custom software pack

I have an embedded code which is working fine with my STM32 with configurable defines. Now I want to share that code as a Keil pack to let my colleagues to use the code preventing them to see source code.(like other hidden&configurable CMSIS packs)
I followed open-cmsis-pack. Create a lib, header and configuration wizard file, succesfully create pack. They can use it, working.
Yet they cant change the configuration. Even if configuration is made from Configuration Wizard, code working as firstly compiled when the lib file created. How can I handle this issue? Is there any guide for it?

.Net framework based software that loads Configuration file into microcontroller flash

I am new to microcontroller - Recently I am working on an embedded device that has a nice Software based on .Net framework. This Software allow users to change the pre-loaded configurations like TCP/IP parameters(IP,Port), temperature thresholds, timer setting, enabling and disabling specific peripherals or GPIO's. After we make our desired configuration there is a button on .Net Form titled as "Load Configuration" or "Save Configuration file" and when we press this button all configuration is loaded into embedded device serially.
Now i am interested in making the software like this which help me in just making some changes in configuration, instead of loading a huge hex file again and again.
Please help me in this regard.

Atmel Studio 7 doesn't show any debugging tools

I just installed Atmel Studio 7 on my Windows 10 HP laptop. This is my first time working w/ a C compiler since high school, and my first time working with a microcontroller.
I loaded one of their example projects and built it without any errors. However, I am not able to debug since there is no option for a debugging tool (see screenshot). The only option is for 'Custom programming tool', while their tutorial videos all show an option for a SAM-ICE debugger or Simulator (e.g. https://www.youtube.com/watch?v=9QlDSNeuAdY)
I have spent hours trying to find an issue online w/ no luck. Please help!
I have had the same problem. I solved this by unchecking the box Tools->Options->Debugger->Backend Agent-> Start Local Backend Agent and then checking that box again
I'll add this information as I also just spent a fair amount of time trying to determine why no debugging tool was available as an option:
Make sure you have the right device connected.
I know this sounds terribly basic, but in my case I have both SAML21 and SAML22 Xplained Pro boards, and I'd forgotten which one I had targeted for a particular project. If you have a project open that targets one, but the attached device is different, you may have this problem. The only available option becomes "Custom Programming Tool" which isn't helpful.
After connecting the correct board, I had to revisit the Tool menu and change the selected debugger/programmer to the appropriate (only) EDBG • ATML###### option.
If you're not using an Atmel Xplained board, this may not be applicable.
I spend some time about this problem as well and found out that all I had to do was go to Device and Debugging options then go to Build and select All Configurations in the configuration box then the simulator should appear under tools.
In my case it was atbackend.exe which crashed after hibernating my laptop. I had to stop Atmel studio, ensure that no AtmelStudio or atbackend processes exist in system and then start ATmel STudio again. After that Simulator appeared in Tool-Selected debugger/programmer.

libwebsockets: How to download files from http server using libwebsocket client

I'm doing a project on ARM platform (Linux Kernel), where I need to code a firmware autoupdate task in C. In order to that, I need to download the manifest file from the FTP/HTTP server and from the manifest file, I'll have link to download the firmware package. I'm using libwebsockets to achieve this task as this is very light weight and has low memory footprint.
Please help me on HOW to download the files and upload the files (as a client) using the libwebsockets library? I have gone through the examples and source code repo to understand how this library works, but this is pretty confusing to fathom the flow and API. Please help me, folks.
Thank you all in advance.

How to modify the TI SensorTag Firmware to advertise indefinitely?

When the side button of the TI SensorTag is pressed, pairing with a device is possible for approx. 2-3 minutes. How do you modify the SensorTag's firmware so that it advertises forever and pressing the side button is not necessary every time?
And how do you upload the firmware with an iOS device, so without using CC-debugger?
How I did it, with help of Chris Innanen (thanks!!)
You will need a Windows virtual machine if you do it on a Mac.
Download IAR Embedded Workbench for 8051 (http://supp.iar.com/Download/SW/?item=EW8051-EVAL). Make sure to take the 30-day evaluation copy and not the 4k limited.
Download BLE-STACK from Texas Instruments (http://www.ti.com/tool/ble-stack) and install it on a Windows (virtual) machine. By default, the installer will install here: "C:\Texas Instruments\BLE-CC254x-1.4.0\Projects\ble\SensorTag\CC2541DB\SensorTag.eww".
Open this SensorTag.eww file with IAR Embedded Workbench.
Select "CK2541DK-Sensor-OAD-ImgA" in the dropdown menu in the "workspace" section on the left
To prevent a compiling error later on: go to Project -> Options... and change the value for "Number of virtual registers" from 16 to 8.
Find "SensorTag.c" in the filetree in the workspace section on the left: "SensorTag - CK2541DK-Sensor-OAD-ImgA/APP/SensorTag.c"
Search for GAP_ADTYPE_FLAGS_LIMITED and change it to GAP_ADTYPE_FLAGS_GENERAL to enable indefinit advertising
Make the build with Project -> Make. Wait until it's done
By default, the new firmware image (.bin file) is now in "C:\Texas Instruments\BLE-CC254x-1.4.0\Projects\ble\SensorTag\CC2541DB\CC2541DK-Sensor-OAD-ImgA\Exe" (Make sure to place it somewhere you can reach it from Mac OS X later, if you use a virtual machine)
Repeat steps 4 to 10, but now for "CC2541DK-Sensor-OAD-ImgB"
Now get the app to upload the new firmware over the air. Get it here: https://itunes.apple.com/us/app/ti-sensortag/id552918064?mt=8
Open iTunes in Mac OS X and open your iOS device, go to the 'Apps' section, scroll to the bottom to see the apps with filesharing possibilities. "SensorTag" should be in that list. Click on it and add the two new firmware files, both Image A and B.
If that's done, open the SensorTag app on your iOS device and connect it to the SensorTag. Then in the bottom of the app tap "Update FW" -> "Select FW file" -> Shared Files > And then tap Image B and upload it. It takes a few minutes. A firmware with type A is already on your SensorTag by default. Because you've put a B Image on it just now, with any new changes you would need to upload an Image A.
Good luck!
Additional: changing the signal strength
1) Find "HCI_EXT_ClkDivOnHaltCmd" and you'll add a new line (and optional comment) after it:
// ADDITION Adjust TX power level
HCI_EXT_SetTxPowerCmd( HCI_EXT_TX_POWER_0_DBM );
1b) You can change "_0_DBM" to "_4_DBM" or "_MINUS_6_DBM" or "_MINUS_23_DBM" as well
2) Find "GAP_ADTYPE_POWER_LEVEL" and change the value on the next line to match the above power level
The above solution didn't work for me until I changed:
initial_advertising_enable = TRUE;
In SensorTag_Init().
I am using this firmware and it will start broadcasting whenever it's not connected. The side button acts as an on and off switch.
http://www.myweathercenter.net/installing-a-new-firmware-for-ti-sensortag/

Resources